computer-playbook/roles/docker-listmonk/templates/docker-compose.yml.j2

51 lines
1.0 KiB
Plaintext
Raw Normal View History

2023-11-18 14:11:48 +01:00
version: "3.7"
2023-12-05 14:37:50 +01:00
x-application-defaults: &application-defaults
2023-11-18 14:11:48 +01:00
restart: unless-stopped
image: listmonk/listmonk:latest
ports:
2023-12-05 13:46:06 +01:00
- "127.0.0.1:{{http_port}}:9000"
2023-11-18 14:11:48 +01:00
networks:
- listmonk
environment:
- TZ=Etc/UTC
2023-12-05 14:37:50 +01:00
x-database-defaults: &database-defaults
image: postgres:13-alpine
2023-11-18 14:11:48 +01:00
ports:
- "9432:5432"
networks:
- listmonk
environment:
2023-12-05 13:46:06 +01:00
- POSTGRES_PASSWORD={{listmonk_database_password}}
2023-11-18 14:11:48 +01:00
- POSTGRES_USER=listmonk
- POSTGRES_DB=listmonk
restart: unless-stopped
healthcheck:
test: ["CMD-SHELL", "pg_isready -U listmonk"]
interval: 10s
timeout: 5s
retries: 6
services:
2023-12-05 14:37:50 +01:00
database:
<<: *database-defaults
container_name: database
2023-11-18 14:11:48 +01:00
volumes:
- type: volume
source: listmonk-data
target: /var/lib/postgresql/data
2023-12-05 14:37:50 +01:00
application:
<<: *application-defaults
container_name: listmonk_application
2023-11-18 14:11:48 +01:00
depends_on:
2023-12-05 14:37:50 +01:00
- database
2023-11-18 14:11:48 +01:00
volumes:
- ./config.toml:/listmonk/config.toml
2023-12-05 13:46:06 +01:00
2023-11-18 14:11:48 +01:00
networks:
listmonk:
volumes:
listmonk-data: