server { listen 443 ssl; server_name lykos.aninix.net; include letsencrypt.conf; root /usr/share/webapps/; client_max_body_size 5m; client_body_timeout 60; include ../conf.d/fastcgi7.config; location / { try_files $uri $uri/ @rewrite; rewrite ^/lykos-wiki/(.*)$ /mediawiki/index.php?title=$1&$args; rewrite ^$ /lykos-wiki/Main_Page; rewrite ^/$ /lykos-wiki/Main_Page; rewrite ^lykos-wiki$ /lykos-wiki/Main_Page; rewrite ^lykos-wiki/$ /lykos-wiki/Main_Page; } location ^~ /maintenance/ { return 403; } location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ { try_files $uri /mediawiki/index.php; expires max; log_not_found off; } location ^~ /cache/ { deny all; } }