You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
However, the compose-go repository's corresponding file does not contain the parameter in the corresponding specification file (it only has the size parameter), see line 401. Nor does the struct support mode, only size.
All this results in that Docker compose version 2.6.0 (which I happen to be running) does not support specifying mode for a tmpfs volume definition, even though https://docs.docker.com/compose/compose-file/ states that "The Compose spec merges the legacy 2.x and 3.x versions, aggregating properties across these formats and is implemented by Compose 1.27.0+."
For example, the following service definition (snippet) errors with services.postgres.volumes.2.tmpfs Additional property mode is not allowed when running docker compose config:
Hi team, any chance we can get this issue looked at? This is a blocker for a project I'm working on. tmpfs mounts defined by a compose file are given inconsistent permissions (sometimes they're world-writable, other times they're only writable by the owner).
milas
added a commit
to milas/compose-go
that referenced
this issue
Nov 30, 2022
Schema included `size` for `tmpfs` mounts but not `mode`. This
appears to have been an oversight.
Fixescompose-spec#302.
Signed-off-by: Milas Bowman <milas.bowman@docker.com>
TL;DR: Docker Compose (at least version 2.x) does not support the
mode
parameter fortmpfs
volume definitions, even though it should.In the Compose Specification, we find that one should be able to define a filesystem
mode
for thetmpfs
mount. The specification itself contains this parameter at line 409.However, the
compose-go
repository's corresponding file does not contain the parameter in the corresponding specification file (it only has thesize
parameter), see line 401. Nor does the struct supportmode
, onlysize
.All this results in that Docker compose version 2.6.0 (which I happen to be running) does not support specifying
mode
for atmpfs
volume definition, even though https://docs.docker.com/compose/compose-file/ states that "The Compose spec merges the legacy 2.x and 3.x versions, aggregating properties across these formats and is implemented by Compose 1.27.0+."For example, the following service definition (snippet) errors with
services.postgres.volumes.2.tmpfs Additional property mode is not allowed
when runningdocker compose config
:(PS: Don't ask me why I "want" to set mode 777 for this tmpfs mount - it's just an evil necessity due to various other limitations.)
The text was updated successfully, but these errors were encountered: