Resin local push without sudo

resin-cli

#1

I tend to be selective about the root access I give on my system.

To me it’s like telling someone he can come to my house when I’m away. You know what I mean right?

Being new to resin I feel we are not there yet in our relationship :slight_smile:

I’m kinda stuck because I’d also like to try the example but local push requires root.

I saw here that it looks to be related to the mdns interaction (https://github.com/resin-io/resin-cli/issues/542) but I’m not sure if this is the case because it still complains if I type the device address.

I have a feeling it could well run as user if I type the address but there might be an unconditional check for root in the code that I could maybe hack away.

Is it the case?


#4

Well I couldn’t really find my way in the code so I ended up going crazy and I changed

node_modules/is-root/index.js

to always return true.

It feels really bad but for just a quick test it will do.

Now this works as user:

resin local push --verbose 172.16.11.253 --source .