-
Notifications
You must be signed in to change notification settings - Fork 5.3k
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
Add support for privileged containers #123 #132
Conversation
|
I think |
Ah gotchya – yes, that's worth checking, and making sure it doesn't get passed through.
|
I'd love to run via fig with |
Hey @bfirsh I found some more time to work on this and made it so that You were right, the option is only needed for running containers, and this allowed me to also revert the changes I had made to It works for me (I can mount network volumes from within containers) but I'm not sure if I did it in the best way/place, so let me know what you think. |
@bfirsh is this pull waiting on anything (other than a review)? |
@@ -241,7 +249,7 @@ def _get_links(self, link_to_self): | |||
links.append((container.name, container.name_without_project)) | |||
return links | |||
|
|||
def _get_container_options(self, override_options, one_off=False): | |||
def _get_container_options(self, override_options, one_off=False, for_create=False): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
_get_container_options
is only used for creating, afaik? Is this needed?
This method should probably be called _get_container_create_options
or something, and we could have a new _get_container_start_options
to make it clear what is going on.
Thanks for taking the time on this @kvz! Added a couple of comments. Would be great to get tests too. |
np, how's this? |
Brilliant, thanks! Will let Travis do its thing. Maybe we should also have a test to check that without the privileged flag, containers aren't privileged. |
This is required for mounting external volumes and addresses errors such as `mount.nfs: Operation not permitted` Be gentle, I don't normally use Python :)
Alright, added that as well : ) |
Huzzah! Thanks! |
Add support for privileged containers #123
😄 |
Add support for privileged containers docker#123 Signed-off-by: Yuval Kohavi <[email protected]>
Switch to new vendor directory layout
This was required when I tried to mount external volumes and
addresses errors such as
mount.nfs: Operation not permitted
(similar for smbfs, and afs)You can add
privileged: True
to any service in yourfig.yml
for the change to take effect.I don't code Python normally, so please be gentle : )