mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-08-29 15:06:26 +02:00
Solved certreap bugs, implemented caching for pictures, optimized CSP policies (stricter), optimized recaptcha implementation for keycloak, solved mariadb wait bug, solved nextcloud plugin bugs, optimized ignore handling of tasks
This commit is contained in:
@@ -31,3 +31,6 @@ location {{location | default("/")}}
|
||||
proxy_read_timeout 900s;
|
||||
send_timeout 900s;
|
||||
}
|
||||
|
||||
# Load caching
|
||||
{% include 'roles/nginx-docker-reverse-proxy/templates/location/proxy_cache.conf.j2' %}
|
@@ -0,0 +1,18 @@
|
||||
proxy_cache_path {{ nginx.directories.cache }} levels=1:2 keys_zone=imgcache:10m inactive=60m use_temp_path=off;
|
||||
|
||||
{%- if location is defined %}
|
||||
location ~* ^{{ location }}.*\.(jpg|jpeg|png|gif|webp|ico|svg)$ {
|
||||
{%- else %}
|
||||
location ~* \.(jpg|jpeg|png|gif|webp|ico|svg)$ {
|
||||
{%- endif %}
|
||||
# Cache in browser
|
||||
expires 30d;
|
||||
add_header Cache-Control "public, max-age=2592000, immutable";
|
||||
|
||||
# Cache on reverse proxy side
|
||||
proxy_pass http://127.0.0.1:{{http_port}}{{location | default("/")}};
|
||||
proxy_cache imgcache;
|
||||
proxy_cache_valid 200 302 60m;
|
||||
proxy_cache_valid 404 1m;
|
||||
add_header X-Proxy-Cache $upstream_cache_status;
|
||||
}
|
Reference in New Issue
Block a user