From 52962512975f1e88b27a6870f83c8aa8f2b2b695 Mon Sep 17 00:00:00 2001 From: Negash Date: Wed, 27 Dec 2023 11:45:58 +0000 Subject: [PATCH] Use token on url path --- chart/templates/generator-application.yaml | 6 +----- chart/templates/ingress-auth.yaml | 10 ---------- chart/values.yaml | 6 ++---- 3 files changed, 3 insertions(+), 19 deletions(-) delete mode 100644 chart/templates/ingress-auth.yaml diff --git a/chart/templates/generator-application.yaml b/chart/templates/generator-application.yaml index 72f0450..814aa11 100644 --- a/chart/templates/generator-application.yaml +++ b/chart/templates/generator-application.yaml @@ -219,10 +219,6 @@ spec: generateName: ingress-{{ template "aldaas.fullname" . }}- labels: aldaas: '{{`{{inputs.parameters.pvc-name}}`}}' - annotations: - nginx.ingress.kubernetes.io/auth-type: basic - nginx.ingress.kubernetes.io/auth-secret: "{{ template "aldaas.fullname" . }}-ingress-auth" - nginx.ingress.kubernetes.io/auth-realm: 'Authentication Required' spec: rules: - host: {{ .Values.domain }} @@ -233,5 +229,5 @@ spec: name: '{{`{{inputs.parameters.service-name}}`}}' port: number: {{ .Values.tunnel.port }} - path: /{{ template "aldaas.fullname" . }}/{{`{{inputs.parameters.service-name}}`}} + path: /{{ template "aldaas.fullname" . }}/{{ .Values.tunnel.token }}/{{`{{inputs.parameters.service-name}}`}} pathType: Prefix \ No newline at end of file diff --git a/chart/templates/ingress-auth.yaml b/chart/templates/ingress-auth.yaml deleted file mode 100644 index ca5809a..0000000 --- a/chart/templates/ingress-auth.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if empty .Values.tunnel.auth.htpasswd }} -apiVersion: v1 -kind: Secret -metadata: - name: "{{ template "aldaas.fullname" . }}-ingress-auth" - namespace: {{ .Release.Namespace }} -type: Opaque -stringData: - auth: {{ .Values.tunnel.auth.htpasswd | default (htpasswd .Values.tunnel.auth.username .Values.tunnel.auth.password) | quote }} -{{- end -}} \ No newline at end of file diff --git a/chart/values.yaml b/chart/values.yaml index feb55c0..ad0d2f6 100644 --- a/chart/values.yaml +++ b/chart/values.yaml @@ -10,10 +10,8 @@ tunnel: image: ghcr.io/negashev/aldaas tag: main port: 8080 - auth: - username: admin - password: passw0rd - htpasswd: + # set some random for your aldaas instance + token: 9fKLQhjGWrHZ3pOSQLKmWlUxoJXkCJqbFs8WeT3EEG8AwKEL4B8YavzXYOApVaXfi2ZVLx77YhsbVyDJTY0l8maSiYKEm6WDyopM rook: storageClassName: ceph-block volumeSnapshotClassName: ceph-block