arangodb / arangodb-docker

Docker container for ArangoDB
Apache License 2.0
106 stars 32 forks source link

Folder Permission in Alpine images are not root group writeable #103

Open vbasem opened 2 years ago

vbasem commented 2 years ago

The folder permissions for /var/lib/arangodb3 /var/lib/arangodb3* are not being properly set to 775 as mentioned in the Dockerfile:

echo chgrp -R 0 /var/lib/arangodb3 /var/lib/arangodb3-apps && \
echo chmod -R 775 /var/lib/arangodb3 /var/lib/arangodb3-apps &

The echo is rendering the command ineffective. This causes environments that disallow root user to fail when starting the ID container which needs to write to those folders which only have read permission by default.

I fixed it locally by rebuilding the image by simply removing the echo in the 2 commands above.

Was the echo on purpose?

Basem Vaseghi basem.vaseghi@daimler.com, Daimler TSS GmbH, legal info/Impressum

KVS85 commented 2 years ago

Hello @vbasem,

This was fixed in https://github.com/arangodb/arangodb-docker/commit/d46dfa818833436aa89907a045c803de84c7868a and soon will appear at https://hub.docker.com/_/arangodb?tab=description.

trieder83 commented 2 years ago

To make the directories root writeable on a image is not a good idea. Usually root it's prohibited (by psp) to run a image as root. As well, it's a bad practice to write to image filesystem as well!