Skip to content
Snippets Groups Projects
Commit 7d70a117 authored by Bob Mottram's avatar Bob Mottram
Browse files

php option

parent 8d75ab63
No related branches found
No related tags found
No related merge requests found
......@@ -314,7 +314,7 @@ function install_bludit {
echo ' # Location';
echo ' location / {'; } >> "$bludit_nginx_site"
nginx_limits "$BLUDIT_DOMAIN_NAME" '15m'
{ echo " try_files \$uri \$uri/ /index.html;";
{ echo " try_files \$uri \$uri/ /index.php?\$args;";
echo ' }';
echo '}'; } >> "$bludit_nginx_site"
else
......@@ -345,7 +345,7 @@ function install_bludit {
echo ' # Location';
echo ' location / {'; } >> "$bludit_nginx_site"
nginx_limits "$BLUDIT_DOMAIN_NAME" '15m'
{ echo " try_files \$uri \$uri/ index.html;";
{ echo " try_files \$uri \$uri/ index.php?\$args;";
echo ' }';
echo '}'; } >> "$bludit_nginx_site"
......
......@@ -686,6 +686,7 @@ if [ ! $app_onion_only ]; then
echo " echo ' include snippets/fastcgi-php.conf;';"
echo " echo ' fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;';"
echo " echo ' fastcgi_read_timeout 30;';"
echo " echo ' fastcgi_param HTTPS on;';"
echo " echo ' }';"
echo " echo '';"
else
......@@ -695,7 +696,11 @@ if [ ! $app_onion_only ]; then
echo " echo ' location / {'; } >> \"\$${app_name}_nginx_site\""
echo " nginx_limits \"\$${app_name_upper}_DOMAIN_NAME\" '15m'"
if [ ! $app_daemon ]; then
echo " { echo \" try_files \\\$uri \\\$uri/ /index.html;\";"
if [[ "$app_php" != 'yes' ]]; then
echo " { echo \" try_files \\\$uri \\\$uri/ /index.html;\";"
else
echo " { echo \" try_files \\\$uri \\\$uri/ /index.php?\\\$args;\";"
fi
else
echo " { echo \" proxy_pass http://localhost:\$${app_name_upper}_PORT_INTERNAL;\";"
fi
......@@ -728,6 +733,7 @@ if [[ "$app_php" == 'yes' ]]; then
echo " echo ' include snippets/fastcgi-php.conf;';"
echo " echo ' fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;';"
echo " echo ' fastcgi_read_timeout 30;';"
echo " echo ' fastcgi_param HTTPS off;';"
echo " echo ' }';"
echo " echo '';"
else
......@@ -737,7 +743,11 @@ echo " echo ' # Location';"
echo " echo ' location / {'; } >> \"\$${app_name}_nginx_site\""
echo " nginx_limits \"\$${app_name_upper}_DOMAIN_NAME\" '15m'"
if [ ! $app_daemon ]; then
echo " { echo \" try_files \\\$uri \\\$uri/ index.html;\";"
if [[ "$app_php" != 'yes' ]]; then
echo " { echo \" try_files \\\$uri \\\$uri/ index.html;\";"
else
echo " { echo \" try_files \\\$uri \\\$uri/ index.php?\\\$args;\";"
fi
else
echo " echo \" proxy_pass http://localhost:\$${app_name_upper}_PORT_INTERNAL;\";"
fi
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment