From fa906663216e2111f4641678f3387c19fa706aef Mon Sep 17 00:00:00 2001 From: Andrey Cherkashin Date: Mon, 2 Oct 2023 15:19:00 -0700 Subject: [PATCH] [BEI-189] Add ingress to tekton-cron --- charts/tekton-cron-jobs/Chart.yaml | 2 +- .../tekton-cron-jobs/templates/ingress.yaml | 28 +++++++++++++++++++ charts/tekton-cron-jobs/values.yaml | 3 ++ 3 files changed, 32 insertions(+), 1 deletion(-) create mode 100644 charts/tekton-cron-jobs/templates/ingress.yaml diff --git a/charts/tekton-cron-jobs/Chart.yaml b/charts/tekton-cron-jobs/Chart.yaml index 64e0c8a..5c26f50 100644 --- a/charts/tekton-cron-jobs/Chart.yaml +++ b/charts/tekton-cron-jobs/Chart.yaml @@ -15,7 +15,7 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 0.1.2 +version: 0.1.3 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to diff --git a/charts/tekton-cron-jobs/templates/ingress.yaml b/charts/tekton-cron-jobs/templates/ingress.yaml new file mode 100644 index 0000000..e9eaa41 --- /dev/null +++ b/charts/tekton-cron-jobs/templates/ingress.yaml @@ -0,0 +1,28 @@ + +{{- if .Values.ingress.enabled -}} +{{- $hostwithdashestls := printf "%s-tls" .Values.ingress.host | replace "." "-" }} +apiVersion: networking.k8s.io/v1 +kind: Ingress +metadata: + name: "tekton-cron" + annotations: + cert-manager.io/cluster-issuer: letsencrypt + kubernetes.io/ingress.class: "nginx-internal" + kubernetes.io/tls-acme: "true" +spec: + rules: + - host: {{ .Values.ingress.host }} + http: + paths: + - backend: + service: + name: el-tekton-cron + port: + number: 8080 + path: / + pathType: ImplementationSpecific + tls: + - hosts: + - {{ .Values.ingress.host }} + secretName: {{ $hostwithdashestls }} +{{- end }} diff --git a/charts/tekton-cron-jobs/values.yaml b/charts/tekton-cron-jobs/values.yaml index 0576182..53423cb 100644 --- a/charts/tekton-cron-jobs/values.yaml +++ b/charts/tekton-cron-jobs/values.yaml @@ -1 +1,4 @@ eventListener: {} +ingress: + enabled: false + host: tekton-cron.gen1.trydave.com