From 3b6879b52de39d8625beafa9e6f861ca2fb51250 Mon Sep 17 00:00:00 2001 From: yggverse Date: Thu, 21 Aug 2025 15:34:45 +0300 Subject: [PATCH] remove cache example (cache statics only) --- README.md | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 56c3bf2..7328457 100644 --- a/README.md +++ b/README.md @@ -49,9 +49,15 @@ WantedBy=multi-user.target server { listen 80; + location ~* \.(jpg|jpeg|png|gif|ico|svg|css|js) { + expires 30d; + add_header Cache-Control "public, max-age=2592000"; + proxy_pass http://127.0.0.1:8000; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-Proto $scheme; + } + location / { - # expires 15m; - # add_header Cache-Control "public, max-age=900"; proxy_pass http://127.0.0.1:8000; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-Proto $scheme;