From aae018af413c3b6f6b823225aa7f9899463af4a7 Mon Sep 17 00:00:00 2001
From: Adar Nimrod <nimrod@shore.co.il>
Date: Sun, 13 Dec 2020 21:24:28 +0200
Subject: [PATCH] Redirect cgit to GitLab.

Now that I finished migrating all repos (FINALLY!!!).
---
 conf.d/www.shore.co.il.conf | 24 ++++--------------------
 1 file changed, 4 insertions(+), 20 deletions(-)

diff --git a/conf.d/www.shore.co.il.conf b/conf.d/www.shore.co.il.conf
index 35504f6..4b63afe 100644
--- a/conf.d/www.shore.co.il.conf
+++ b/conf.d/www.shore.co.il.conf
@@ -1,4 +1,3 @@
-map $host $cgit { default cgit; }
 map $host $lam { default ldap-account-manager; }
 map $host $kodi { default kodi.shore.co.il; }
 
@@ -40,25 +39,10 @@ server {
         charset UTF-8;
     }
 
-    location /cgit/ {
-        proxy_pass          http://$cgit$uri;
-        proxy_http_version  1.1;
-        include             snippets/proxy-headers.conf;
-    }
-
-    location /git {
-        rewrite             ^/git /cgit/;
-    }
-
-    location /git/ {
-        rewrite             ^/git/(.*) /cgit/$1;
-    }
-
-    location /cgit-css/ {
-        proxy_pass          http://$cgit$request_uri;
-        proxy_http_version  1.1;
-        include             snippets/proxy-headers.conf;
-    }
+    location /cgit          { return 301 https://git.shore.co.il/explore; }
+    location /cgit/         { return 301 https://git.shore.co.il/explore; }
+    location /git           { return 301 https://git.shore.co.il/explore; }
+    location /git/          { return 301 https://git.shore.co.il/explore; }
 
     location /lam {
         proxy_pass          http://$lam$request_uri;
-- 
GitLab