Docker.github.io: group_add option doesn't work as described

Created on 7 Apr 2017  路  8Comments  路  Source: docker/docker.github.io

File: compose/compose-file/index.md, CC @londoncalling

The group_add option is described as being a second level property, right under "services". This option doesn't work. Please note I also tried to put it nested under a service, and it didn't work either, so for now I don't really know what the documentation should read.

See my comment on ticket #3328

areCompose

Most helpful comment

What's the alternative if user need group_add in a version 3 compose file ? Should it be handled manually in Dockerfile ?

All 8 comments

@dnephin @shin- @nathanleclaire @ManoMarks Can you all take a look at the above comment, and also the referenced issue #3328.

It sounds like from the discussions that group_add is not working in Compose?

group_add works fine in Compose, but that example snippet is indeed wrong. It should be something like:

version: '2'
services:
  myservice:
    image: alpine
    group_add:
      - mail

@londoncalling If you're working on this change, it might be a good occasion to remove group_add from the v3 docs as well, since it's only a valid option in v2.

@shin- oh!? okay, thanks, updating it now

@shin- on issue #3328 psoare's seems to have tried this format as a second try and says it didn't work ...? Maybe it's the indents that are different. I'll add your example to Version 2 and remove the whole thing from Version 3.

I confirm this works on version 2 and not on version 3.

@psoares thanks for the feedback, the docs updates are published now, so I'm going to close this issue. Feel free to re-open the discussion or a new issue if you find something else.

What's the alternative if user need group_add in a version 3 compose file ? Should it be handled manually in Dockerfile ?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Mararesliu picture Mararesliu  路  4Comments

thaJeztah picture thaJeztah  路  4Comments

joaofnfernandes picture joaofnfernandes  路  3Comments

MicheleMannino picture MicheleMannino  路  4Comments

GPPassos picture GPPassos  路  3Comments