# This file contains the pgsql service definition (the primary Sourcegraph database deployment), # as well as the codeintel-db service definition (a separate postgres deployment). Both run postgres. # This file is used during the sourcegraph/server -> docker-compose migration process. # # 🚨This file MUST be kept in sync with the pgsql definition in docker-compose/docker-compose.yaml version: '2.4' services: # Description: PostgreSQL database for various data. # # Disk: 128GB / persistent SSD # Ports exposed to other Sourcegraph services: 5432/TCP 9187/TCP # Ports exposed to the public internet: none # pgsql: container_name: pgsql image: 'index.docker.io/sourcegraph/postgres-12-alpine:216430_2023-05-02_5.0-3cc9006de32c@sha256:931a3b043d79f4cc7692a96810e18f0db231f36534a6748ea862903768ceeef0' cpus: 4 mem_limit: '2g' healthcheck: test: '/liveness.sh' interval: 10s timeout: 1s retries: 3 start_period: 15s volumes: - 'pgsql:/data/' networks: - sourcegraph restart: always codeintel-db: container_name: codeintel-db image: 'index.docker.io/sourcegraph/codeintel-db:216430_2023-05-02_5.0-3cc9006de32c@sha256:931a3b043d79f4cc7692a96810e18f0db231f36534a6748ea862903768ceeef0' cpus: 4 mem_limit: '2g' healthcheck: test: '/liveness.sh' interval: 10s timeout: 1s retries: 3 start_period: 15s volumes: - 'codeintel-db:/data/' networks: - sourcegraph restart: always volumes: pgsql: codeintel-db: networks: sourcegraph: