diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..839e090 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,4 @@ +FROM nginx:1.24-bullseye + +COPY ./site-html /var/www/blog +COPY ./nginx.conf /etc/nginx/conf.d/default.conf diff --git a/nginx.conf b/nginx.conf new file mode 100644 index 0000000..fa6900f --- /dev/null +++ b/nginx.conf @@ -0,0 +1,18 @@ +server { + listen 80; + server_name pim.kunis.nl; + index index.html index.htm; + root /var/www/blog; + + location / { + try_files $uri $uri/ /index.html; + } + + location ~* \.(?:ico|css|js|gif|jpe?g|png)$ { + expires 30d; + add_header Pragma public; + add_header Cache-Control "public"; + } + + error_page 404 /404.html; +}