Add error_page.html for 404 errors

This commit is contained in:
Max Schmidt 2023-10-24 09:50:08 +02:00
parent e062d42e66
commit 9793bdaab9

View File

@ -19,10 +19,17 @@ http {
try_files $uri $uri/ =404;
}
location /error_page.html {
internal;
}
location ~* \.(jpg|jpeg|png|gif|ico|css|js|htm|html)$ {
root /usr/share/nginx/html;
expires 30d;
add_header Pragma public;
add_header Cache-Control "public";
}
error_page 404 /error_page.html;
}
}