2024-01-03 11:38:09 +01:00
|
|
|
x-op-app: &app
|
2024-04-04 12:24:58 +02:00
|
|
|
logging:
|
|
|
|
driver: journald
|
2024-01-14 14:10:36 +01:00
|
|
|
image: custom_openproject
|
2023-12-24 18:48:38 +01:00
|
|
|
environment:
|
2023-12-31 11:14:18 +01:00
|
|
|
OPENPROJECT_HTTPS: "${OPENPROJECT_HTTPS}"
|
|
|
|
OPENPROJECT_HOST__NAME: "${OPENPROJECT_HOST__NAME}"
|
2023-12-24 18:48:38 +01:00
|
|
|
OPENPROJECT_HSTS: "${OPENPROJECT_HSTS:-true}"
|
|
|
|
RAILS_CACHE_STORE: "memcache"
|
|
|
|
OPENPROJECT_CACHE__MEMCACHE__SERVER: "cache:11211"
|
|
|
|
OPENPROJECT_RAILS__RELATIVE__URL__ROOT: "${OPENPROJECT_RAILS__RELATIVE__URL__ROOT:-}"
|
2023-12-30 15:22:18 +01:00
|
|
|
DATABASE_URL: "${DATABASE_URL}"
|
2023-12-24 18:48:38 +01:00
|
|
|
RAILS_MIN_THREADS: ${RAILS_MIN_THREADS:-4}
|
|
|
|
RAILS_MAX_THREADS: ${RAILS_MAX_THREADS:-16}
|
|
|
|
# set to true to enable the email receiving feature. See ./docker/cron for more options
|
|
|
|
IMAP_ENABLED: "${IMAP_ENABLED:-false}"
|
|
|
|
volumes:
|
2023-12-31 11:14:18 +01:00
|
|
|
- "data:/var/openproject/assets"
|
2024-01-13 21:38:02 +01:00
|
|
|
- "{{dummy_volume}}:/var/openproject/pgdata" # This mount is unnecessary and just done to prevent anonymous volumes
|
2023-12-24 18:48:38 +01:00
|
|
|
|
|
|
|
services:
|
2023-12-31 11:14:18 +01:00
|
|
|
|
2024-01-19 15:12:18 +01:00
|
|
|
{% include 'templates/docker/services/' + database_type + '.yml.j2' %}
|
2023-12-24 18:48:38 +01:00
|
|
|
|
|
|
|
cache:
|
|
|
|
image: memcached
|
2024-01-14 14:10:36 +01:00
|
|
|
container_name: openproject-memcached
|
2024-01-12 20:57:58 +01:00
|
|
|
restart: {{docker_restart_policy}}
|
2024-04-04 12:24:58 +02:00
|
|
|
logging:
|
|
|
|
driver: journald
|
2024-01-19 15:12:18 +01:00
|
|
|
{% include 'templates/docker/container/networks.yml.j2' %}
|
2023-12-24 18:48:38 +01:00
|
|
|
|
|
|
|
proxy:
|
2024-01-12 20:57:58 +01:00
|
|
|
restart: {{docker_restart_policy}}
|
2024-04-04 12:24:58 +02:00
|
|
|
logging:
|
|
|
|
driver: journald
|
2024-01-14 14:10:36 +01:00
|
|
|
image: custom_openproject
|
|
|
|
container_name: openproject-proxy
|
2023-12-24 18:48:38 +01:00
|
|
|
command: "./docker/prod/proxy"
|
|
|
|
ports:
|
2023-12-31 11:14:18 +01:00
|
|
|
- "${PORT}:80"
|
2023-12-24 18:48:38 +01:00
|
|
|
environment:
|
|
|
|
APP_HOST: web
|
|
|
|
OPENPROJECT_RAILS__RELATIVE__URL__ROOT: "${OPENPROJECT_RAILS__RELATIVE__URL__ROOT:-}"
|
|
|
|
depends_on:
|
|
|
|
- web
|
2024-01-19 15:12:18 +01:00
|
|
|
{% include 'templates/docker/container/networks.yml.j2' %}
|
2023-12-24 21:42:32 +01:00
|
|
|
volumes:
|
2023-12-31 11:14:18 +01:00
|
|
|
- "data:/var/openproject/assets"
|
2024-01-13 21:38:02 +01:00
|
|
|
- "{{dummy_volume}}:/var/openproject/pgdata" # This mount is unnecessary and just done to prevent anonymous volumes
|
2023-12-31 11:44:21 +01:00
|
|
|
|
2023-12-24 18:48:38 +01:00
|
|
|
web:
|
|
|
|
<<: *app
|
2024-04-04 12:24:58 +02:00
|
|
|
restart: {{docker_restart_policy}}
|
2023-12-24 18:48:38 +01:00
|
|
|
command: "./docker/prod/web"
|
2024-01-14 14:10:36 +01:00
|
|
|
container_name: openproject-web
|
2024-01-19 15:12:18 +01:00
|
|
|
{% include 'templates/docker/container/networks.yml.j2' %}
|
|
|
|
{% include 'templates/docker/container/depends-on-also-database.yml.j2' %}
|
2024-01-02 21:13:34 +01:00
|
|
|
cache:
|
2024-01-05 20:44:43 +01:00
|
|
|
condition: service_started
|
2024-01-02 21:13:34 +01:00
|
|
|
seeder:
|
2024-01-05 20:44:43 +01:00
|
|
|
condition: service_started
|
2023-12-24 18:48:38 +01:00
|
|
|
labels:
|
|
|
|
- autoheal=true
|
|
|
|
healthcheck:
|
|
|
|
test: ["CMD", "curl", "-f", "http://localhost:8080${OPENPROJECT_RAILS__RELATIVE__URL__ROOT:-}/health_checks/default"]
|
|
|
|
interval: 10s
|
|
|
|
timeout: 3s
|
|
|
|
retries: 3
|
|
|
|
start_period: 30s
|
|
|
|
|
|
|
|
autoheal:
|
|
|
|
image: willfarrell/autoheal:1.2.0
|
2024-01-14 14:10:36 +01:00
|
|
|
container_name: openproject-autoheal
|
2024-04-04 12:24:58 +02:00
|
|
|
restart: {{docker_restart_policy}}
|
|
|
|
logging:
|
|
|
|
driver: journald
|
2023-12-24 18:48:38 +01:00
|
|
|
volumes:
|
|
|
|
- "/var/run/docker.sock:/var/run/docker.sock"
|
|
|
|
environment:
|
|
|
|
AUTOHEAL_CONTAINER_LABEL: autoheal
|
|
|
|
AUTOHEAL_START_PERIOD: 600
|
|
|
|
AUTOHEAL_INTERVAL: 30
|
|
|
|
|
|
|
|
worker:
|
|
|
|
<<: *app
|
2024-04-04 12:24:58 +02:00
|
|
|
restart: {{docker_restart_policy}}
|
2023-12-24 18:48:38 +01:00
|
|
|
command: "./docker/prod/worker"
|
2024-01-14 14:10:36 +01:00
|
|
|
container_name: openproject-worker
|
2024-01-19 15:12:18 +01:00
|
|
|
{% include 'templates/docker/container/networks.yml.j2' %}
|
|
|
|
{% include 'templates/docker/container/depends-on-also-database.yml.j2' %}
|
2024-01-02 21:13:34 +01:00
|
|
|
cache:
|
2024-01-05 20:44:43 +01:00
|
|
|
condition: service_started
|
2024-01-02 21:13:34 +01:00
|
|
|
seeder:
|
2024-01-05 20:44:43 +01:00
|
|
|
condition: service_started
|
2023-12-24 18:48:38 +01:00
|
|
|
|
|
|
|
cron:
|
|
|
|
<<: *app
|
2024-04-04 12:24:58 +02:00
|
|
|
restart: {{docker_restart_policy}}
|
2023-12-24 18:48:38 +01:00
|
|
|
command: "./docker/prod/cron"
|
2024-01-14 14:10:36 +01:00
|
|
|
container_name: openproject-cron
|
2024-01-19 15:12:18 +01:00
|
|
|
{% include 'templates/docker/container/networks.yml.j2' %}
|
|
|
|
{% include 'templates/docker/container/depends-on-also-database.yml.j2' %}
|
2024-01-02 21:13:34 +01:00
|
|
|
cache:
|
2024-01-05 20:44:43 +01:00
|
|
|
condition: service_started
|
2024-01-02 21:13:34 +01:00
|
|
|
seeder:
|
2024-01-05 20:44:43 +01:00
|
|
|
condition: service_started
|
2023-12-24 18:48:38 +01:00
|
|
|
|
|
|
|
seeder:
|
|
|
|
<<: *app
|
|
|
|
command: "./docker/prod/seeder"
|
2024-01-14 14:10:36 +01:00
|
|
|
container_name: openproject-seeder
|
2023-12-24 18:48:38 +01:00
|
|
|
restart: on-failure
|
2024-01-19 15:12:18 +01:00
|
|
|
{% include 'templates/docker/container/networks.yml.j2' %}
|
2024-01-03 11:38:09 +01:00
|
|
|
|
2024-01-19 15:12:18 +01:00
|
|
|
{% include 'templates/docker/compose/networks.yml.j2' %}
|
2024-01-03 11:38:09 +01:00
|
|
|
|
2024-01-19 15:12:18 +01:00
|
|
|
{% include 'templates/docker/compose/volumes.yml.j2' %}
|
2024-01-03 11:38:09 +01:00
|
|
|
data:
|