Skip to content

Commit

Permalink
impr: docker - healthcheck using ping (fix #17)
Browse files Browse the repository at this point in the history
  • Loading branch information
nalgeon committed May 4, 2024
1 parent 05aeb4b commit 043f1c1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,12 @@ COPY . .
RUN make build build-cli

FROM alpine:latest
RUN apk add --no-cache redis
RUN mkdir /data
VOLUME /data
WORKDIR /data
COPY --from=build /app/build/redka /usr/local/bin/redka
COPY --from=build /app/build/redka-cli /usr/local/bin/redka-cli
HEALTHCHECK CMD redis-cli PING || exit 1
EXPOSE 6379
CMD ["redka", "-h", "0.0.0.0", "-p", "6379", "redka.db"]

0 comments on commit 043f1c1

Please sign in to comment.