I've installed Docker CE from the official apt repository. To grant regular users access to Docker, I've created a group
docker and added each user to this group. Yet, whenever any user runs something within a container (
docker run -d ...), the processes are run under my UID and the files they create have my ownership, e.g.
myuser:myuser instead of
anotheruser:anotheruser. When users explicitly specify their UIDs (
docker run -d --user $UID ...), the processes are correctly registered with their UIDs, but the outputs belong to
anotheruser:root. That group specification (i.e.
root) troubles me quite a bit. What should I do to:
- Make other users run dockers under their UIDs only;
- Make their output register as