From 5f14386dcdd3530c79a31678a1a3bf59e3ddb6ef Mon Sep 17 00:00:00 2001 From: makefunstuff Date: Fri, 28 Jun 2024 15:42:09 +0300 Subject: broken --- tools/argocd/templates/deployment.yaml | 5 +++-- tools/argocd/templates/ingress.yaml | 15 ++++++++++----- tools/argocd/templates/secret.yaml | 11 +++++++++++ 3 files changed, 24 insertions(+), 7 deletions(-) create mode 100644 tools/argocd/templates/secret.yaml (limited to 'tools/argocd/templates') diff --git a/tools/argocd/templates/deployment.yaml b/tools/argocd/templates/deployment.yaml index b2fa31e..e0daf82 100644 --- a/tools/argocd/templates/deployment.yaml +++ b/tools/argocd/templates/deployment.yaml @@ -9,7 +9,7 @@ metadata: name: argocd-server namespace: argocd spec: - replicas: { { .Values.replicas "1" } } + replicas: {{ .Values.replicas }} selector: matchLabels: app: argocd-server @@ -27,5 +27,6 @@ spec: - name: ARGOCD_SERVER_ADMIN_PASSWORD valueFrom: secretKeyRef: - name: argocd-server + name: argocd-secret key: admin.password + diff --git a/tools/argocd/templates/ingress.yaml b/tools/argocd/templates/ingress.yaml index 5793540..1253287 100644 --- a/tools/argocd/templates/ingress.yaml +++ b/tools/argocd/templates/ingress.yaml @@ -2,17 +2,22 @@ apiVersion: networking.k8s.io/v1 kind: Ingress metadata: name: argocd-ingress - namespace: { { .Values.namespace } } + namespace: {{ .Values.namespace }} annotations: kubernetes.io/ingress.class: - { { .Values.ingress.annotations."kubernetes.io/ingress.class" } } + {{ .Values.ingress.annotations.kubernetes_io_ingress_class }} cert-manager.io/cluster-issuer: letsencrypt-prod + traefik.ingress.kubernetes.io/router.entrypoints: websecure + traefik.ingress.kubernetes.io/router.tls: "true" + traefik.ingress.kubernetes.io/router.tls.certresolver: "default" traefik.ingress.kubernetes.io/redirect-entry-point: https + traefik.ingress.kubernetes.io/router.tls.domains.0.main: topkek.cloud + traefik.ingress.kubernetes.io/router.tls.domains.0.sans: argocd.topkek.cloud traefik.ingress.kubernetes.io/ssl-redirect: "true" traefik.ingress.kubernetes.io/tls-acme: "true" spec: rules: - - host: { { .Values.ingress.hostname } } + - host: {{ .Values.ingress.hostname }} http: paths: - path: / @@ -24,5 +29,5 @@ spec: number: 80 tls: - hosts: - - { { .Values.ingress.hostname } } - secretName: { { .Values.ingress.tls.secretName } } + - {{ .Values.ingress.hostname }} + secretName: {{ .Values.ingress.tls.secretName }} diff --git a/tools/argocd/templates/secret.yaml b/tools/argocd/templates/secret.yaml new file mode 100644 index 0000000..c80372c --- /dev/null +++ b/tools/argocd/templates/secret.yaml @@ -0,0 +1,11 @@ +{{- if not (lookup "v1" "Secret" .Values.namespace "argocd-secret") }} +apiVersion: v1 +kind: Secret +metadata: + name: argocd-secret + namespace: {{ .Values.namespace }} +type: Opaque +data: + admin.password: {{ .Values.argocd.adminPassword | b64enc }} +{{- end }} + -- cgit 1.4.1-2-gfad0