Commit a40d5e59 authored by Felix Bartels's avatar Felix Bartels

ZP-1161 import updated nginx config example. Released under the Affero GNU...

ZP-1161 import updated nginx config example. Released under the Affero GNU General Public License (AGPL) version 3.
parent fe2bcf98
server { server {
listen 443; listen 443 ssl;
server_name localhost; # Please edit me server_name localhost; # Please edit me
ssl on; ssl on;
#ssl_certificate /path/to/ssl.crt; # Please edit me ssl_certificate <path-to-certificate>/fullchain.pem; # Please edit me
#ssl_certificate_key /path/to/ssl.key; # Please edit me ssl_certificate_key <path-to-certificate>/privkey.pem; # Please edit me
root /usr/share/webapps/z-push; root /usr/share/z-push;
index index.php; index index.php;
  access_log /var/log/nginx/zpush-access.log;
error_log /var/log/nginx/zpush-error.log;
# Performance Settings # Attachments 20MB max
#client_max_body_size 4M; client_max_body_size 20m;
#client_body_buffer_size 128k; client_body_buffer_size 128k;
location / { location / {
try_files $uri $uri/ index.php; try_files $uri $uri/ index.php;
} }
location /Microsoft-Server-ActiveSync { location /Microsoft-Server-ActiveSync {
rewrite ^(.*)$ /index.php last; rewrite ^(.*)$ /index.php last;
}
location /AutoDiscover/AutoDiscover.xml {
alias /usr/share/z-push/autodiscover/autodiscover.php;
include fastcgi_params;
#depending on your php-fpm config
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_param SCRIPT_FILENAME /usr/share/z-push/autodiscover/autodiscover.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param REQUEST_URI $1;
} }
location ~ .php$ { location ~ .php$ {
include fastcgi_params; include /etc/nginx/fastcgi_params;
fastcgi_index index.php; fastcgi_index index.php;
fastcgi_param HTTPS on; fastcgi_param HTTPS on;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_pass unix:/run/php-fpm/php-fpm.sock; #depending on your php-fpm config
fastcgi_pass unix:/run/php-fpm/php-fpm.sock;
# PHP max_execution_time is set to 730
        fastcgi_read_timeout 730;
        proxy_read_timeout 700;
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment