Skip to content

Commit 62ca3d8

Browse files
committed
Update healthcheck configuration for GPU services to improve startup reliability
1 parent 220aaa8 commit 62ca3d8

3 files changed

Lines changed: 16 additions & 8 deletions

File tree

‎compose/docker-compose-multi-gpu.yml‎

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,12 @@ services:
2222
capabilities: [gpu]
2323
healthcheck:
2424
test: [ "CMD", "curl", "-f", "http://localhost:18080/health" ]
25-
interval: 300s
25+
interval: 30s
2626
timeout: 10s
2727
retries: 3
28-
start_period: 30s
28+
# Must exceed model download + TRT engine warmup on first boot, otherwise
29+
# the container is killed mid-startup and never reaches "healthy".
30+
start_period: 240s
2931

3032
ifr-trt-gpu1:
3133
image: insightface-rest:${IFR_VERSION}
@@ -48,10 +50,12 @@ services:
4850
capabilities: [gpu]
4951
healthcheck:
5052
test: [ "CMD", "curl", "-f", "http://localhost:18080/health" ]
51-
interval: 300s
53+
interval: 30s
5254
timeout: 10s
5355
retries: 3
54-
start_period: 30s
56+
# Must exceed model download + TRT engine warmup on first boot, otherwise
57+
# the container is killed mid-startup and never reaches "healthy".
58+
start_period: 240s
5559

5660

5761
nginx:

‎compose/docker-compose-v2.yml‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,12 @@ x-base_service: &base_service
99
- &v_nginx ../misc/nginx_conf/conf.d:/etc/nginx/conf.d
1010
healthcheck:
1111
test: [ "CMD", "curl", "-f", "http://localhost:18080/health" ]
12-
interval: 300s
12+
interval: 30s
1313
timeout: 10s
1414
retries: 3
15-
start_period: 30s
15+
# Must exceed model download + TRT engine warmup on first boot, otherwise
16+
# the container is killed mid-startup and never reaches "healthy".
17+
start_period: 240s
1618

1719
services:
1820
ifr-trt-gpu0:

‎compose/docker-compose.yml‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,9 @@ services:
2323
capabilities: [gpu]
2424
healthcheck:
2525
test: [ "CMD", "curl", "-f", "http://localhost:18080/health" ]
26-
interval: 300s
26+
interval: 30s
2727
timeout: 10s
2828
retries: 3
29-
start_period: 30s
29+
# Must exceed model download + TRT engine warmup on first boot, otherwise
30+
# the container is killed mid-startup and never reaches "healthy".
31+
start_period: 240s

0 commit comments

Comments
 (0)