From b7f8b874bb9f2028c29b1f22f893fabec2836de8 Mon Sep 17 00:00:00 2001 From: VirtualTam Date: Sat, 5 Nov 2016 19:51:03 +0100 Subject: [PATCH] Docker: set favicon location in nginx configuration Relates to https://github.com/shaarli/Shaarli/issues/681 Fixed: - nginx: set the favicon location See http://serverfault.com/a/352861 Signed-off-by: VirtualTam --- docker/development/nginx.conf | 5 +++++ docker/production/nginx.conf | 5 +++++ docker/production/stable/nginx.conf | 5 +++++ 3 files changed, 15 insertions(+) diff --git a/docker/development/nginx.conf b/docker/development/nginx.conf index cda09b56..e714ee76 100644 --- a/docker/development/nginx.conf +++ b/docker/development/nginx.conf @@ -49,6 +49,11 @@ http { add_header Cache-Control "public, must-revalidate, proxy-revalidate"; } + location = /favicon.ico { + # serve the Shaarli favicon from its custom location + alias /var/www/shaarli/images/favicon.ico; + } + location ~ (index)\.php$ { # filter and proxy PHP requests to PHP-FPM fastcgi_pass unix:/var/run/php5-fpm.sock; diff --git a/docker/production/nginx.conf b/docker/production/nginx.conf index e23c4587..f7d59fc8 100644 --- a/docker/production/nginx.conf +++ b/docker/production/nginx.conf @@ -41,6 +41,11 @@ http { add_header Cache-Control "public, must-revalidate, proxy-revalidate"; } + location = /favicon.ico { + # serve the Shaarli favicon from its custom location + alias /var/www/shaarli/images/favicon.ico; + } + location ~ (index)\.php$ { # filter and proxy PHP requests to PHP-FPM fastcgi_pass unix:/var/run/php5-fpm.sock; diff --git a/docker/production/stable/nginx.conf b/docker/production/stable/nginx.conf index e23c4587..f7d59fc8 100644 --- a/docker/production/stable/nginx.conf +++ b/docker/production/stable/nginx.conf @@ -41,6 +41,11 @@ http { add_header Cache-Control "public, must-revalidate, proxy-revalidate"; } + location = /favicon.ico { + # serve the Shaarli favicon from its custom location + alias /var/www/shaarli/images/favicon.ico; + } + location ~ (index)\.php$ { # filter and proxy PHP requests to PHP-FPM fastcgi_pass unix:/var/run/php5-fpm.sock; -- 2.41.0