#!/usr/bin/env bash # Renders setup_configuration/data.prod.yaml.template into the gitignored # data.prod.yaml docker-compose.openzaak.prod.yml mounts over the container's data.yaml. # Run this once before `docker compose ... up` in a production deploy; re-run whenever the # secrets rotate. Fails fast (no output file) if a required env var is missing — never # silently falls back to a real-looking default. set -euo pipefail cd "$(dirname "${BASH_SOURCE[0]}")" : "${OPENZAAK_SITE_DOMAIN:?OPENZAAK_SITE_DOMAIN must be set (e.g. open-zaak.example.org)}" : "${OPENZAAK_CLIENT_ID:?OPENZAAK_CLIENT_ID must be set}" : "${OPENZAAK_CLIENT_SECRET:?OPENZAAK_CLIENT_SECRET must be set}" : "${OPENZAAK_APPLICATIE_UUID:?OPENZAAK_APPLICATIE_UUID must be set (a fresh UUID, e.g. \$(uuidgen))}" envsubst < setup_configuration/data.prod.yaml.template > setup_configuration/data.prod.yaml echo "Wrote setup_configuration/data.prod.yaml"