diff --git a/.env b/.env index 1133522..d3e4347 100644 --- a/.env +++ b/.env @@ -1,4 +1,4 @@ -POSTGRES_DB=no_copy_db +POSTGRES_DB=no_copy_ POSTGRES_USER=postgres POSTGRES_PASSWORD=postgres POSTGRES_PORT=5432 diff --git a/docker-compose.yaml b/docker-compose.yaml index 69f9587..dfbd31b 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -5,37 +5,28 @@ services: image: postgres:17 restart: always environment: - POSTGRES_DB: no_copy_db + POSTGRES_DB: no_copy_ POSTGRES_USER: postgres POSTGRES_PASSWORD: postgres - POSTGRES_PORT: 5432 - POSTGRES_HOST: postgres - PGDATA: /data/postgres ports: - - "5432:5432" + - "54320:5432" volumes: - pgdata:/var/lib/postgresql/data - healthcheck: - test: [ "CMD-SHELL", "pg_isready -U postgres -p 5432" ] - interval: 10s - timeout: 5s - retries: 20 container_name: postgres app: build: . container_name: no_copy_app environment: - POSTGRES_DB: no_copy_db + POSTGRES_DB: no_copy_ POSTGRES_USER: postgres POSTGRES_PASSWORD: postgres POSTGRES_PORT: 5432 - POSTGRES_HOST: postgres + POSTGRES_HOST: db depends_on: - db: - condition: service_healthy + - db ports: - "8080:8080" volumes: - pgdata: + pgdata: \ No newline at end of file