server { listen 80; root /var/www/html/clameurs-lawebserie.fr/public_html; index index.html index.php; server_name dev.clameurs-lawebserie.fr; charset utf-8; location / { try_files $uri $uri/ /index.php?$query_string; } location = /favicon.ico { access_log off; log_not_found off; } location = /robots.txt { access_log off; log_not_found off; } access_log on; error_log /var/log/nginx/error.log error; sendfile off; client_max_body_size 100m; location ~ \.php$ { fastcgi_split_path_info ^(.+\.php)(/.+)$; fastcgi_pass phpd7:9000; fastcgi_index index.php; include fastcgi_params; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_intercept_errors off; fastcgi_buffer_size 16k; fastcgi_buffers 4 16k; fastcgi_read_timeout 150; } location ~ /\.ht { deny all; } } server { listen 80; root /var/www/html/clameurs-lawebserie.fr/static_html; server_name static.clameurs-lawebserie.fr; index index.html index.js index.css index.json index.woff index.ttf; # index.ico index.jpg index.png index.gif index.jpeg # rewrite ^/modules/(.*)\.(css|js)$ /modules/$1/index.$2 last; # rewrite ^/sites/all/modules/(.*)\.(css|js)$ /sites/all/modules/$1/index.$2 last; rewrite ^/analytics.js$ /analytics/index.js; rewrite ^/sites/default/files/(.+)\.(ico|png|jpeg|jpg|gif)$ /sites/default/files/$1/index.$2 last; rewrite ^/sites/default/files/styles/(.*)\.(ico|jpeg|jpg|gif|png)$ /sites/default/files/styles/$1/index.$2 last; rewrite ^/sites/all/themes/figureslibres/clameurs/images/(.*)\.(jpeg|jpg) /sites/all/themes/figureslibres/clameurs/images/$1/index.$2 last; rewrite ^/(.*)/(.*)\.(css|js|png|woff|ttf|ico|gif)$ /$1/$2/index.$3; charset utf-8; access_log on; error_log /var/log/nginx/error.log error; }