Skip to content
Advertisement

Strange file permission in docker container (question marks on permission bit and user bit)

I write a Dockerfile and docker-compose.yml to build a custom image which combines beakerx and cling, which contents are below.

JavaScript

and

JavaScript

Some logs of docker-compose build were

JavaScript

But When I run docker-compose up -d, I got PermissionError: [Errno 13] Permission denied: '/home/beakerx/.local/share' error. So I drive into the docker image.

JavaScript

Why the permission of ~/.local/share was a lot of question marks at the first sight, and when I run as root or return to the original user, it was correct.

I tried run start-notebook.sh manually, the first time it was failed, then the second time it was successfully.

JavaScript

If I modified Dockerfile (move up USER beakerx)

JavaScript

Then some errors occurred (ls -la /home/beakerx/.local).

JavaScript

Advertisement

Answer

This problem is related to the storage-driver bug, see https://github.com/moby/moby/issues/28391, https://github.com/moby/moby/issues/20240. Currently I can only change storage-driver to overlay, use the default aufs or recommended overlay2 will break.

User contributions licensed under: CC BY-SA
7 People found this is helpful
Advertisement