Docker-compose
Docker Compose
Commands:
Example of docker-compose.yml
version: '3'
services:
management:
image: nginx
container_name: management
ports:
- 10.10.10.1:80:80
- 10.10.10.1:443:443
volumes:
- /etc/nginx:/etc/nginx/conf.d/
- /storage:/storage
- /etc/localtime:/etc/localtime:ro
restart: always
extra_hosts:
- "host.docker.internal:host-gateway"
oxidized:
depends_on:
- management
image: oxidized:latest
container_name: oxidized
expose:
- "8888"
volumes:
- /etc/oxidized:/root/.config/oxidized
- /etc/localtime:/etc/localtime:ro
restart: always
command: /root/.config/oxidized/startup.sh
backupmgmt:
depends_on:
- management
image: gunicorn
container_name: backupmgmt
expose:
- "80"
volumes:
- /storage/backupmanagement:/app
- /storage/backup:/storage/backup
command: /app/gunicorn.shSome Errors
nginx: [emerg] host not found in upstream “host.docker.internal:8888” in /etc/nginx/conf.d/nginx.conf:3
Configuration of NGINX:
Solution 1: Using extra_hosts: host.docker.internal
Solution 2
Last updated