fix(nginx): custom vhost flarum

improvement: create custom vhost if doesn't exist
pull/34/head
Magicalex 2018-11-05 18:53:30 +01:00
parent b50541af89
commit ed36207636
No known key found for this signature in database
GPG Key ID: A89B48B1788C3CB5
5 changed files with 14 additions and 8 deletions

View File

View File

@ -1,6 +0,0 @@
# Example:
# fix for flagrow/sitemap (https://github.com/flagrow/sitemap)
# location = /sitemap.xml {
# try_files $uri $uri/ /index.php?$query_string;
# }

View File

@ -132,7 +132,7 @@ http {
fastcgi_param REMOTE_ADDR $http_x_real_ip;
}
include /etc/nginx/conf.d/custom-flarum.conf;
include /etc/nginx/conf.d/custom-vhost-flarum.conf;
}

View File

@ -64,6 +64,18 @@ if [ -f 'extensions/composer.repositories.txt' ]; then
done < extensions/composer.repositories.txt
fi
# Custom vhost flarum nginx
if [ ! -e '/etc/nginx/conf.d/custom-vhost-flarum.conf' ]; then
echo '# Example:
# fix for flagrow/sitemap (https://github.com/flagrow/sitemap)
# location = /sitemap.xml {
# try_files $uri $uri/ /index.php?$query_string;
# }' > /etc/nginx/conf.d/custom-vhost-flarum.conf
fi
# if no installation was performed before
if [ -e 'assets/rev-manifest.json' ]; then