We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Description
I try to share a container mount with the host like done with docker example mount in onboot section.
Steps to reproduce the issue:
Generated a custom mount image (alpine image)
onboot section
- name: mount image: alpine:latest capabilities: - CAP_SYS_ADMIN binds: - /dev:/dev - /var:/var:rshared,rbind rootfsPropagation: shared command: - "/bin/mount" - "LABEL=<MY_LABEL>" - "/var/lib/docker"
Also tested with config by image label:
LABEL org.mobyproject.config='{"binds": ["/dev:/dev", "/var:/var:rshared,rbind", "/:/hostroot"], "capabilities": ["CAP_SYS_ADMIN"], "rootfsPropagation": "shared", "net": "new", "ipc": "new"}'
Same result
Describe the results you received:
Mount inside of the container, but isn't available in the host
/ # df Filesystem 1K-blocks Used Available Use% Mounted on
rbind is set twice
{ "destination": "/var", "type": "bind", "source": "/var", "options": [ "rshared", "rbind", "rbind" ] },
namespaces and rootfsPropagation:
"linux": { "resources": {}, "namespaces": [ { "type": "pid" }, { "type": "mount" } ], "rootfsPropagation": "shared" }
Describe the results you expected:
Mount should be available in host root filesystem
How to fix it
Remove mount namespace lines from config.json and run with runc run again and it will work
runc run
{ "type": "mount" }
And it works fine
/ # df Filesystem 1K-blocks Used Available Use% Mounted on /dev/sda1 10252256 36888 9674868 0% /var/lib/docker
Is it a bug or is something wrong with my yml file? Is it possible to set mount namespace as needed in yml?
The text was updated successfully, but these errors were encountered:
mount namespace is also set if I test docker.yml, but it works... Is there some magic in the linuxkit/init?
Sorry, something went wrong.
No branches or pull requests
Description
I try to share a container mount with the host like done with docker example mount in onboot section.
Steps to reproduce the issue:
Generated a custom mount image (alpine image)
onboot section
Also tested with config by image label:
Same result
Describe the results you received:
Mount inside of the container, but isn't available in the host
rbind is set twice
namespaces and rootfsPropagation:
Describe the results you expected:
Mount should be available in host root filesystem
How to fix it
Remove mount namespace lines from config.json and run with
runc run
again and it will workAnd it works fine
Is it a bug or is something wrong with my yml file?
Is it possible to set mount namespace as needed in yml?
The text was updated successfully, but these errors were encountered: