Docker Compose file · Environment and secrets
Mount a config file
Provide a configuration file to a service.
services:
proxy:
image: nginx:1.27
configs:
- source: nginx_conf
target: /etc/nginx/nginx.conf
configs:
nginx_conf:
file: ./nginx.conf
Official Docker Compose file documentation
More environment and secrets commands
All environment and secrets commands · Docker Compose file cheatsheet