initial commit
This commit is contained in:
+57
@@ -0,0 +1,57 @@
|
||||
services:
|
||||
postgres:
|
||||
container_name: postgres_wschat
|
||||
image: docker.io/library/postgres:18
|
||||
environment:
|
||||
POSTGRES_USER: wschat
|
||||
POSTGRES_PASSWORD: example
|
||||
POSTGRES_DB: wschat_db
|
||||
volumes:
|
||||
- postgres-data-wschat:/var/lib/postgresql
|
||||
ports:
|
||||
- "127.0.0.1:54325:5432"
|
||||
shm_size: 128m
|
||||
command: ["postgres", "-c", "listen_addresses=*"]
|
||||
networks:
|
||||
- postgres-net
|
||||
restart: always
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U wschat -d wschat_db"]
|
||||
interval: 10s
|
||||
timeout: 5s
|
||||
retries: 5
|
||||
start_period: 900s
|
||||
|
||||
dbgate:
|
||||
container_name: dbgate_wschat
|
||||
image: docker.io/dbgate/dbgate:latest
|
||||
environment:
|
||||
CONNECTIONS: pg
|
||||
LABEL_pg: Postgres
|
||||
SERVER_pg: postgres
|
||||
PORT_pg: 5432
|
||||
USER_pg: wschat
|
||||
PASSWORD_pg: example
|
||||
DATABASE_pg: wschat_db
|
||||
ENGINE_pg: postgres@dbgate-plugin-postgres
|
||||
volumes:
|
||||
- dbgate-data-wschat:/root/.dbgate
|
||||
ports:
|
||||
- "127.0.0.1:7777:3000"
|
||||
depends_on:
|
||||
postgres:
|
||||
condition: service_healthy
|
||||
networks:
|
||||
- postgres-net
|
||||
restart: always
|
||||
|
||||
networks:
|
||||
postgres-net:
|
||||
name: postgres-net-wschat
|
||||
driver: bridge
|
||||
|
||||
volumes:
|
||||
postgres-data-wschat:
|
||||
name: postgres-data-wschat
|
||||
dbgate-data-wschat:
|
||||
name: dbgate-data-wschat
|
||||
Reference in New Issue
Block a user