diff --git a/charts/kkp-argocd-apps/Chart.yaml b/charts/kkp-argocd-apps/Chart.yaml index c598635..414e9c9 100644 --- a/charts/kkp-argocd-apps/Chart.yaml +++ b/charts/kkp-argocd-apps/Chart.yaml @@ -29,7 +29,7 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 0.1.2 +version: 0.1.3 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to diff --git a/charts/kkp-argocd-apps/templates/argocd-apps-backup.yaml b/charts/kkp-argocd-apps/templates/argocd-apps-backup.yaml index 5841368..d14fb1e 100644 --- a/charts/kkp-argocd-apps/templates/argocd-apps-backup.yaml +++ b/charts/kkp-argocd-apps/templates/argocd-apps-backup.yaml @@ -13,12 +13,6 @@ # limitations under the License. {{ if .Values.velero.enable }} ---- -apiVersion: v1 -kind: Namespace -metadata: - name: velero - --- apiVersion: argoproj.io/v1alpha1 kind: Application @@ -48,8 +42,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: velero - {{- if .Values.velero.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.velero.autoSync }} automated: {} {{ end }} {{ end }} diff --git a/charts/kkp-argocd-apps/templates/argocd-apps-kkp-core.yaml b/charts/kkp-argocd-apps/templates/argocd-apps-kkp-core.yaml index 109b2e6..fc9911f 100644 --- a/charts/kkp-argocd-apps/templates/argocd-apps-kkp-core.yaml +++ b/charts/kkp-argocd-apps/templates/argocd-apps-kkp-core.yaml @@ -12,13 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -{{ if or .Values.seedSettings.enable .Values.seedExtras.enable }} ---- -apiVersion: v1 -kind: Namespace -metadata: - name: kubermatic -{{ end }} --- apiVersion: argoproj.io/v1alpha1 kind: AppProject @@ -40,11 +33,6 @@ spec: {{ if .Values.oauth.enable }} --- -apiVersion: v1 -kind: Namespace -metadata: - name: oauth ---- apiVersion: argoproj.io/v1alpha1 kind: Application metadata: @@ -69,19 +57,16 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: oauth - {{- if .Values.oauth.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.oauth.autoSync }} automated: {} {{ end }} {{ end }} {{ if .Values.nginx.enable }} --- -apiVersion: v1 -kind: Namespace -metadata: - name: nginx-ingress-controller ---- apiVersion: argoproj.io/v1alpha1 kind: Application metadata: @@ -107,8 +92,10 @@ spec: server: 'https://kubernetes.default.svc' namespace: nginx-ingress-controller # nginx ingress app to be synced automatically so that we can access ArgoCD via it! - {{- if .Values.nginx.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.nginx.autoSync }} automated: {} {{ end }} {{ end }} @@ -116,11 +103,6 @@ spec: {{ if .Values.certManager.enable }} --- -apiVersion: v1 -kind: Namespace -metadata: - name: cert-manager ---- apiVersion: argoproj.io/v1alpha1 kind: Application metadata: @@ -148,9 +130,11 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: cert-manager - # cert-manager app to be synced automatically so that we get certificates issued for KKP dashboard and ArgoCD to start with - {{- if .Values.certManager.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.certManager.autoSync }} + # cert-manager app to be synced automatically so that we get certificates issued for KKP dashboard and ArgoCD to start with automated: {} {{ end }} {{ end }} @@ -164,7 +148,6 @@ metadata: namespace: argocd spec: project: kubermatic-config - project: default sources: - repoURL: '{{ .Values.repoURL }}' targetRevision: {{ template "git-tag-version" . }} @@ -172,8 +155,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: kubermatic - {{- if .Values.seedSettings.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.seedSettings.autoSync }} automated: {} {{ end }} {{ end }} @@ -187,20 +172,21 @@ metadata: namespace: argocd spec: project: kubermatic-config - project: default sources: - repoURL: '{{ .Values.repoURL }}' targetRevision: {{ template "git-tag-version" . }} path: '{{ .Values.environment }}' directory: recurse: true - exclude: 'values.yaml' + exclude: 'values.yaml,{{ .Values.userMlaValuesFileName }}' include: '{common/*,{{ .Values.seed }}/*}' destination: server: 'https://kubernetes.default.svc' namespace: kubermatic - {{- if .Values.seedExtras.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.seedExtras.autoSync }} automated: {} {{ end }} {{ end }} \ No newline at end of file diff --git a/charts/kkp-argocd-apps/templates/argocd-apps-logging.yaml b/charts/kkp-argocd-apps/templates/argocd-apps-logging.yaml index 91f36f9..a937ae8 100644 --- a/charts/kkp-argocd-apps/templates/argocd-apps-logging.yaml +++ b/charts/kkp-argocd-apps/templates/argocd-apps-logging.yaml @@ -12,14 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -{{ if or .Values.promtail.enable .Values.loki.enable }} ---- -apiVersion: v1 -kind: Namespace -metadata: - name: logging -{{ end }} - {{ if .Values.promtail.enable }} --- apiVersion: argoproj.io/v1alpha1 @@ -47,8 +39,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: logging - {{- if .Values.promtail.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.promtail.autoSync }} automated: {} {{ end }} {{ end }} @@ -79,8 +73,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: logging - {{- if .Values.loki.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.loki.autoSync }} automated: {} {{ end }} {{ end }} diff --git a/charts/kkp-argocd-apps/templates/argocd-apps-monitoring.yaml b/charts/kkp-argocd-apps/templates/argocd-apps-monitoring.yaml index 083027a..19425e0 100644 --- a/charts/kkp-argocd-apps/templates/argocd-apps-monitoring.yaml +++ b/charts/kkp-argocd-apps/templates/argocd-apps-monitoring.yaml @@ -12,14 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -{{ if or .Values.prometheus .Values.alertManager.enable .Values.grafana.enable .Values.kubeStateMetrics.enable .Values.nodeExporter.enable .Values.blackboxExporter.enable .Values.thanos.enable }} ---- -apiVersion: v1 -kind: Namespace -metadata: - name: monitoring -{{ end }} - {{ if .Values.prometheus.enable }} --- apiVersion: argoproj.io/v1alpha1 @@ -46,8 +38,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: monitoring - {{- if .Values.prometheus.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.prometheus.autoSync }} automated: {} {{ end }} {{ end }} @@ -78,8 +72,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: monitoring - {{- if .Values.alertManager.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.alertManager.autoSync }} automated: {} {{ end }} {{ end }} @@ -113,7 +109,8 @@ spec: # need to work around long annotations for dashboard configmaps syncPolicy: syncOptions: - - ServerSideApply=true + - CreateNamespace=true + - ServerSideApply=true {{- if .Values.grafana.autoSync }} automated: {} {{ end }} @@ -151,8 +148,10 @@ spec: kind: Deployment jsonPointers: - /spec/template/spec/containers/0/resources - {{- if .Values.kubeStateMetrics.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.kubeStateMetrics.autoSync }} automated: {} {{ end }} {{ end }} @@ -183,8 +182,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: monitoring - {{- if .Values.nodeExporter.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.nodeExporter.autoSync }} automated: {} {{ end }} {{ end }} @@ -215,8 +216,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: monitoring - {{- if .Values.blackboxExporter.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.blackboxExporter.autoSync }} automated: {} {{ end }} {{ end }} @@ -252,8 +255,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: monitoring - {{- if .Values.thanos.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.thanos.autoSync }} automated: {} {{ end }} {{ end }} @@ -262,11 +267,6 @@ spec: {{ if .Values.iapSeedMla.enable }} --- -apiVersion: v1 -kind: Namespace -metadata: - name: iap ---- apiVersion: argoproj.io/v1alpha1 kind: Application metadata: @@ -291,8 +291,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: iap - {{- if .Values.iapSeedMla.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.iapSeedMla.autoSync }} automated: {} {{ end }} {{ end }} \ No newline at end of file diff --git a/charts/kkp-argocd-apps/templates/argocd-apps-storage.yaml b/charts/kkp-argocd-apps/templates/argocd-apps-storage.yaml index 6bec3be..c497dac 100644 --- a/charts/kkp-argocd-apps/templates/argocd-apps-storage.yaml +++ b/charts/kkp-argocd-apps/templates/argocd-apps-storage.yaml @@ -13,12 +13,6 @@ # limitations under the License. {{ if .Values.minio.enable }} ---- -apiVersion: v1 -kind: Namespace -metadata: - name: minio - --- apiVersion: argoproj.io/v1alpha1 kind: Application @@ -44,8 +38,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: minio - {{- if .Values.minio.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.minio.autoSync }} automated: {} {{ end }} {{ end }} diff --git a/charts/kkp-argocd-apps/templates/argocd-apps-usermla.yaml b/charts/kkp-argocd-apps/templates/argocd-apps-usermla.yaml index 5326e79..03a582e 100644 --- a/charts/kkp-argocd-apps/templates/argocd-apps-usermla.yaml +++ b/charts/kkp-argocd-apps/templates/argocd-apps-usermla.yaml @@ -31,11 +31,6 @@ spec: destinations: - namespace: mla server: https://kubernetes.default.svc ---- -apiVersion: v1 -kind: Namespace -metadata: - name: mla {{ end }} {{ if and .Values.userMla.enable .Values.userMla.minio.enable }} @@ -64,8 +59,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: mla - {{- if .Values.userMla.minio.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.userMla.minio.autoSync }} automated: {} {{ end }} {{ end }} @@ -98,8 +95,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: mla - {{- if .Values.userMla.secrets.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.userMla.secrets.autoSync }} automated: {} {{ end }} --- @@ -130,8 +129,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: mla - {{- if .Values.userMla.minioLifecycleMgr.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.userMla.minioLifecycleMgr.autoSync }} automated: {} {{ end }} {{ end }} @@ -162,8 +163,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: mla - {{- if .Values.userMla.grafana.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.userMla.grafana.autoSync }} automated: {} {{ end }} {{ end }} @@ -194,8 +197,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: mla - {{- if .Values.userMla.consul.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.userMla.consul.autoSync }} automated: {} {{ end }} {{ end }} @@ -225,8 +230,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: mla - {{- if .Values.userMla.alertmanagerProxy.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.userMla.alertmanagerProxy.autoSync }} automated: {} {{ end }} {{ end }} @@ -257,8 +264,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: mla - {{- if .Values.userMla.cortex.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.userMla.cortex.autoSync }} automated: {} {{ end }} @@ -297,8 +306,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: mla - {{- if .Values.userMla.lokiDistributed.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.userMla.lokiDistributed.autoSync }} automated: {} {{ end }} {{ end }} @@ -329,8 +340,10 @@ spec: destination: server: 'https://kubernetes.default.svc' namespace: mla - {{- if .Values.userMla.iapMla.autoSync }} syncPolicy: + syncOptions: + - CreateNamespace=true + {{- if .Values.userMla.iapMla.autoSync }} automated: {} {{ end }} {{ end }}