From 3b9c732dba33c6c529b2e332357e90bb13a6f1ee Mon Sep 17 00:00:00 2001
From: Theo Sanderson <theo@sndrsn.co.uk>
Date: Wed, 13 Dec 2023 10:12:50 +0000
Subject: [PATCH] chore: test helm template and remove argo links (#654)

* generate argocd links to lapis swagger per organism

* commit a helm template test

* move up and fix templateability check

* typo

* restore linebreak

* remove links
---
 .github/workflows/e2e-k3d.yml                   | 14 +++++++++++++-
 kubernetes/preview/templates/ingressroute.yaml  |  2 --
 kubernetes/preview/templates/lapis-ingress.yaml |  3 ---
 3 files changed, 13 insertions(+), 6 deletions(-)

diff --git a/.github/workflows/e2e-k3d.yml b/.github/workflows/e2e-k3d.yml
index 11777b179f..3f82dd889d 100644
--- a/.github/workflows/e2e-k3d.yml
+++ b/.github/workflows/e2e-k3d.yml
@@ -29,6 +29,18 @@ jobs:
       run: |
         ./deploy.py cluster
 
+    - name: Test helm template
+      uses: WyriHaximus/github-action-helm3@v3
+      with:
+        exec: helm template does-not-matter ./kubernetes/preview > defaultTemplate.yaml
+
+    - name: Upload default helm template
+      uses: actions/upload-artifact@v3
+      with:
+        name: default-helm-template
+        path: defaultTemplate.yaml
+      
+
     - name: Wait for Backend Docker Image
       uses: lewagon/wait-on-check-action@v1.3.1
       with:
@@ -42,7 +54,7 @@ jobs:
         ref: ${{ github.ref }}
         check-name: Build Website Docker Image
         repo-token: ${{ secrets.GITHUB_TOKEN }}
-      
+
     - name: Deploy with helm
       uses: WyriHaximus/github-action-helm3@v3
       with:
diff --git a/kubernetes/preview/templates/ingressroute.yaml b/kubernetes/preview/templates/ingressroute.yaml
index 53a02174da..d8ca19bf19 100644
--- a/kubernetes/preview/templates/ingressroute.yaml
+++ b/kubernetes/preview/templates/ingressroute.yaml
@@ -31,7 +31,6 @@ metadata:
   namespace: {{ .Values.namespace }}
   annotations:
     cert-manager.io/cluster-issuer: "letsencrypt-prod"
-    link.argocd.argoproj.io/external-link: https://{{ $backendHost }}
 spec:
   entryPoints:
     - websecure
@@ -52,7 +51,6 @@ metadata:
   namespace: {{ .Values.namespace }}
   annotations:
     cert-manager.io/cluster-issuer: "letsencrypt-prod"
-    link.argocd.argoproj.io/external-link: https://{{ $keycloakHost }}
 spec:
   entryPoints:
     - websecure
diff --git a/kubernetes/preview/templates/lapis-ingress.yaml b/kubernetes/preview/templates/lapis-ingress.yaml
index 221055b2ce..f95541e2fb 100644
--- a/kubernetes/preview/templates/lapis-ingress.yaml
+++ b/kubernetes/preview/templates/lapis-ingress.yaml
@@ -10,9 +10,6 @@ metadata:
   namespace: {{ $.Values.namespace }}
   annotations:
     cert-manager.io/cluster-issuer: "letsencrypt-prod"
-{{- if eq $.Values.environment "server" }}
-    link.argocd.argoproj.io/external-link: https://{{ $lapisHost }}
-{{- end }}
 spec:
   entryPoints:
     {{- if eq $.Values.environment "server" }}