Spaces:
Running
Running
Download nginx.conf from Flubstar/webmag-kit: direct link, hf CLI and curl.
- Browser
- Download file 1.1 kB
-
https://huggingface.co/spaces/Flubstar/webmag-kit/resolve/main/nginx.conf
- Command line
-
hf download hf://spaces/Flubstar/webmag-kit/nginx.conf
-
curl -L -o nginx.conf https://huggingface.co/spaces/Flubstar/webmag-kit/resolve/main/nginx.conf
1.1 kB
| # WebMag Kit — Nginx-Vorlage | |
| # Nach /etc/nginx/sites-available/webmag kopieren, symlink setzen, nginx reload. | |
| # root-Pfad unten an deine Umgebung anpassen. | |
| server { | |
| listen 80; | |
| server_name _; # <- deinen Domainnamen eintragen | |
| root /var/www/html/webmag; # <- Installationspfad (install.sh) anpassen | |
| index index.html; | |
| # Statische Magazin-Seiten: saubere URLs für die Hauptseiten | |
| location / { | |
| try_files $uri $uri/ =404; | |
| } | |
| # Gzip-Kompression (HTML/CSS/JS) | |
| gzip on; | |
| gzip_comp_level 5; | |
| gzip_types text/plain text/css application/javascript application/json image/svg+xml; | |
| # Caching: HTML kurz, Fonts/SVG länger | |
| location ~* \.html$ { | |
| add_header Cache-Control "no-cache, must-revalidate"; | |
| } | |
| location ~* \.(woff2?|svg|png|jpg|webp|ico)$ { | |
| expires 7d; | |
| add_header Cache-Control "public"; | |
| } | |
| # Sicherheits-Header | |
| add_header X-Content-Type-Options nosniff; | |
| add_header X-Frame-Options SAMEORIGIN; | |
| add_header Referrer-Policy strict-origin-when-cross-origin; | |
| } | |