add application of applications example (#29)

* add application of applications example

* Add a link in the readme
This commit is contained in:
Omer Kahani authored and Alexander Matyushentsev committed 2019-06-13 10:43:02 -07:00
1 parent 454cc52962
commit 08836bd970
10 files changed
+246

No files matched your search

+45
View File
@@ -0,0 +1,45 @@
{{- $namespace := .Values.argo_namespace -}}
{{- $chart_name := include "argo-cd.name" . -}}
{{- $chart := include "argo-cd.chart" . -}}
{{- range .Values.projects }}
apiVersion: argoproj.io/v1alpha1
kind: AppProject
metadata:
name: {{ .name }}
namespace: {{ $namespace }}
labels:
app.kubernetes.io/name: {{ $chart_name }}
helm.sh/chart: {{ $chart }}
app.kubernetes.io/instance: {{ $.Release.Name }}
app.kubernetes.io/managed-by: {{ $.Release.Service }}
app.kubernetes.io/part-of: {{ $chart_name }}
spec:
description: {{ .description }}
sourceRepos:
{{ toYaml .sourceRepos | indent 2 -}}
destinations:
{{- range .destinations }}
- namespace: {{ .namespaces }}
server: {{.server | default "https://kubernetes.default.svc" }}
{{- end }}
{{- if .clusterResourceWhitelist }}
clusterResourceWhitelist:
{{ toYaml .clusterResourceWhitelist| indent 2 }}
{{- end }}
roles:
{{- range .roles }}
- name: {{ .name }}
description: {{ .description }}
policies:
{{ toYaml .policies| indent 6 }}
jwtTokens:
{{ toYaml .jwtTokens| indent 6 }}
groups:
{{ toYaml .oidcGroups| indent 6 -}}
{{- end }}
---
{{- end }}