Skip to content

Commit f4d7f5a

Browse files
committed
add healthcheck
1 parent 4f9298e commit f4d7f5a

2 files changed

Lines changed: 7 additions & 1 deletion

File tree

docker-compose.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,12 @@ services:
88
volumes:
99
- rabbit_data:/var/lib/rabbitmq
1010
restart: on-failure
11+
healthcheck:
12+
test: ["CMD", "rabbitmq-diagnostics", "-q", "ping"]
13+
interval: 5s
14+
timeout: 5s
15+
retries: 10
16+
start_period: 10s
1117

1218
redis:
1319
image: redis:6.2.7-alpine

packages/amqp/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
"test:coverage": "npm run test -- --coverage",
2424
"lint": "biome check . && tsc",
2525
"lint:fix": "biome check --write .",
26-
"docker:start": "docker compose up -d rabbitmq",
26+
"docker:start": "docker compose up -d --wait rabbitmq",
2727
"docker:stop": "docker compose down",
2828
"prepublishOnly": "npm run lint && npm run build"
2929
},

0 commit comments

Comments
 (0)