fix: prevent nginx default page in hugo image
Some checks failed
Deploy Hugo Blog to k3s / build-and-deploy (push) Failing after 24s

This commit is contained in:
luochen570
2026-06-02 08:47:13 +08:00
parent 06185c71d7
commit a2aec46cc0
2 changed files with 16 additions and 2 deletions

View File

@@ -1,3 +1,6 @@
FROM docker.m.daocloud.io/library/nginx:alpine
COPY public/ /usr/share/nginx/html
RUN rm -rf /usr/share/nginx/html/*
COPY public/ /usr/share/nginx/html/
RUN test -s /usr/share/nginx/html/index.html \
&& ! grep -q "Welcome to nginx" /usr/share/nginx/html/index.html
EXPOSE 80