summarylogtreecommitdiffstats
path: root/nginx-location.conf
diff options
context:
space:
mode:
authorMartina Pietruschka2015-06-08 22:27:03 +0000
committerMartina Pietruschka2015-06-08 22:27:03 +0000
commita3f9695e498917be0d558b8fc59308472a9efc7f (patch)
tree1734dedaa822d8b002c47189b1cd8fe732e1619e /nginx-location.conf
downloadaur-a3f9695e498917be0d558b8fc59308472a9efc7f.tar.gz
Initial import
Diffstat (limited to 'nginx-location.conf')
-rw-r--r--nginx-location.conf42
1 files changed, 42 insertions, 0 deletions
diff --git a/nginx-location.conf b/nginx-location.conf
new file mode 100644
index 000000000000..6ad85c9915d4
--- /dev/null
+++ b/nginx-location.conf
@@ -0,0 +1,42 @@
+ ###
+ ## In order to run this component you need to define a server-context in.
+ ## /etc/nginx/nginx.conf:
+ ##
+ ## http {
+ ## server {
+ ## listen 80;
+ ## include ${PATH_TO_THIS_LOCATION_FILE};
+ ## }
+ ## }
+ ##
+ ## Or include this file in your existing server-context.
+ ##
+ location /zarafa-webapp {
+ root /usr/share/webapps;
+ index index.php;
+
+ ## [WARNING] The following header states that the browser should only communicate
+ ## with your server over a secure connection for the next 24 months.
+ add_header Strict-Transport-Security max-age=63072000;
+ add_header X-Frame-Options DENY;
+ add_header X-Content-Type-Options nosniff;
+
+ # HIDDEN FILES AND FOLDERS
+ rewrite ^(.*)\/\.(.*)$ @404 break;
+
+ ## Increase this if you want to upload large attachments
+ client_max_body_size 20m;
+
+ # Pass PHP scripts to PHP-FPM
+ location ~* \.php$ {
+ if (!-f $request_filename) {
+ return 404;
+ }
+
+ fastcgi_index index.php;
+ fastcgi_pass unix:/run/php-fpm/zarafa-webapp.sock;
+ include fastcgi_params;
+ fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
+ fastcgi_param SCRIPT_NAME $fastcgi_script_name;
+ }
+ } \ No newline at end of file