burmilla / os

Tiny Linux distro that runs the entire OS as Docker containers
https://burmillaos.org
Apache License 2.0
210 stars 13 forks source link

"~/.docker" folder is owned by root user & group #180

Open ahrastnik opened 2 months ago

ahrastnik commented 2 months ago

BurmillaOS Version: (ros os version) v2.0.1 release

Where are you running BurmillaOS? (docker-machine, AWS, GCE, baremetal, etc.) Proxmox 8.1.4

Which processor architecture you are using? x86

Do you use some extra hardware? (GPU, etc)? No

Which console you use (default, ubuntu, centos, etc..) Default

Do you use some service(s) which are not enabled by default? Docker compose

Have you installed some extra tools to console? No

Do you use some other customizations? No

Please share copy of your cloud-init (remember remove all sensitive data first) Not applicable

On a fresh install, it looks like the ~/.docker folder is owned by root:root. This caused a failed image build for me with docker compose, as the build attempts to create build files inside this folder via the rancher user.

Running sudo chown "$USER":"$USER" /home/"$USER"/.docker -R fixes the issue. Perhaps it would be best to assign the folder to the docker group, the same way as the docker socket is already.

olljanat commented 2 months ago

Installation doesn’t create folder “.docker”. Most probably you have used command “docker-compose” before “docker login” which would also create this folder but it would be owned by rancher.

There is other related issues in #168 which why whole docker compose thing should be refactored (or removed).

Now when Docker has switched to quite fast release cycle it potentially would make sense include docker compose to user docker package like Docker CE package works in most of the distros.