-
-
Save mizner/56a9581278f2317e18cb1ddcb36793d6 to your computer and use it in GitHub Desktop.
Docker compose V2 static addressing (example?)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
services: | |
haproxy: | |
image: haproxy:latest | |
ports: | |
- "80:80" | |
- "443:443" | |
volumes: | |
- ${PWD}/haproxy/haproxy.cfg:/usr/local/etc/haproxy/haproxy.cfg | |
restart: always | |
networks: | |
- widgets | |
logging: | |
driver: json-file | |
options: | |
max-size: "100m" | |
max-file: "3" | |
labels: "haproxy" | |
mariadb: | |
image: mariadb:latest | |
volumes: | |
- /vol/appdata/mariadb:/var/lib/mysql | |
environment: | |
- MYSQL_ROOT_PASSWORD=secret-pw | |
restart: always | |
networks: | |
- widgets | |
logging: | |
driver: json-file | |
options: | |
max-size: "100m" | |
max-file: "3" | |
labels: "mariadb" | |
app_orangella: | |
image: apache:1.0 | |
restart: always | |
ports: | |
- "81:80" | |
networks: | |
- widgets | |
logging: | |
driver: json-file | |
options: | |
max-size: "50m" | |
max-file: "3" | |
labels: "app_orangella" | |
networks: | |
widgets: | |
driver: bridge | |
ipam: | |
config: | |
- subnet: 172.10.0.0/16 | |
gateway: 172.10.5.254 | |
aux_addresses: | |
haproxy: 172.10.1.2 | |
mariadb: 172.10.1.3 | |
app_orangella: 172.10.1.4 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment