# SPDX-FileCopyrightText: 2026 Bart Broere # SPDX-License-Identifier: GPL-3.0-or-later # # boltage, PostgreSQL with Apache AGE and pgAdmin as separate containers. boltage runs # from the slim image (see Containerfile). Start with: # # POSTGRES_PASSWORD=secret podman compose up -d # # or put POSTGRES_PASSWORD in a .env file next to this one. name: boltage services: postgres: image: docker.io/apache/age:release_PG18_1.8.0 command: ["postgres", "-c", "shared_preload_libraries=age"] environment: POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:?Set POSTGRES_PASSWORD, for example in a .env file} BOLTAGE_DEFAULT_GRAPH: ${BOLTAGE_DEFAULT_GRAPH:-neo4j} volumes: - postgres-data:/var/lib/postgresql # Creates the default graph when the database is initialised. - ./container/initdb/10-boltage.sh:/docker-entrypoint-initdb.d/10-boltage.sh:ro ports: - "${BOLTAGE_POSTGRES_PORT:-5432}:5432" healthcheck: # Over TCP, so the temporary server that runs the init scripts does not count. test: ["CMD", "pg_isready", "--host", "127.0.0.1", "--username", "postgres"] interval: 5s timeout: 5s retries: 20 boltage: build: context: . dockerfile: Containerfile target: slim image: localhost/boltage:slim environment: BOLTAGE_PG_HOST: postgres BOLTAGE_PG_DATABASE: postgres BOLTAGE_DEFAULT_GRAPH: ${BOLTAGE_DEFAULT_GRAPH:-neo4j} BOLTAGE_LOG_LEVEL: ${BOLTAGE_LOG_LEVEL:-INFO} ports: - "7474:7474" - "7687:7687" depends_on: postgres: condition: service_healthy pgadmin: image: docker.io/dpage/pgadmin4:9.18 environment: PGADMIN_DEFAULT_EMAIL: ${PGADMIN_DEFAULT_EMAIL:-admin@example.com} PGADMIN_DEFAULT_PASSWORD: ${PGADMIN_DEFAULT_PASSWORD:-${POSTGRES_PASSWORD}} PGADMIN_CONFIG_UPGRADE_CHECK_ENABLED: "False" volumes: - pgadmin-data:/var/lib/pgadmin # Registers the postgres service on first start. - ./container/pgadmin/compose-servers.json:/pgadmin4/servers.json:ro ports: - "5050:80" depends_on: postgres: condition: service_healthy volumes: postgres-data: pgadmin-data: