fix the restart policy
This commit is contained in:
+13
-3
@@ -1,6 +1,13 @@
|
||||
services:
|
||||
timescaledb:
|
||||
image: timescale/timescaledb:latest-pg16
|
||||
restart: unless-stopped
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U postgres -d micrometeo"]
|
||||
interval: 5s
|
||||
timeout: 3s
|
||||
retries: 12
|
||||
start_period: 20s
|
||||
environment:
|
||||
POSTGRES_PASSWORD: postgres
|
||||
POSTGRES_USER: postgres
|
||||
@@ -17,7 +24,8 @@ services:
|
||||
context: .
|
||||
dockerfile: Dockerfile
|
||||
depends_on:
|
||||
- timescaledb
|
||||
timescaledb:
|
||||
condition: service_healthy
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- "8080:8080"
|
||||
@@ -29,7 +37,8 @@ services:
|
||||
context: .
|
||||
dockerfile: Dockerfile.train
|
||||
depends_on:
|
||||
- timescaledb
|
||||
timescaledb:
|
||||
condition: service_healthy
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
DATABASE_URL: "postgres://postgres:postgres@timescaledb:5432/micrometeo?sslmode=disable"
|
||||
@@ -64,7 +73,8 @@ services:
|
||||
context: .
|
||||
dockerfile: Dockerfile.train
|
||||
depends_on:
|
||||
- timescaledb
|
||||
timescaledb:
|
||||
condition: service_healthy
|
||||
restart: unless-stopped
|
||||
profiles: ["shadow"]
|
||||
environment:
|
||||
|
||||
Reference in New Issue
Block a user