[DOCUMENTATION] Added X-Sendfile/X-Accel-Redirect to the sample nginx and apache config files

This commit is contained in:
Miguel Dantas 2019-08-04 20:14:45 +01:00 committed by Diogo Cordeiro
parent b4fced4bd7
commit 573ba2ee43
2 changed files with 13 additions and 0 deletions

View File

@ -44,6 +44,11 @@
# RewriteRule (.*) index.php/$1 [L,QSA]
</IfModule>
# Enable X-Sendfile if available. Still needs to be enabled in the config
<IfModule mod_xsendfile.c>
XSendFile On
</IfModule>
<FilesMatch "\.(ini)">
<IfVersion < 2.3>
Order allow,deny

View File

@ -31,6 +31,14 @@ server {
# Index
index index.php;
# X-Accel/X-Sendfile. Still needs to be enabled in the config
location /file {
internal;
# FIXME: Change "/path/to/gnusocial/root/" to the folder where
# attachments are stored (normally the same as the site root)
root /path/to/gnusocial/root/;
}
# PHP
location ~ ^/(index|install)\.php(/.*)?$ {
#location ^~ /index.php {