diff --git a/compose-postgresql.yml b/compose-postgresql.yml new file mode 100644 index 0000000..ddecbe1 --- /dev/null +++ b/compose-postgresql.yml @@ -0,0 +1,30 @@ +version: '3.9' +name: y9-dev-postgres +services: + postgresql: + image: postgres:latest + container_name: pg01 + restart: always + extra_hosts: + - "host.docker.internal:host-gateway" + networks: + - y9-share-net + ports: + - "5432:5432" + environment: + POSTGRES_USER: 'root' + POSTGRES_PASSWORD: '12345678' + POSTGRES_DB: 'y9_public' + volumes: + - d:/docker-data/postgres:/var/lib/mysql + - d:/docker-config/postgres-init:/docker-entrypoint-initdb.d + healthcheck: + test: [ "CMD", "pg_isready", "-q", "-d", "postgres", "-U", "root" ] + interval: 5s + timeout: 10s + retries: 8 + labels: + org.springframework.boot.readiness-check.tcp.disable: true +networks: + y9-share-net: + external: true \ No newline at end of file