Skip to content

Commit 4556d03

Browse files
authored
fix: healthcheck printf returns 0 (#804)
1 parent ab821f1 commit 4556d03

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

internal/start/start.go

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ EOF
280280
"/app/bin/migrate && /app/bin/realtime eval 'Realtime.Release.seeds(Realtime.Repo)' && /app/bin/server",
281281
},
282282
Healthcheck: &container.HealthConfig{
283-
Test: []string{"CMD", "printf", "\\0", ">", "/dev/tcp/localhost/4000"},
283+
Test: []string{"CMD", "bash", "-c", "printf \\0 > /dev/tcp/localhost/4000"},
284284
Interval: 2 * time.Second,
285285
Timeout: 2 * time.Second,
286286
Retries: 10,
@@ -309,6 +309,12 @@ EOF
309309
"PGRST_DB_ANON_ROLE=anon",
310310
"PGRST_JWT_SECRET=" + utils.JWTSecret,
311311
},
312+
Healthcheck: &container.HealthConfig{
313+
Test: []string{"CMD", "bash", "-c", "printf \\0 > /dev/tcp/localhost/3000"},
314+
Interval: 2 * time.Second,
315+
Timeout: 2 * time.Second,
316+
Retries: 10,
317+
},
312318
},
313319
container.HostConfig{
314320
RestartPolicy: container.RestartPolicy{Name: "always"},

0 commit comments

Comments
 (0)