From b916743cc7d8227c8498570abd1a0a692ee28393 Mon Sep 17 00:00:00 2001 From: Jean-Christian Denis Date: Sat, 23 Nov 2024 20:10:32 +0100 Subject: [PATCH] fix custom subdomain --- etc/snippets_subdomain.conf | 3 --- www/servers/subdomain.conf | 5 +++++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/etc/snippets_subdomain.conf b/etc/snippets_subdomain.conf index 80256a6..782e6a0 100644 --- a/etc/snippets_subdomain.conf +++ b/etc/snippets_subdomain.conf @@ -12,9 +12,6 @@ client_max_body_size 32m; if ($dc_blog_id = '') { set $dc_blog_id default; } -if ($dc_blog_id = 'stable') { - set $dc_blog_id default; -} # Blogs public paths location ~ /public { diff --git a/www/servers/subdomain.conf b/www/servers/subdomain.conf index 3293562..5f04b31 100644 --- a/www/servers/subdomain.conf +++ b/www/servers/subdomain.conf @@ -9,6 +9,11 @@ server { # - ... server_name ~^(?\w*?)?\.?(\w+\.\w+)$; + # Redirect a particular subdomain + if ($dc_blog_id = 'blog') { + set $dc_blog_id default; + } + # To use custom configuration only use # include /etc/nginx/snippets/snippets_common.conf; # Adapt to your needs here the content of