docker-mailman icon indicating copy to clipboard operation
docker-mailman copied to clipboard

Allow chown failures

Open ishitatsuyuki opened this issue 8 years ago • 11 comments

Both mailman-core and mailman-web bails when I mount the configs ro like this:

volumes:
  - ./mailman-extra.cfg:/opt/mailman/mailman-extra.cfg
chown: /opt/mailman/mailman-extra.cfg: Read-only file system
mailman-core exited with code 1

I prefer mounting them because /opt is hard to manage and doesn't scale.

ishitatsuyuki avatar Jul 24 '17 10:07 ishitatsuyuki

To be able to persist the data, you need to mount something at /opt/mailman/ inside the core container which is writable for the container and something at /opt/mailman-web-data inside the web container.

ou can mount ANY two directories at those locations and things should work as long as they are writable by uid 1000 I guess.

maxking avatar Jul 24 '17 10:07 maxking

I use named volumes. (And ro configs on top)

ishitatsuyuki avatar Jul 24 '17 10:07 ishitatsuyuki

Technically, I don't need mailman-extra.cfg to be writable, but I do need /opt/mailman to writable inside core. I might have to investigate more on how to do that, do you have ideas?

maxking avatar Jul 24 '17 10:07 maxking

I would assume other things to break when it's not writable, so I think chown -f is enough.

ishitatsuyuki avatar Jul 24 '17 10:07 ishitatsuyuki

Why not break early instead of waiting for the Mailman to break later?

maxking avatar Jul 24 '17 10:07 maxking

Hey folks, I'm running into this as well:

image

Where I template out that mailman-extra.cfg file using Docker swarm configs (read-only files):

    configs:
      - source: mailman_extra_cfg
        target: /opt/mailman/core/mailman-extra.cfg

And this is failing because of the above mentioned chown issue:

https://github.com/maxking/docker-mailman/blob/9409942a316524b30120713b2888fd9c42c233e7/core/docker-entrypoint.sh#L231

Maybe passing -f is enough? Idk maybe a configurable env var?

decentral1se avatar May 14 '21 15:05 decentral1se

Same issue here, when using docker-mailman in a K8s cluster and mounting mailman-extra.cfg from a config map, there's no way to make it writable. As such, the containers are crash-looping. Either read the extra conf from another location than /opt/mailman (which would make sense IMHO) or support chown failures.

pgmillon avatar Jan 08 '22 09:01 pgmillon

This issue has not been updated for more than 1year

github-actions[bot] avatar Jan 08 '23 22:01 github-actions[bot]