diff --git a/Dockerfile b/Dockerfile index 89b281f..fe10cd8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -6,6 +6,8 @@ RUN apk --update add nginx COPY 2048 /usr/share/nginx/html +COPY default.conf /etc/nginx/http.d/default.conf + EXPOSE 80 CMD ["nginx", "-g", "daemon off;"] diff --git a/default.conf b/default.conf new file mode 100644 index 0000000..f974ef0 --- /dev/null +++ b/default.conf @@ -0,0 +1,15 @@ +server { + listen 80 default_server; + listen [::]:80 default_server; + + root /usr/share/nginx/html; + index index.html; + + location / { + try_files $uri $uri/ =404; + } + + location = /404.html { + internal; + } +}