2 caldavzap.heureux-cyclage.org
3 caldavzap.cyclocoop.org;
5 client_body_buffer_size 1024k;
6 client_max_body_size 10m;
8 location ~* ^/davical/htdocs/caldav\.php(|/.*)$ {
11 include /etc/nginx/conf.d/fastcgi.conf;
13 if ($request_method !~ ^(GET|HEAD)$) {
14 # NOTE: if non GET/HEAD, don't cache and mark user as uncacheable for 1 second via cookie.
17 if ($no_cache = "1") {
18 # NOTE: drop no cache cookie if need be (for some reason, add_header fails if included in prior if-block).
19 add_header Set-Cookie "_mcnc=1; Max-Age=2; Path=/";
20 add_header X-Microcachable "0";
22 if ($http_cookie ~* "_mcnc") {
23 # NOTE: bypass cache if no-cache cookie is set
26 fastcgi_cache_bypass $no_cache;
27 fastcgi_cache_use_stale updating;
28 fastcgi_cache_valid 200 10s;
29 fastcgi_cache_valid 404 10m;
30 fastcgi_ignore_headers Cache-Control Expires Set-Cookie;
31 fastcgi_index index.php;
32 fastcgi_split_path_info ^(.+\.php)(/.+)$;
33 fastcgi_param PATH_INFO $fastcgi_path_info;
34 fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
35 fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
36 fastcgi_no_cache $no_cache;
37 fastcgi_param REDIRECT_STATUS 200;
38 # NOTE: PHP only, required if PHP was built with --enable-force-cgi-redirect
39 fastcgi_pass_header Cookie;
40 fastcgi_pass_header Set-Cookie;
42 fastcgi_pass unix:/run/php5/fpm/davical;
44 location ~* ^/davical/htdocs/.+\.(css|gif|html|ico|jpeg|js|jpg|png|txt|xml)$ {
50 location ~* ^.+\.(css|gif|html|ico|jpeg|js|jpg|png|txt|xml)$ {
61 # include /etc/nginx/conf.d/fastcgi.conf;
62 # fastcgi_index index.php;
63 # #fastcgi_param PATH_INFO $fastcgi_path_info;
64 # #fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
65 # #fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
66 # fastcgi_param REDIRECT_STATUS 200;
67 # # NOTE: PHP only, required if PHP was built with --enable-force-cgi-redirect
68 # fastcgi_split_path_info ^(.+\.php)(/.+)$;
70 # fastcgi_pass unix:/run/php5/fpm/caldavzap;