Skip to content

Commit 7829829

Browse files
committed
Adds healthcheck to azurite and improves ready condition
Ensures azurite is healthy before other services depend on it. Azure/Azurite#2623 This change adds a healthcheck to the azurite service in docker-compose.yml. Also ensures that the `ready` service waits for azurite to be healthy, rather than just running, preventing potential issues if azurite is not fully initialized. Improves reliability and robustness during startup.
1 parent 705c3fe commit 7829829

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

docker-compose.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,21 @@
11
services:
22
azurite:
33
image: mcr.microsoft.com/azure-storage/azurite:3.35.0
4+
command: azurite --skipApiVersionCheck
45
ports:
56
- 10000:10000
67
- 10001:10001
78
- 10002:10002
9+
healthcheck:
10+
test: ["CMD", "curl", "-f", "http://localhost:10000"]
11+
interval: 5s
12+
timeout: 5s
13+
retries: 10
14+
start_period: 10s
815

916
ready:
1017
image: andrewlock/wait-for-dependencies
1118
command: azurite:10000
1219
depends_on:
13-
- azurite
20+
azurite:
21+
condition: service_healthy

0 commit comments

Comments
 (0)