update with latest build versions, includes custom build for postgres and migrating from v16 to v18

This commit is contained in:
2026-01-14 22:33:45 +02:00
parent 8ff8126d41
commit 9f7fa24931
27 changed files with 1371 additions and 309 deletions

View File

@@ -0,0 +1,36 @@
# Docker Compose for local testing of PostgreSQL 18 + PostGIS image
#
# Usage:
# docker-compose -f docker-compose.test.yaml up -d
# docker-compose -f docker-compose.test.yaml exec postgres psql -U postgres
# docker-compose -f docker-compose.test.yaml down -v
#
# NOTE: PostgreSQL 18 changed the data directory path!
# PG 13-17: /var/lib/postgresql/data
# PG 18+: /var/lib/postgresql
#
version: '3.8'
services:
postgres:
image: cnpg-postgis:18-3.6
platform: linux/arm64
container_name: postgis-test
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: testpassword
POSTGRES_DB: testdb
ports:
- "5432:5432"
volumes:
# NOTE: PG18 uses /var/lib/postgresql (not /var/lib/postgresql/data)
- postgres_data:/var/lib/postgresql
- ./init-extensions.sql:/docker-entrypoint-initdb.d/20-extensions.sql:ro
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 10s
timeout: 5s
retries: 5
volumes:
postgres_data: