Kapisi/roles/WebServer/files/conf.d/Core/lykos-wiki.conf

38 lines
817 B
Plaintext
Raw Normal View History

2020-10-08 16:33:19 -05:00
server {
2022-07-02 10:24:10 -05:00
listen 443 ssl;
server_name lykos.aninix.net;
2020-10-08 16:33:19 -05:00
include letsencrypt.conf;
2020-10-08 16:33:19 -05:00
2022-07-02 10:24:10 -05:00
root /usr/share/webapps/;
2020-10-08 16:33:19 -05:00
2022-07-02 10:24:10 -05:00
client_max_body_size 5m;
client_body_timeout 60;
2020-10-08 16:33:19 -05:00
2022-07-02 10:24:10 -05:00
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;
2020-10-08 16:33:19 -05:00
}
2022-07-02 10:24:10 -05:00
location ^~ /maintenance/ {
return 403;
2020-10-08 16:33:19 -05:00
}
2022-07-02 10:24:10 -05:00
2020-10-08 16:33:19 -05:00
location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ {
2022-07-02 10:24:10 -05:00
try_files $uri /mediawiki/index.php;
2020-10-08 16:33:19 -05:00
expires max;
log_not_found off;
}
2022-07-02 10:24:10 -05:00
location ^~ /cache/ {
2020-10-08 16:33:19 -05:00
deny all;
}
2022-07-02 10:24:10 -05:00
2020-10-08 16:33:19 -05:00
}