Skip to content
New issue

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

docker: Fix userdata bind mount path inside the container #2222

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

bpradipt
Copy link
Member

For docker provider we use systemd container which mounts /run as a tmpfs volume.
This mounting of /run happens after docker has bind mounted the userdata file inside the container and consequently the userdata file is no longer accessible.

This commit changes the path of the userdata file to not use /run for the docker provider.

For docker provider we use systemd container which mounts /run
as a tmpfs volume.
This mounting of /run happens after docker has bind mounted the
userdata file inside the container and consequently the userdata file is no
longer accessible.

This commit changes the path of the userdata file to not use `/run` for
the docker provider.

Signed-off-by: Pradipta Banerjee <[email protected]>
@bpradipt bpradipt requested a review from a team as a code owner December 23, 2024 17:52
@bpradipt
Copy link
Member Author

I'm not sure if there is a better way to solve the issue. Open for suggestion

Copy link
Collaborator

@mkulke mkulke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's probably better to change the default mount path for the ci disk rather than adding an exception for docker, no? it doesn't need to be in /run I think, it can be in /mnt or wherever

@bpradipt
Copy link
Member Author

it's probably better to change the default mount path for the ci disk rather than adding an exception for docker, no? it doesn't need to be in /run I think, it can be in /mnt or wherever

Yeah, having a uniform one is better. I was not sure if there is a hard dependency on /run for any platform. Let me just use /media as the mount path for the ci disk and check through ci if anything breaks. That should help.

@bpradipt
Copy link
Member Author

One challenge is how to make /media mountpath available early in the boot cycle since root (/) is RO. Only the following are available via systemd - https://freedesktop.org/wiki/Software/systemd/APIFileSystems/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants