Switch to nginx server (#8)

* test nginx image

* web optimize jpg

* update Readme

* adds docker swarm stack file [CI SKIP]
This commit is contained in:
2022-01-13 09:35:23 +01:00
committed by GitHub
parent d2645777c1
commit 02a796e966
7 changed files with 124 additions and 25 deletions

View File

@ -6,10 +6,9 @@ WORKDIR /src
RUN npm install \
&& npm run build
FROM caddy:2.4.6-alpine
FROM nginx:1.21.5-alpine
LABEL maintainer="marco.blessing@googlemail.com"
COPY --from=builder /src/Caddyfile /etc/caddy/Caddyfile
COPY --from=builder src/public /usr/share/caddy/
HEALTHCHECK --interval=15s --timeout=3s \
CMD wget --no-verbose --tries=1 --spider http://localhost:8080/ || exit 1
#RUN ls -la /usr/share/caddy/
CMD wget --no-verbose --tries=1 --spider http://localhost:80/ || exit 1
COPY --from=builder src/public /usr/share/nignx/html/
COPY nginx.conf /etc/nginx/nginx.conf