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: add support for devices #2308

Merged
merged 1 commit into from
Oct 2, 2019
Merged

docker: add support for devices #2308

merged 1 commit into from
Oct 2, 2019

Conversation

sprat
Copy link
Contributor

@sprat sprat commented Sep 19, 2019

This fixes #2307 by adding a "devices" setting in docker platform config. I also updated the documentation accordingly.

I tested my changes on a custom role and I successfully made a fuse mount with the following settings in my docker platform:

  - name: debian
    image: debian:latest
    #privileged: True
    devices:
      - /dev/fuse:/dev/fuse:rwm
    capabilities:
      - SYS_ADMIN
    security_opts:
      - apparmor=unconfined

PR Type

  • Feature Pull Request

Copy link
Contributor

@decentral1se decentral1se left a comment

Choose a reason for hiding this comment

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

Thanks @sprat! You'll have to resolve the DCO issue to pass the PR tests.

Also, there is a little bit more work for this one. You'll need to add tests. Please see #1889 for a similar change in which you can follow along what needs to be done. Hope that is clear.

@ssbarnea
Copy link
Member

@sprat Please fix the DCO as I cannot bypass it.

@sprat
Copy link
Contributor Author

sprat commented Sep 19, 2019

No problem, I'll fix that when I come back to home.

Signed-off-by: Sylvain Prat <sylvain.prat@gmail.com>
@sprat
Copy link
Contributor Author

sprat commented Sep 25, 2019

The merge request should be ok. One job failed due to problem with apt install which has nothing to do with my merge request.

Copy link
Contributor

@decentral1se decentral1se left a comment

Choose a reason for hiding this comment

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

Restarted the CI build.

Also (from ^^^):

Also, there is a little bit more work for this one. You'll need to add tests. Please see #1889 for a similar change in which you can follow along what needs to be done. Hope that is clear.

@ssbarnea ssbarnea changed the title Fixed #2307 docker: add support for devices Oct 2, 2019
@ssbarnea ssbarnea dismissed decentral1se’s stale review October 2, 2019 16:54

no need to add tests yet, ours cover enough and we are not in the business of validating docker module itself.

@ssbarnea ssbarnea merged commit 2da62fc into ansible:master Oct 2, 2019
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.

"devices" support in docker driver
3 participants