From ba46de6bc2cb2e121003f755996660808d0dd259 Mon Sep 17 00:00:00 2001 From: David Landry Date: Fri, 24 May 2024 23:51:02 -0400 Subject: [PATCH] chore(argocd): restore ksops integration --- .../argocd-repo-server-ksops-patch.yaml | 61 ++++++++++--------- 1 file changed, 31 insertions(+), 30 deletions(-) diff --git a/bootstrap/argo-cd/argocd-repo-server-ksops-patch.yaml b/bootstrap/argo-cd/argocd-repo-server-ksops-patch.yaml index bef31a7..7bc4390 100644 --- a/bootstrap/argo-cd/argocd-repo-server-ksops-patch.yaml +++ b/bootstrap/argo-cd/argocd-repo-server-ksops-patch.yaml @@ -14,37 +14,38 @@ spec: secret: secretName: sops-age # 2. Use an init container to download/copy custom binaries into the emptyDir - # initContainers: - # - name: install-ksops - # image: viaductoss/ksops:v4.3.1 - # command: ["/bin/sh", "-c"] - # args: - # - echo "Installing KSOPS..."; - # mv ksops /custom-tools/; - # mv kustomize /custom-tools/; - # echo "Done."; - # volumeMounts: - # - mountPath: /custom-tools - # name: custom-tools - # # 3. Volume mount the custom binary to the bin directory (overriding the existing version) - # containers: - # - name: argocd-repo-server - # volumeMounts: - # - mountPath: /usr/local/bin/kustomize - # name: custom-tools - # subPath: kustomize - # - mountPath: /usr/local/bin/ksops - # name: custom-tools - # subPath: ksops - # - name: sops-age - # readOnly: true - # mountPath: "/.config/sops/age" + initContainers: + - name: install-ksops + image: viaductoss/ksops:v4.3.1 + command: ["/bin/sh", "-c"] + args: + - echo "Installing KSOPS..."; + mv ksops /custom-tools/; + mv kustomize /custom-tools/; + echo "Done."; + volumeMounts: + - mountPath: /custom-tools + name: custom-tools + # 3. Volume mount the custom binary to the bin directory (overriding the existing version) + containers: + - name: argocd-repo-server + volumeMounts: + - mountPath: /usr/local/bin/kustomize + name: custom-tools + subPath: kustomize + - mountPath: /usr/local/bin/ksops + name: custom-tools + subPath: ksops + - name: sops-age + readOnly: true + mountPath: "/.config/sops/age" + + env: + - name: XDG_CONFIG_HOME + value: /.config + - name: SOPS_AGE_KEY_FILE + value: /.config/sops/age/keys.txt - env: - - name: XDG_CONFIG_HOME - value: /.config - - name: SOPS_AGE_KEY_FILE - value: /.config/sops/age/keys.txt ## If you use AWS or GCP KMS, don't forget to include the necessary credentials to decrypt the secrets! # env: # - name: AWS_ACCESS_KEY_ID