From fee56c604237152b99b3bea46e62d17a8195a4e3 Mon Sep 17 00:00:00 2001 From: Joseph Manley Date: Sat, 2 May 2020 03:02:06 -0400 Subject: [PATCH] Dockerfile with working healthcheck endpoint --- server/Dockerfile | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/server/Dockerfile b/server/Dockerfile index ea72233..8aef4a5 100644 --- a/server/Dockerfile +++ b/server/Dockerfile @@ -1,20 +1,15 @@ FROM fedora:32 # Build and setup app -RUN dnf install g++ enet-devel gtest gmock gmock-devel gtest-devel -y +RUN dnf install g++ enet-devel gtest gmock gmock-devel gtest-devel nginx -y ADD / /dt RUN cd /dt; /dt/build.sh -CMD ["/dt/builds/server.out"] +RUN echo "Container is healthy!" > /usr/share/nginx/html/index.html -# Setup status endpoint -RUN dnf install nginx -y +CMD /usr/sbin/nginx ; /dt/builds/server.out -COPY nginx.conf /etc/nginx/conf.d/nginx.conf - -RUN systemctl enable nginx.service - -EXPOSE 80/tcp +EXPOSE 80 EXPOSE 7777/udp \ No newline at end of file