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

Fix bindmount autocreate race #376

Merged
merged 1 commit into from Jul 9, 2020

Conversation

kolyshkin
Copy link

When using the mounts API, bind mounts are not supposed to be
automatically created.

Before this patch there is a race condition between validating that a
bind path exists and then actually setting up the bind mount where the
bind path may exist during validation but was removed during mountpooint
setup.

This adds a field to the mountpoint struct to ensure that binds created
over the mounts API are not accidentally created.

@kolyshkin: port of upstream commit 1caeb79/PR moby#37378

Signed-off-by: Brian Goff cpuguy83@gmail.com
Signed-off-by: Kir Kolyshkin kolyshkin@gmail.com

When using the mounts API, bind mounts are not supposed to be
automatically created.

Before this patch there is a race condition between valiating that a
bind path exists and then actually setting up the bind mount where the
bind path may exist during validation but was removed during mountpooint
setup.

This adds a field to the mountpoint struct to ensure that binds created
over the mounts API are not accidentally created.

[@kolyshkin: port of upstream commit 1caeb79]

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
@kolyshkin
Copy link
Author

@rh-atomic-bot
Copy link

Can one of the admins verify this patch?
I understand the following commands:

  • bot, add author to whitelist
  • bot, test pull request
  • bot, test pull request once

@rhatdan
Copy link
Member

rhatdan commented Jul 9, 2020

LGTM

@rhatdan rhatdan merged commit fd5a16e into projectatomic:docker-1.13.1-rhel Jul 9, 2020
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.

None yet

4 participants