ansible-infra/templates/chaosknoten/configs/pretalx/compose.yaml.j2
June f16f8697c2
move roles, files and templates dirs out of playbook dir into root dir
Because of how Ansible local relative search paths work, the global
"files" and "templates" directories need to be next to the playbooks.
However its not intuitive to look into the "playbooks" directory to find
the files and templates for a host.
Therefore move them out of the "playbooks" directory into the root
directory and add symlinks so everything still works.

Similarly for local roles, they also need to be next to the playbooks.
So for a nicer structure, move the "roles" directory out into the root
directory as well and add a symlink so everything still works.

Also see:
https://docs.ansible.com/ansible/latest/playbook_guide/playbook_pathing.html#resolving-local-relative-paths
https://docs.ansible.com/ansible/latest/playbook_guide/playbooks_reuse_roles.html#storing-and-finding-roles
2024-12-08 02:55:25 +01:00

106 lines
3.3 KiB
Django/Jinja

---
# see https://github.com/pretalx/pretalx-docker/blob/main/docker-compose.yml
services:
database:
image: docker.io/library/postgres:15-alpine
environment:
- "POSTGRES_USER=pretalx"
- "POSTGRES_PASSWORD={{ lookup("community.general.passwordstore", "noc/vm-secrets/chaosknoten/pretalx/DB_PASSWORD", create=false, missing="error") }}"
- "POSTGRES_DB=pretalx"
volumes:
- database:/var/lib/postgresql/data
restart: unless-stopped
redis:
image: redis:latest
restart: unless-stopped
volumes:
- redis:/data
static:
image: docker.io/library/nginx
restart: unless-stopped
volumes:
- public:/usr/share/nginx/html
ports:
- 8081:80
pretalx:
image: pretalx/standalone:latest
entrypoint: gunicorn
command:
- "pretalx.wsgi"
- "--name"
- "pretalx"
- "--workers"
- "4"
- "--max-requests"
- "1200"
- "--max-requests-jitter"
- "50"
- "--log-level=info"
- "--bind=0.0.0.0:8080"
ports:
- 8080:8080
restart: unless-stopped
environment:
PRETALX_DATA_DIR: /data
PRETALX_FILESYSTEM_MEDIA: /public/media
PRETALX_FILESYSTEM_STATIC: /public/static
PRETALX_SITE_URL: https://pretalx.hamburg.ccc.de
PRETALX_DB_TYPE: postgresql
PRETALX_DB_NAME: pretalx
PRETALX_DB_USER: pretalx
PRETALX_DB_PASS: "{{ lookup("community.general.passwordstore", "noc/vm-secrets/chaosknoten/pretalx/DB_PASSWORD", create=false, missing="error") }}"
PRETALX_DB_HOST: database
PRETALX_MAIL_FROM: "pretalx@hamburg.ccc.de"
PRETALX_MAIL_HOST: "cow-intern.hamburg.ccc.de"
PRETALX_CELERY_BACKEND: redis://redis/1
PRETALX_CELERY_BROKER: redis://redis/2
PRETALX_REDIS: redis://redis/3
PRETALX_REDIS_SESSIONS: "True"
# PRETALX_LOGGING_EMAIL: noc@hamburg.ccc.de
PRETALX_LANGUAGE_CODE: de
PRETALX_TIME_ZONE: Europe/Berlin
volumes:
- pretalx:/data
- public:/public
celery:
image: pretalx/standalone:latest
command:
- taskworker
restart: unless-stopped
environment:
PRETALX_DATA_DIR: /data
PRETALX_FILESYSTEM_MEDIA: /public/media
PRETALX_FILESYSTEM_STATIC: /public/static
PRETALX_SITE_URL: https://pretalx.hamburg.ccc.de
PRETALX_DB_TYPE: postgresql
PRETALX_DB_NAME: pretalx
PRETALX_DB_USER: pretalx
PRETALX_DB_PASS: "{{ lookup("community.general.passwordstore", "noc/vm-secrets/chaosknoten/pretalx/DB_PASSWORD", create=false, missing="error") }}"
PRETALX_DB_HOST: database
PRETALX_MAIL_FROM: "pretalx@hamburg.ccc.de"
PRETALX_MAIL_HOST: "cow.hamburg.ccc.de"
PRETALX_MAIL_PORT: 587
PRETALX_MAIL_USER: pretalx@hamburg.ccc.de
PRETALX_MAIL_PASSWORD: "{{ lookup("community.general.passwordstore", "noc/vm-secrets/chaosknoten/pretalx/PRETALX_MAIL_PASSWORD", create=false, missing="error") }}"
PRETALX_MAIL_TLS: "true"
PRETALX_CELERY_BACKEND: redis://redis/1
PRETALX_CELERY_BROKER: redis://redis/2
PRETALX_REDIS: redis://redis/3
PRETALX_REDIS_SESSIONS: "True"
# PRETALX_LOGGING_EMAIL: noc@hamburg.ccc.de
PRETALX_LANGUAGE_CODE: de
PRETALX_TIME_ZONE: Europe/Berlin
volumes:
- pretalx:/data
- public:/public
volumes:
database: {}
redis: {}
pretalx: {}
public: {}