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

bludit nginx config

parent a9c11e9f
No related branches found
No related tags found
No related merge requests found
...@@ -292,6 +292,11 @@ function install_bludit { ...@@ -292,6 +292,11 @@ function install_bludit {
echo ' # Root'; echo ' # Root';
echo " root /var/www/$BLUDIT_DOMAIN_NAME/htdocs;"; echo " root /var/www/$BLUDIT_DOMAIN_NAME/htdocs;";
echo ''; echo '';
echo ' location ~ \.(jpg|jpeg|gif|png|css|js|ico|svg|eot|ttf|woff|woff2|otf)$ {';
echo ' access_log off;';
echo ' expires 30d;';
echo ' }';
echo '';
echo ' index index.php;'; echo ' index index.php;';
echo ' location ~ \.php {'; echo ' location ~ \.php {';
echo ' include snippets/fastcgi-php.conf;'; echo ' include snippets/fastcgi-php.conf;';
...@@ -304,6 +309,10 @@ function install_bludit { ...@@ -304,6 +309,10 @@ function install_bludit {
nginx_limits "$BLUDIT_DOMAIN_NAME" '15m' nginx_limits "$BLUDIT_DOMAIN_NAME" '15m'
{ echo " try_files \$uri \$uri/ /index.php?\$args;"; { echo " try_files \$uri \$uri/ /index.php?\$args;";
echo ' }'; echo ' }';
echo '';
echo ' location ^~ /bl-content/tmp/ { deny all; }';
echo ' location ^~ /bl-content/pages/ { deny all; }';
echo ' location ^~ /bl-content/databases/ { deny all; } ';
echo '}'; } >> "$bludit_nginx_site" echo '}'; } >> "$bludit_nginx_site"
else else
echo -n '' > "$bludit_nginx_site" echo -n '' > "$bludit_nginx_site"
...@@ -323,6 +332,11 @@ function install_bludit { ...@@ -323,6 +332,11 @@ function install_bludit {
echo ' # Root'; echo ' # Root';
echo " root /var/www/$BLUDIT_DOMAIN_NAME/htdocs;"; echo " root /var/www/$BLUDIT_DOMAIN_NAME/htdocs;";
echo ''; echo '';
echo ' location ~ \.(jpg|jpeg|gif|png|css|js|ico|svg|eot|ttf|woff|woff2|otf)$ {';
echo ' access_log off;';
echo ' expires 30d;';
echo ' }';
echo '';
echo ' index index.php;'; echo ' index index.php;';
echo ' location ~ \.php {'; echo ' location ~ \.php {';
echo ' include snippets/fastcgi-php.conf;'; echo ' include snippets/fastcgi-php.conf;';
...@@ -335,6 +349,10 @@ function install_bludit { ...@@ -335,6 +349,10 @@ function install_bludit {
nginx_limits "$BLUDIT_DOMAIN_NAME" '15m' nginx_limits "$BLUDIT_DOMAIN_NAME" '15m'
{ echo " try_files \$uri \$uri/ index.php?\$args;"; { echo " try_files \$uri \$uri/ index.php?\$args;";
echo ' }'; echo ' }';
echo '';
echo ' location ^~ /bl-content/tmp/ { deny all; }';
echo ' location ^~ /bl-content/pages/ { deny all; }';
echo ' location ^~ /bl-content/databases/ { deny all; } ';
echo '}'; } >> "$bludit_nginx_site" echo '}'; } >> "$bludit_nginx_site"
configure_php configure_php
......
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