pretalx-docker-formula/pretalx-docker/init.sls

38 lines
1.1 KiB
Text
Raw Permalink Normal View History

2024-07-30 20:48:43 +02:00
pretalx-data-directory-exists:
file.directory:
2024-08-06 21:28:07 +02:00
- user: 999
- group: 999
2024-08-06 20:05:01 +02:00
- name: /opt/pretalx/data
- makedirs: True
pretalx-public-directory-exists:
file.directory:
2024-08-06 21:28:07 +02:00
- user: 999
- group: 999
2024-08-06 20:05:01 +02:00
- name: /opt/pretalx/public
2024-07-30 20:48:43 +02:00
- makedirs: True
pretalx-config-file-is-present:
file.managed:
- name: /opt/pretalx/pretalx.cfg
2024-08-06 20:52:41 +02:00
- source: salt://pretalx-docker/pretalx.cfg.jinja
2024-07-30 20:48:43 +02:00
- template: jinja
pretalx-docker-container-running:
docker_container.running:
- name: pretalx
2024-08-06 20:51:36 +02:00
- image: {{ salt['pillar.get']('pretalx:image:path', 'docker.io/pretalx/standalone') }}:{{ salt['pillar.get']('pretalx:image:version', 'v2024.1.0') }}
2024-07-30 20:48:43 +02:00
- container_name: pretalx
- environment:
- PRETALX_FILESYSTEM_MEDIA=/public/media
- PRETALX_FILESYSTEM_STATIC=/public/static
- restart: always
- networks:
- bridge
- binds:
- /opt/pretalx/pretalx.cfg:/etc/pretalx/pretalx.cfg:ro
2024-08-06 20:05:01 +02:00
- /opt/pretalx/data:/data
- /opt/pretalx/public:/public
2024-07-30 20:48:43 +02:00
- port_bindings:
2024-08-06 20:05:01 +02:00
- "{{ salt['pillar.get']('pretalx:container_web_port', "127.0.0.1:3000") }}:80"