Root cause of the compose-smoke failure (found in the runner logs):
oz-init-1 | CommandError: Yaml file
`/app/setup_configuration/data.yaml` does not exist.
The ubuntu-latest runner runs the job inside a container, so
`docker compose up` starts the stack as SIBLING containers via the host
daemon. A relative bind mount (./openzaak/setup_configuration) resolves to
a path inside the job container that the daemon can't see, so Docker mounts
an empty dir and the init container can't find data.yaml. The same trap hit
nrc-init (data.yaml), flowable-init (the BPMN) and keycloak (realm import).
Fix: bake the assets into small derived images instead of bind-mounting:
- infra/openzaak/Dockerfile -> register-referentie/openzaak:dev
- infra/opennotificaties/Dockerfile-> register-referentie/opennotificaties:dev
- infra/keycloak/Dockerfile -> register-referentie/keycloak:dev
- flowable-init: build.dockerfile_inline bakes workflows/registratie.bpmn
Base versions stay build args (OPENZAAK_TAG / OPENNOTIFICATIES_TAG), so the
pinning is unchanged. Applied to both the consolidated compose and the
per-service composes, so local Podman and CI use one mechanism — no bind
mounts, no SELinux `:z`, no world-readable requirement.
Verified locally: `podman build` of the OpenZaak and BPMN images produces
the file at the expected in-container path.
Docs: docs/runbooks/gitea-actions-gotchas.md explains the DinD bind-mount
trap and the bake fix; openzaak.md and ci.md point at it.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
72 lines
2.5 KiB
YAML
72 lines
2.5 KiB
YAML
# Flowable (S-03): the flowable-rest engine on Postgres.
|
|
# The registratie.bpmn model is deployed via the REST API on startup by flowable-init.
|
|
#
|
|
# docker compose -f infra/flowable/docker-compose.yml up -d
|
|
# # REST API (basic auth) under http://localhost:8090/flowable-rest/service/
|
|
#
|
|
# Host port 8090 (8000/8001/8080/8180 are taken by OpenZaak/NRC/BFF/Keycloak).
|
|
services:
|
|
flowable-db:
|
|
image: docker.io/library/postgres:16
|
|
environment:
|
|
POSTGRES_USER: flowable
|
|
POSTGRES_PASSWORD: flowable
|
|
POSTGRES_DB: flowable
|
|
volumes:
|
|
- flowable-db:/var/lib/postgresql/data
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U flowable -d flowable"]
|
|
interval: 5s
|
|
timeout: 3s
|
|
retries: 10
|
|
networks: [cg]
|
|
|
|
flowable-rest:
|
|
image: docker.io/flowable/flowable-rest:latest
|
|
environment:
|
|
SPRING_DATASOURCE_DRIVER-CLASS-NAME: org.postgresql.Driver
|
|
SPRING_DATASOURCE_URL: jdbc:postgresql://flowable-db:5432/flowable
|
|
SPRING_DATASOURCE_USERNAME: flowable
|
|
SPRING_DATASOURCE_PASSWORD: flowable
|
|
ports:
|
|
- "8090:8080"
|
|
depends_on:
|
|
flowable-db:
|
|
condition: service_healthy
|
|
networks: [cg]
|
|
|
|
# Deploys workflows/registratie.bpmn via the REST API once flowable-rest is up.
|
|
# Idempotent: skips if a deployment named "registratie" already exists.
|
|
flowable-init:
|
|
# The BPMN is baked into a tiny curl image (build context = repo-root
|
|
# workflows/) instead of bind-mounted, so the deploy works on Gitea's
|
|
# containerized runner too. See docs/runbooks/gitea-actions-gotchas.md.
|
|
build:
|
|
context: ../../workflows
|
|
dockerfile_inline: |
|
|
FROM docker.io/curlimages/curl:latest
|
|
COPY registratie.bpmn /work/registratie.bpmn
|
|
image: register-referentie/flowable-init:dev
|
|
restart: "no"
|
|
command:
|
|
- sh
|
|
- -c
|
|
- |
|
|
base=http://flowable-rest:8080/flowable-rest/service/repository/deployments
|
|
until curl -sf -u rest-admin:test "$$base" >/dev/null 2>&1; do echo "waiting for flowable-rest..."; sleep 3; done
|
|
if curl -s -u rest-admin:test "$$base?name=registratie" | grep -q '"name":"registratie"'; then
|
|
echo "registratie already deployed; skip"
|
|
else
|
|
curl -sf -u rest-admin:test -F 'file=@/work/registratie.bpmn;filename=registratie.bpmn' "$$base" >/dev/null && echo "deployed registratie"
|
|
fi
|
|
depends_on:
|
|
flowable-rest:
|
|
condition: service_started
|
|
networks: [cg]
|
|
|
|
volumes:
|
|
flowable-db:
|
|
|
|
networks:
|
|
cg:
|