illinois-cs241 / broadway

A distributed systems framework used running distributable workloads.
Other
18 stars 0 forks source link

Can we get rid of the need to run as root? #12

Open bhuvy2 opened 5 years ago

bhuvy2 commented 5 years ago

As usual, running a piece of code as root unless absolutely necessary is just good security practice. Can we have a script that creates a new user and sets up that user to be a part of the docker group instead of root?

jasonB221 commented 5 years ago

I tried running as a user with access to docker, and the main issue I ran into is most docker containers run as root, which will make it hard to clean up the job directory after the run finishes. Even if the containers aren't running as root, it is unlikely that the docker container user and whatever service user is created will have the same UID, making cleanup annoying.