# ---- # Copyright (C) 2013-2020 - Reevo (http://reevo.org) # License: Affero GPL version 3 - http://www.gnu.org/licenses/agpl.html # ES: Este archivos es parte de: reevo-web (http://git.reevo.org/reevo/crianzamutua) # EN: This file is part of: crianzamutua (http://git.reevo.org/reevo/reevo-2020) # ---- server { server_name example.org; root /srv/reevotech/www/wiki; index index.php; access_log /srv/reevotech/log/wiki/$server_name.nginx.access.log; error_log /srv/reevotech/log/wiki/$server_name.nginx.error.log; location / { index index.php; try_files $uri $uri/ @mediawiki; } location = /favicon.ico { add_header Cache-Control "public"; expires 7d; } location = /robots.txt { } location @mediawiki { if ($subdomain) { return 301 http://$server_name$request_uri#$subdomain; } rewrite ^/([^?]*)(?:\?(.*))? /index.php?title=$1&$2 last; } location ~ \.php?$ { include /etc/nginx/fastcgi_params; fastcgi_pass unix:/srv/reevotech/run/$server_name.socket; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; } }