From acdcff091bc3e7e519800ea5e1c7df5113547a1f Mon Sep 17 00:00:00 2001 From: emil-lengman Date: Wed, 12 Aug 2020 18:23:06 +0200 Subject: [PATCH] add health check and stopsignal --- Dockerfile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Dockerfile b/Dockerfile index 5753ab1..28b086c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -30,7 +30,10 @@ COPY --chown=node:node . . RUN yarn build +STOPSIGNAL SIGNINT EXPOSE 3001 +HEALTHCHECK --interval=30s --timeout=30s --start-period=10s --retries=3 \ + CMD [ "curl", "-f", "${REACT_APP_API_PROTOCOL}://localhost:${REACT_APP_API_PORT}", "||", "exit", "1" ] ENTRYPOINT [ "docker-entrypoint.sh" ] CMD ["yarn", "start"] \ No newline at end of file