feat(argocd-apps): adopt additional Applications/Projects to argocd-apps chart (#1356)

Signed-off-by: yu-croco <yuki.kita22@gmail.com>
This commit is contained in:
Aikawa 2022-08-22 21:32:07 +09:00 committed by GitHub
parent 914021b38a
commit 798c8107c3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 260 additions and 0 deletions

View file

@ -0,0 +1,42 @@
{{- range .Values.applications }}
---
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
{{- with .additionalAnnotations }}
annotations:
{{- range $key, $value := . }}
{{ $key }}: {{ $value | quote }}
{{- end }}
{{- end }}
{{- with .additionalLabels }}
labels:
{{- toYaml . | nindent 4 }}
{{- end }}
name: {{ .name }}
{{- with .namespace }}
namespace: {{ . }}
{{- end }}
{{- with .finalizers }}
finalizers:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
project: {{ tpl .project $ }}
source:
{{- toYaml .source | nindent 4 }}
destination:
{{- toYaml .destination | nindent 4 }}
{{- with .syncPolicy }}
syncPolicy:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .ignoreDifferences }}
ignoreDifferences:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .info }}
info:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- end }}

View file

@ -0,0 +1,62 @@
{{- range .Values.projects }}
---
apiVersion: argoproj.io/v1alpha1
kind: AppProject
metadata:
{{- with .additionalAnnotations }}
annotations:
{{- range $key, $value := . }}
{{ $key }}: {{ $value | quote }}
{{- end }}
{{- end }}
{{- with .additionalLabels }}
labels:
{{- toYaml . | nindent 4 }}
{{- end }}
name: {{ .name }}
{{- with .namespace }}
namespace: {{ . }}
{{- end }}
{{- with .finalizers }}
finalizers:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
description: {{ .description }}
sourceRepos:
{{- toYaml .sourceRepos | nindent 4 }}
destinations:
{{- toYaml .destinations | nindent 4 }}
{{- with .clusterResourceWhitelist }}
clusterResourceWhitelist:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .clusterResourceBlacklist }}
clusterResourceBlacklist:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .namespaceResourceBlacklist }}
namespaceResourceBlacklist:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .namespaceResourceWhitelist }}
namespaceResourceWhitelist:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .orphanedResources }}
orphanedResources:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .roles }}
roles:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .syncWindows }}
syncWindows:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .signatureKeys }}
signatureKeys:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- end }}