Restructured code and matrix rol

This commit is contained in:
2024-01-19 15:12:18 +01:00
parent 0aebca62f6
commit c4209f0559
64 changed files with 249 additions and 224 deletions

View File

@@ -1,6 +1,6 @@
---
- name: "include docker-compose-database.yml"
include_tasks: docker-compose-database.yml
- name: "include docker/compose/database.yml"
include_tasks: docker/compose/database.yml
- name: "include tasks nginx-docker-proxy-domain.yml"
include_tasks: nginx-docker-proxy-domain.yml

View File

@@ -21,13 +21,13 @@ x-op-app: &app
services:
{% include 'templates/docker-service-' + database_type + '.yml.j2' %}
{% include 'templates/docker/services/' + database_type + '.yml.j2' %}
cache:
image: memcached
container_name: openproject-memcached
restart: {{docker_restart_policy}}
{% include 'templates/docker-container-networks.yml.j2' %}
{% include 'templates/docker/container/networks.yml.j2' %}
proxy:
restart: {{docker_restart_policy}}
@@ -41,7 +41,7 @@ services:
OPENPROJECT_RAILS__RELATIVE__URL__ROOT: "${OPENPROJECT_RAILS__RELATIVE__URL__ROOT:-}"
depends_on:
- web
{% include 'templates/docker-container-networks.yml.j2' %}
{% include 'templates/docker/container/networks.yml.j2' %}
volumes:
- "data:/var/openproject/assets"
- "{{dummy_volume}}:/var/openproject/pgdata" # This mount is unnecessary and just done to prevent anonymous volumes
@@ -50,8 +50,8 @@ services:
<<: *app
command: "./docker/prod/web"
container_name: openproject-web
{% include 'templates/docker-container-networks.yml.j2' %}
{% include 'templates/docker-container-depends-on-also-database.yml.j2' %}
{% include 'templates/docker/container/networks.yml.j2' %}
{% include 'templates/docker/container/depends-on-also-database.yml.j2' %}
cache:
condition: service_started
seeder:
@@ -79,8 +79,8 @@ services:
<<: *app
command: "./docker/prod/worker"
container_name: openproject-worker
{% include 'templates/docker-container-networks.yml.j2' %}
{% include 'templates/docker-container-depends-on-also-database.yml.j2' %}
{% include 'templates/docker/container/networks.yml.j2' %}
{% include 'templates/docker/container/depends-on-also-database.yml.j2' %}
cache:
condition: service_started
seeder:
@@ -90,8 +90,8 @@ services:
<<: *app
command: "./docker/prod/cron"
container_name: openproject-cron
{% include 'templates/docker-container-networks.yml.j2' %}
{% include 'templates/docker-container-depends-on-also-database.yml.j2' %}
{% include 'templates/docker/container/networks.yml.j2' %}
{% include 'templates/docker/container/depends-on-also-database.yml.j2' %}
cache:
condition: service_started
seeder:
@@ -102,9 +102,9 @@ services:
command: "./docker/prod/seeder"
container_name: openproject-seeder
restart: on-failure
{% include 'templates/docker-container-networks.yml.j2' %}
{% include 'templates/docker/container/networks.yml.j2' %}
{% include 'templates/docker-compose-networks.yml.j2' %}
{% include 'templates/docker/compose/networks.yml.j2' %}
{% include 'templates/docker-compose-volumes.yml.j2' %}
{% include 'templates/docker/compose/volumes.yml.j2' %}
data:

View File

@@ -2,7 +2,7 @@ docker_compose_project_name: "openproject"
repository_directory: "{{ path_docker_compose_instances }}{{docker_compose_project_name}}/"
docker_compose_instance_directory: "{{repository_directory}}compose/"
docker_compose_file_path: "{{docker_compose_instance_directory}}docker-compose.yml"
docker_compose_backup_path: "/tmp/{{docker_compose_project_name}}-docker-compose-backup.yml"
docker_compose_backup_path: "/tmp/{{docker_compose_project_name}}-docker/compose/backup.yml"
database_password: "{{openproject_database_password}}"
repository_address: "https://github.com/opf/openproject-deploy"
database_type: "postgres"