add docker health checks

This commit is contained in:
2025-07-17 00:38:10 +01:00
parent 7dc46b6ad0
commit d49025a6b4
6 changed files with 42 additions and 7 deletions

View File

@ -21,7 +21,10 @@ RUN --mount=type=cache,target=/usr/local/cargo/registry \
cargo build --release --bin nuchat --target-dir=/app/target
FROM gcr.io/distroless/cc AS runtime
WORKDIR /app
COPY --from=builder /app/target/release/nuchat ./nuchat
ENTRYPOINT [ "./nuchat", "--host 0.0.0.0" ]
ADD --chmod=a+x vendor/busybox_WGET /usr/bin/wget
COPY --from=builder /app/target/release/nuchat /usr/bin/
# HEALTHCHECK --interval=5s --retries=1 --timeout=5s CMD ["wget", "-q", "--spider", "http://localhost:7000/healthcheck
ENTRYPOINT [ "nuchat", "--host", "0.0.0.0" ]