Skip to content

Debugging procedure should use bind mounts with selinux label

Daniel Juarez requested to merge selinux_bindmount into master

Ref. https://docs.docker.com/storage/bind-mounts/#configure-the-selinux-label

If you use selinux you can add the z or Z options to modify the selinux label of the host file or directory being mounted into the container. This affects the file or directory on the host machine itself and can have consequences outside of the scope of Docker.

    The z option indicates that the bind mount content is shared among multiple containers.
    The Z option indicates that the bind mount content is private and unshared.

Otherwise you need to deal with Selinux yourself, by default mounted volume will show permission denied.

Merge request reports