1
0
Fork 0
mirror of https://github.com/seanmorley15/AdventureLog.git synced 2025-07-19 12:59:36 +02:00

Update backend/nginx.conf

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
Sean Morley 2025-05-29 18:02:05 -04:00 committed by GitHub
parent 787ac4a8b3
commit 9d69935f22
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -39,15 +39,15 @@ http {
internal; internal;
alias /code/media/; alias /code/media/;
try_files $uri =404; try_files $uri =404;
}
# Nested location for PDFs # Separate location for PDFs under /protectedMedia/
location ~* \.pdf$ { location ~* ^/protectedMedia/.*\.pdf$ {
add_header Content-Security-Policy "default-src 'self'; script-src 'none'; object-src 'none'; base-uri 'none'" always; add_header Content-Security-Policy "default-src 'self'; script-src 'none'; object-src 'none'; base-uri 'none'" always;
add_header X-Content-Type-Options nosniff always; add_header X-Content-Type-Options nosniff always;
add_header X-Frame-Options SAMEORIGIN always; add_header X-Frame-Options SAMEORIGIN always;
add_header Content-Disposition "inline" always; add_header Content-Disposition "inline" always;
} }
}
} }