From 7cd2d4159b4dac2ae5cb1f1be875b2c8efa2011d Mon Sep 17 00:00:00 2001 From: Manuel Cilurzo Date: Sat, 24 Aug 2024 09:03:07 +0200 Subject: [PATCH] versuch #2 --- .github/default.conf | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/.github/default.conf b/.github/default.conf index d73fba2e7..b5d301430 100644 --- a/.github/default.conf +++ b/.github/default.conf @@ -36,6 +36,10 @@ server { root /usr/share/nginx/html; index index.html index.htm; + if ($http_host = "digital-alias.app.sbb.ch") { + return 301 $scheme://digital.sbb.ch$request_uri; + } + rewrite ^([^.]*[^/])$ $1/ permanent; port_in_redirect off; autoindex on; @@ -44,15 +48,5 @@ server { location / { try_files $uri $uri/ =404; } - - -} - - - -server { - listen 8080 - server_name digital-alias.app.sbb.ch; - rewrite ^/(.*)$ http://digital.sbb.ch/$1 redirect; } \ No newline at end of file