Ask a Question
Back to All

Permission denied when accessing secrets


I'm using a public container image and am trying to access secrets in the service. I've added secrets to the Docker environment, and then updated the service to use these secrets.

Docker secret: FB_TOKEN // ******
Service secret configuration: FB_TOKEN // FB_TOKEN.secret

The FB_TOKEN.secret file is available at /var/run/secrets/ at runtime but when the application attempts to access the secret, permission is denied.

The Dockerfile for the container image has configured:
USER root
USER 1000

Please advise.

Start typing markdown or type / to insert a block