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

60 lines
1.2 KiB
Plaintext
Raw Normal View History

2022-11-16 11:17:37 +01:00
version: '2'
services:
application:
image: zknt/pixelfed
2023-01-09 15:59:36 +01:00
restart: always
2022-11-16 11:17:37 +01:00
logging:
driver: journald
env_file:
- ./env
volumes:
- "application_data:/var/www/storage"
2023-12-10 16:24:43 +01:00
- "bootstrap:/var/www/bootstrap"
2022-11-16 11:17:37 +01:00
- "./env:/var/www/.env"
ports:
- "{{http_port}}:80"
depends_on:
- database
- redis
worker:
image: zknt/pixelfed
2023-01-09 15:59:36 +01:00
restart: always
2022-11-16 11:17:37 +01:00
logging:
driver: journald
env_file:
- ./env
volumes:
- "application_data:/var/www/storage"
2023-12-10 16:24:43 +01:00
- "bootstrap:/var/www/bootstrap"
2022-11-16 11:17:37 +01:00
- "./env:/var/www/.env"
entrypoint: /worker-entrypoint.sh
depends_on:
- database
- redis
- application
2022-11-16 11:17:37 +01:00
healthcheck:
test: php artisan horizon:status | grep running
interval: 60s
timeout: 5s
retries: 1
{% include 'templates/docker-mariadb-service.yml.j2' %}
2022-11-16 11:17:37 +01:00
redis:
image: redis:alpine
restart: always
logging:
driver: journald
volumes:
- redis_data:/data
2022-11-16 11:17:37 +01:00
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 1s
timeout: 3s
retries: 30
volumes:
database:
redis_data:
2023-12-10 16:24:43 +01:00
application_data:
bootstrap: