34 lines
852 B
YAML
34 lines
852 B
YAML
|
networks:
|
||
|
database:
|
||
|
|
||
|
services:
|
||
|
postgres-server:
|
||
|
image: postgres:${POSTGRES_TAG}
|
||
|
restart: unless-stopped
|
||
|
volumes:
|
||
|
- ${VOLUME_PATH}/var/lib/postgresql/data:/var/lib/postgresql/data:rw
|
||
|
networks:
|
||
|
- database
|
||
|
secrets:
|
||
|
- postgres_db
|
||
|
- postgres_user
|
||
|
- postgres_password
|
||
|
environment:
|
||
|
POSTGRES_DB_FILE: /run/secrets/postgres_db
|
||
|
POSTGRES_USER_FILE: /run/secrets/postgres_user
|
||
|
POSTGRES_PASSWORD_FILE: /run/secrets/postgres_password
|
||
|
zabbix-server:
|
||
|
networks:
|
||
|
- database
|
||
|
environment:
|
||
|
DB_SERVER_HOST: postgres-server
|
||
|
depends_on:
|
||
|
- postgres-server
|
||
|
zabbix-web: # The main Zabbix web UI or interface
|
||
|
networks:
|
||
|
- database
|
||
|
environment: # Postgres database variables
|
||
|
DB_SERVER_HOST: postgres-server
|
||
|
depends_on:
|
||
|
- postgres-server
|