Compare commits

...

12 Commits

6 changed files with 63 additions and 17 deletions
+7 -1
View File
@@ -19,4 +19,10 @@ SMTP_HOST=127.0.0.71
SMTP_USER=pretix
SMTP_PORT=1025
SMTP_TLS=on
SMTP_SSL=off
SMTP_SSL=off
# --- Optional: Custom Plugin Image ---
# Set COMPOSE_FILE and PRETIX_PLUGIN_IMAGE_TAG to use custom plugins:
#
# COMPOSE_FILE=compose.yml:compose.plugin.yml
# PRETIX_PLUGIN_IMAGE_TAG=1.0.0
+23 -1
View File
@@ -26,6 +26,28 @@
For more, see [`docs.coopcloud.tech`](https://docs.coopcloud.tech).
## Plugins
1. Build or obtain a plugin bundle image.
Use the [pretix-plugins Repository](https://git.coopcloud.tech/coop-cloud/pretix-plugins) to build an image containing the plugins you need, or use an existing published image.
2. Set the following variables in your app .env:
```
COMPOSE_FILE=compose.yml:compose.plugin.yml
PRETIX_PLUGIN_IMAGE=git.coopcloud.tech/your-org/pretix-plugins:1.0.0
```
3. Deploy as usual:
`abra app deploy <app-name>`
### How the override works
`compose.plugin.yml` is an optional compose file that overrides only the `image:` field of the app service. Docker Compose merges the two files at deploy time. If `PRETIX_PLUGIN_IMAGE` is not set, the standard pretix/standalone:stable
image is used as a fallback, so the override file can be included without risk.
### Operators without plugins
No action required. As long as `COMPOSE_FILE` and `PRETIX_PLUGIN_IMAGE` are not set in your `.env`, the standard pretix image is used. This override has no effect on your deployment.
### Building your own plugin bundle
See the [pretix-plugins Repository](https://git.coopcloud.tech/coop-cloud/pretix-plugins) `README` for instructions on how to add or change the plugins you want to use.
## TODO
@@ -33,4 +55,4 @@ For more, see [`docs.coopcloud.tech`](https://docs.coopcloud.tech).
* [x] healthchecks
* [x] cronjob: 15,45 * * * * /usr/bin/docker exec pretix.service pretix cron
* [x] backups https://docs.pretix.eu/en/latest/admin/maintainance.html#maintainance
* [ ] plugins
* [x] plugins
+5
View File
@@ -14,3 +14,8 @@ u.save()
"""
echo "Changed admin password"
}
fix_collation_mismatch() {
psql -U ${POSTGRES_USER} -d ${POSTGRES_DB} -c "ALTER DATABASE ${POSTGRES_DB} REFRESH COLLATION VERSION;"
psql -U ${POSTGRES_USER} -d ${POSTGRES_DB} -c "REINDEX DATABASE ${POSTGRES_DB};"
}
+8
View File
@@ -0,0 +1,8 @@
# compose.plugin.yml
# Optional Override: Changes the Standard-Pretix Image with an Image with preinstalled custom plugins.
# Set active via setting: COMPOSE_FILE=compose.yml:compose.plugin.yml
version: "3.8"
services:
app:
image: git.coopcloud.tech/coop-cloud/pretix-plugins:${PRETIX_PLUGIN_IMAGE_TAG:-latest}
+19 -15
View File
@@ -3,7 +3,7 @@ version: "3.8"
services:
app:
image: 'pretix/standalone:2025.8.0'
image: "pretix/standalone:2026.5.1"
networks:
- proxy
- internal
@@ -19,20 +19,20 @@ services:
- admin_pass
deploy:
restart_policy:
condition: on-failure
condition: any
labels:
- "traefik.enable=true"
- "traefik.http.services.${STACK_NAME}.loadbalancer.server.port=80"
- "traefik.http.routers.${STACK_NAME}.rule=Host(`${DOMAIN}`${EXTRA_DOMAINS})"
- "traefik.http.routers.${STACK_NAME}.entrypoints=web-secure"
- "traefik.http.routers.${STACK_NAME}.tls.certresolver=${LETS_ENCRYPT_ENV}"
- "coop-cloud.${STACK_NAME}.version=2.2.0+2025.8.0"
- "coop-cloud.${STACK_NAME}.version=2.7.0+2026.5.1"
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost/healthcheck"]
interval: 30s
timeout: 10s
retries: 10
start_period: 1m
retries: 30
start_period: 5m
db:
image: postgres:16
@@ -55,26 +55,32 @@ services:
mode: 0555
entrypoint: /docker-entrypoint.sh
healthcheck:
test: ["CMD-SHELL", "[ -f $${HEALTHCHECK_MARKER} ] || pg_isready -d $${POSTGRES_DB} -U $${POSTGRES_USER}"]
interval: 10s
test:
[
"CMD-SHELL",
"[ -f $${HEALTHCHECK_MARKER} ] || pg_isready -d $${POSTGRES_DB} -U $${POSTGRES_USER}",
]
interval: 30s
timeout: 5s
retries: 5
retries: 20
start_period: 1m
deploy:
labels:
backupbot.backup: "${ENABLE_BACKUPS:-true}"
backupbot.backup.pre-hook: "/pg_backup.sh backup"
backupbot.backup.pre-hook: "/pg_backup.sh backup"
backupbot.backup.volumes.postgres.path: "backup.sql"
backupbot.restore.post-hook: '/pg_backup.sh restore'
backupbot.restore.post-hook: "/pg_backup.sh restore"
redis:
image: redis:8.0.2-alpine
image: redis:8.8.0-alpine
volumes:
- "redis:/data"
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 3s
interval: 20s
timeout: 5s
retries: 20
start_period: 1m
networks:
- internal
@@ -84,8 +90,7 @@ services:
- STACK_NAME=${STACK_NAME}
volumes:
- /var/run/docker.sock:/var/run/docker.sock
entrypoint:
/entrypoint.sh
entrypoint: /entrypoint.sh
configs:
- source: cron_entrypoint
target: /entrypoint.sh
@@ -117,7 +122,6 @@ networks:
external: true
internal:
secrets:
db_password:
external: true
+1
View File
@@ -0,0 +1 @@
New envs for COMPOSE_FILE and PRETIX_PLUGIN_IMAGE and a compose.plugin.yml to add custom plugins in the pretix-plugins coop-cloud repository.