Skip to content

Commit 56563a7

Browse files
committed
Run healthchecks more frequently during startup for faster cold starts
Signed-off-by: Lilly Rose Berner <[email protected]>
1 parent 9fe7600 commit 56563a7

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

echo/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ COPY --from=build /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
4848
# Copy last so prior steps are cached doing many rebuilds
4949
COPY --from=build /build/bin bin
5050

51-
HEALTHCHECK --interval=5s --timeout=5s --retries=1 CMD ["healthcheck"]
51+
HEALTHCHECK --interval=5s --start-interval=1s --retries=1 --timeout=5s --start-period=1m CMD ["healthcheck"]
5252

5353
USER 101:101
5454
CMD ["echo"]

echo/docker-compose.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,8 @@ services:
5757
healthcheck:
5858
test: ["CMD", "pg_isready", "-U", "echo"]
5959
interval: 5s
60+
start_interval: 1s
61+
retries: 1
6062
timeout: 5s
6163
start_period: 1m
6264

0 commit comments

Comments
 (0)