Skip to content

armgit / Cap

Public Imported from GitHub
0

Open source Loom alternative. Beautiful, shareable screen recordings.

build(docker): use bun healthcheck for media-server service

Richie McIlroy42e89ccdd99d
diff --git a/docker-compose.coolify.yml b/docker-compose.coolify.yml
index 8c89312e3..d14469468 100644
--- a/docker-compose.coolify.yml
+++ b/docker-compose.coolify.yml
@@ -47,7 +47,7 @@ services:
PORT: 3456
MEDIA_SERVER_WEBHOOK_SECRET: ${MEDIA_SERVER_WEBHOOK_SECRET}
healthcheck:
- test: ["CMD", "wget", "-qO-", "http://localhost:3456/health"]
+ test: ["CMD", "bun", "-e", "fetch('http://127.0.0.1:3456/health').then((response) => process.exit(response.ok ? 0 : 1)).catch(() => process.exit(1))"]
interval: 30s
timeout: 10s
retries: 3
diff --git a/docker-compose.template.yml b/docker-compose.template.yml
index e21f40d28..1360b3d87 100644
--- a/docker-compose.template.yml
+++ b/docker-compose.template.yml
@@ -61,7 +61,7 @@ services:
ports:
- "3456:3456"
healthcheck:
- test: ["CMD", "wget", "-qO-", "http://localhost:3456/health"]
+ test: ["CMD", "bun", "-e", "fetch('http://127.0.0.1:3456/health').then((response) => process.exit(response.ok ? 0 : 1)).catch(() => process.exit(1))"]
interval: 30s
timeout: 10s
retries: 3
diff --git a/docker-compose.yml b/docker-compose.yml
index 50add5ca7..a7f62ad01 100644
--- a/docker-compose.yml
+++ b/docker-compose.yml
@@ -49,7 +49,7 @@ services:
PORT: 3456
MEDIA_SERVER_WEBHOOK_SECRET: ${MEDIA_SERVER_WEBHOOK_SECRET:-fedcba9876543210fedcba9876543210fedcba9876543210fedcba9876543210}
healthcheck:
- test: ["CMD", "wget", "-qO-", "http://localhost:3456/health"]
+ test: ["CMD", "bun", "-e", "fetch('http://127.0.0.1:3456/health').then((response) => process.exit(response.ok ? 0 : 1)).catch(() => process.exit(1))"]
interval: 30s
timeout: 10s
retries: 3