I’d like to reuse the certificates generated by SWAG for ejabberd, but when running the container with user: 9000:9000
(recommended user), it can’t read the .pem files:
[error] Failed to read PEM file /opt/ejabberd/conf/privkey.pem: permission denied
Here’s how the certificates are mounted:
services:
ejabberd:
image: ghcr.io/processone/ejabberd:latest
container_name: ejabberd
environment:
UID: 1000
GID: 1000
volumes:
- ejabberd/db:/opt/ejabberd/database
- ejabberd/config/ejabberd.yml:/opt/ejabberd/conf/ejabberd.yml
- swag/config/etc/letsencrypt/live/domain.example/fullchain.pem:/opt/ejabberd/conf/fullchain.pem:ro
- swag/config/etc/letsencrypt/live/domain.example/privkey.pem:/opt/ejabberd/conf/privkey.pem:ro
Does anyone have any idea if it is indeed possible?