From ee355d116ecb07d15b64042983651fd82c63493d Mon Sep 17 00:00:00 2001 From: Badal Kumar Prusty Date: Sun, 7 Apr 2024 02:17:48 +0530 Subject: [PATCH] expose global container registry for all microservices --- charts/devtron/templates/_helpers.tpl | 16 +++++ charts/devtron/templates/app-sync-job.yaml | 6 +- charts/devtron/templates/dashboard.yaml | 2 +- charts/devtron/templates/devtron.yaml | 6 +- charts/devtron/templates/dex.yaml | 4 +- charts/devtron/templates/gitsensor.yaml | 4 +- charts/devtron/templates/grafana.yaml | 22 +++--- charts/devtron/templates/install.yaml | 7 +- charts/devtron/templates/kubelink.yaml | 2 +- charts/devtron/templates/kubewatch.yaml | 2 +- charts/devtron/templates/lens.yaml | 2 +- charts/devtron/templates/migrator.yaml | 26 ++++--- charts/devtron/templates/minio.yaml | 6 +- charts/devtron/templates/nats-server.yaml | 13 ++-- charts/devtron/templates/notifier.yaml | 2 +- charts/devtron/templates/postgresql.yaml | 12 ++-- charts/devtron/templates/workflow.yaml | 6 +- charts/devtron/values.yaml | 80 ++++++++++++++++------ 18 files changed, 136 insertions(+), 82 deletions(-) diff --git a/charts/devtron/templates/_helpers.tpl b/charts/devtron/templates/_helpers.tpl index 19789e59c7..a1cb53f4e0 100644 --- a/charts/devtron/templates/_helpers.tpl +++ b/charts/devtron/templates/_helpers.tpl @@ -18,3 +18,19 @@ it randomly. {{- randAlphaNum $len -}} {{- end -}} {{- end }} + +{{- define "fullImage" }} +{{- $registryName := .currentPosition.registry | default .global.containerRegistry -}} +{{- $imageName := .image | default .currentPosition.image -}} +{{- $imageTag := .tag | default .currentPosition.tag -}} +{{- $imageDigest := .digest | default .currentPosition.digest -}} +{{- if and $registryName $imageName $imageTag $imageDigest }} + {{- printf "%s/%s:%s@%s" $registryName $imageName $imageTag $imageDigest -}} +{{- else if and $registryName $imageName $imageTag -}} + {{- printf "%s/%s:%s" $registryName $imageName $imageTag -}} +{{- else if and $registryName $imageName $imageDigest }} + {{- printf "%s/%s@%s" $registryName $imageName $imageDigest -}} +{{- else }} + {{- printf "%s/%s" $registryName $imageName -}} +{{- end }} +{{- end -}} diff --git a/charts/devtron/templates/app-sync-job.yaml b/charts/devtron/templates/app-sync-job.yaml index f17183e69c..4f0e6dd5ed 100644 --- a/charts/devtron/templates/app-sync-job.yaml +++ b/charts/devtron/templates/app-sync-job.yaml @@ -13,7 +13,7 @@ spec: serviceAccountName: devtron initContainers: - name: migration-wait - image: "quay.io/devtron/kubectl:latest" + image: {{ include "fullImage" (dict "currentPosition" $.Values.kubectlUtility "global" $.Values.global ) }} command: ['sh', '-c', 'while [ ! $(kubectl -n devtroncd get $(kubectl -n devtroncd get job -l job=postgresql-migrate-devtron -o name) -o jsonpath="{.status.succeeded}") ]; do sleep 10; done'] {{- if .Values.components.migrator }} {{- if .Values.components.migrator.appSync }} @@ -31,7 +31,7 @@ spec: {{- end }} containers: - name: chart-sync - image: quay.io/devtron/chart-sync:d0dcc590-373-21074 + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.appsyncjob "image" $.Values.components.appsyncjob.extraImage "digest" $.Values.components.appsyncjob.extraDigest "global" $.Values.global ) }} {{- if and $.Values.global $.Values.global.containerSecurityContext }} securityContext: {{- toYaml $.Values.global.containerSecurityContext | nindent 10 }} @@ -80,7 +80,7 @@ spec: {{- end }} containers: - name: chart-sync - image: quay.io/devtron/chart-sync:d0dcc590-373-21074 + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.appsyncjob.chartsync "global" $.Values.global ) }} {{- if and $.Values.global $.Values.global.containerSecurityContext }} securityContext: {{- toYaml $.Values.global.containerSecurityContext | nindent 14 }} diff --git a/charts/devtron/templates/dashboard.yaml b/charts/devtron/templates/dashboard.yaml index 188191eca7..300560fd59 100644 --- a/charts/devtron/templates/dashboard.yaml +++ b/charts/devtron/templates/dashboard.yaml @@ -79,7 +79,7 @@ spec: {{- end }} containers: - name: dashboard - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.dashboard "global" $.Values.global ) }} imagePullPolicy: {{ .imagePullPolicy }} {{- if and $.Values.global $.Values.global.containerSecurityContext }} securityContext: diff --git a/charts/devtron/templates/devtron.yaml b/charts/devtron/templates/devtron.yaml index 227d02dcc4..0cb390907a 100644 --- a/charts/devtron/templates/devtron.yaml +++ b/charts/devtron/templates/devtron.yaml @@ -114,12 +114,12 @@ spec: - name: devtron {{- if $.Values.installer.modules }} {{- if and (has "cicd" $.Values.installer.modules) ($.Release.IsUpgrade) }} - image: {{ $.Values.components.devtron.cicdImage }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.devtron "image" $.Values.components.devtron.cicdImage "digest" $.Values.components.devtron.cicdImageDigest "global" $.Values.global ) }} {{- else }} - image: {{ $.Values.components.devtron.image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.devtron "image" $.Values.components.devtron.image "digest" $.Values.components.devtron.digest "global" $.Values.global ) }} {{- end }} {{- else }} - image: {{ $.Values.components.devtron.image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.devtron "image" $.Values.components.devtron.image "digest" $.Values.components.devtron.digest "global" $.Values.global ) }} {{- end }} imagePullPolicy: {{ .imagePullPolicy }} {{- if and $.Values.global $.Values.global.containerSecurityContext }} diff --git a/charts/devtron/templates/dex.yaml b/charts/devtron/templates/dex.yaml index 82ef6f6b84..cfcf0f9e9d 100644 --- a/charts/devtron/templates/dex.yaml +++ b/charts/devtron/templates/dex.yaml @@ -76,7 +76,7 @@ spec: - command: - /shared/authenticator - rundex - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.argocdDexServer "global" $.Values.global ) }} imagePullPolicy: {{ .imagePullPolicy }} name: dex {{- if and $.Values.global $.Values.global.containerSecurityContext }} @@ -100,7 +100,7 @@ spec: - -n - /authenticator - /shared - image: {{ .initContainer.authenticator }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.argocdDexServer.initContainer "image" $.Values.components.argocdDexServer.initContainer.authenticator "digest" $.Values.components.argocdDexServer.initContainer.digest "global" $.Values.global ) }} imagePullPolicy: IfNotPresent name: copyutil {{- if and $.Values.global $.Values.global.containerSecurityContext }} diff --git a/charts/devtron/templates/gitsensor.yaml b/charts/devtron/templates/gitsensor.yaml index 356dec9ee6..8752e97148 100644 --- a/charts/devtron/templates/gitsensor.yaml +++ b/charts/devtron/templates/gitsensor.yaml @@ -77,7 +77,7 @@ spec: - /bin/sh - -c - mkdir -p /git-base/ssh-keys && chown -R devtron:devtron /git-base && chmod 777 /git-base/ssh-keys - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.gitsensor "global" $.Values.global ) }} imagePullPolicy: IfNotPresent name: chown-git-base resources: {} @@ -90,7 +90,7 @@ spec: name: git-volume containers: - name: git-sensor - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.gitsensor "global" $.Values.global ) }} {{- if .imagePullPolicy }} imagePullPolicy: {{ .imagePullPolicy }} {{- end }} diff --git a/charts/devtron/templates/grafana.yaml b/charts/devtron/templates/grafana.yaml index 984b1cf3d1..b17f30c328 100644 --- a/charts/devtron/templates/grafana.yaml +++ b/charts/devtron/templates/grafana.yaml @@ -17,14 +17,14 @@ spec: serviceAccountName: devtron containers: - name: grafana-restart - image: "quay.io/devtron/kubectl:latest" + image: {{ include "fullImage" (dict "currentPosition" $.Values.monitoring.grafana.grafanaOrgJob "global" $.Values.global ) }} command: ["sh", "/tmp/kubectl-grafana.sh"] volumeMounts: - name: grafana-org-volume mountPath: "/tmp/" initContainers: - name: grafana-org - image: quay.io/devtron/k8s-utils:tutum-curl + image: {{ include "fullImage" (dict "currentPosition" $.Values.monitoring.grafana.grafanaOrgJob.initContainers "global" $.Values.global ) }} command: ["sh","/tmp/org.sh"] env: - name: GRAFANA_PASSWORD @@ -512,24 +512,22 @@ spec: runAsUser: 472 initContainers: - name: init-chown-data - image: "quay.io/devtron/busybox:1.31.1" + image: {{ include "fullImage" (dict "currentPosition" $.Values.monitoring.grafana.initContainer.chownData "global" $.Values.global ) }} imagePullPolicy: IfNotPresent securityContext: runAsNonRoot: false runAsUser: 0 command: ["chown", "-R", "472:472", "/var/lib/grafana"] - resources: - {} + resources: {} volumeMounts: - name: storage mountPath: "/var/lib/grafana" - name: download-dashboards - image: "quay.io/devtron/curl:7.73.0" + image: {{ include "fullImage" (dict "currentPosition" $.Values.monitoring.grafana.initContainer.downloadDashboards "global" $.Values.global ) }} imagePullPolicy: IfNotPresent command: ["/bin/sh"] args: [ "-c", "mkdir -p /var/lib/grafana/dashboards/default && /bin/sh /etc/grafana/download_dashboards.sh" ] - resources: - {} + resources: {} env: volumeMounts: - name: config @@ -538,7 +536,7 @@ spec: - name: storage mountPath: "/var/lib/grafana" - name: grafana-sc-datasources - image: "quay.io/kiwigrid/k8s-sidecar:1.1.0" + image: {{ include "fullImage" (dict "currentPosition" $.Values.monitoring.grafana.initContainer.grafanaDatasources "global" $.Values.global ) }} imagePullPolicy: IfNotPresent env: - name: METHOD @@ -557,7 +555,7 @@ spec: containers: {{- with $.Values.monitoring.grafana.grafanaDashboards }} - name: grafana-sc-dashboard - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.monitoring.grafana "global" $.Values.global ) }} imagePullPolicy: {{ .imagePullPolicy }} env: - name: METHOD @@ -578,7 +576,7 @@ spec: {{- end }} {{- with $.Values.monitoring.grafana}} - name: grafana - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.monitoring.grafana "global" $.Values.global ) }} imagePullPolicy: {{ .imagePullPolicy }} volumeMounts: - name: config @@ -662,7 +660,7 @@ spec: serviceAccountName: devtron-grafana-test containers: - name: devtron-test - image: "quay.io/devtron/bats:v1.4.1" + image: {{ include "fullImage" (dict "currentPosition" $.Values.monitoring.grafana.devtronGrafanaTest "global" $.Values.global ) }} imagePullPolicy: "IfNotPresent" command: ["/opt/bats/bin/bats", "-t", "/tests/run.sh"] volumeMounts: diff --git a/charts/devtron/templates/install.yaml b/charts/devtron/templates/install.yaml index e7ff9e3e74..5ab1334268 100644 --- a/charts/devtron/templates/install.yaml +++ b/charts/devtron/templates/install.yaml @@ -85,12 +85,7 @@ spec: {{- toYaml $.Values.global.podSecurityContext | nindent 8 }} {{- end }} containers: - - - {{- if $.Values.installer.tag }} - image: {{ $.Values.installer.image }}:{{ $.Values.installer.tag }} - {{- else }} - image: {{ $.Values.installer.image }} - {{- end }} + - image: {{ include "fullImage" (dict "currentPosition" $.Values.installer "global" $.Values.global ) }} imagePullPolicy: IfNotPresent name: inception {{- if and $.Values.global $.Values.global.containerSecurityContext }} diff --git a/charts/devtron/templates/kubelink.yaml b/charts/devtron/templates/kubelink.yaml index 5b5e2b8807..eaf4f7455c 100644 --- a/charts/devtron/templates/kubelink.yaml +++ b/charts/devtron/templates/kubelink.yaml @@ -66,7 +66,7 @@ spec: {{- end }} containers: - name: kubelink - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.kubelink "global" $.Values.global ) }} imagePullPolicy: {{ .imagePullPolicy }} {{- if and $.Values.global $.Values.global.containerSecurityContext }} securityContext: diff --git a/charts/devtron/templates/kubewatch.yaml b/charts/devtron/templates/kubewatch.yaml index bd5749d275..4c6ad4d281 100644 --- a/charts/devtron/templates/kubewatch.yaml +++ b/charts/devtron/templates/kubewatch.yaml @@ -176,7 +176,7 @@ spec: {{- end }} containers: - name: kubewatch - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.kubewatch "global" $.Values.global ) }} imagePullPolicy: {{ .imagePullPolicy }} {{- if and $.Values.global $.Values.global.containerSecurityContext }} securityContext: diff --git a/charts/devtron/templates/lens.yaml b/charts/devtron/templates/lens.yaml index 76328fb7dc..cfbfc36e21 100644 --- a/charts/devtron/templates/lens.yaml +++ b/charts/devtron/templates/lens.yaml @@ -73,7 +73,7 @@ spec: {{- end }} containers: - name: lens - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.lens "global" $.Values.global ) }} {{- if .imagePullPolicy }} imagePullPolicy: {{ .imagePullPolicy }} {{- end }} diff --git a/charts/devtron/templates/migrator.yaml b/charts/devtron/templates/migrator.yaml index a4414008ac..f5218cab44 100644 --- a/charts/devtron/templates/migrator.yaml +++ b/charts/devtron/templates/migrator.yaml @@ -33,7 +33,7 @@ spec: envFrom: - secretRef: name: devtron-secret - image: quay.io/devtron/devtron-utils:dup-chart-repo-v1.1.0 + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.migrator.devtron.initContainer.chartFix "global" $.Values.global ) }} {{- if and $.Values.global $.Values.global.containerSecurityContext }} securityContext: {{- toYaml $.Values.global.containerSecurityContext | nindent 12 }} @@ -43,7 +43,7 @@ spec: - /bin/sh - -c - cp -r /scripts/. /shared/ - image: {{ $.Values.components.devtron.image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.devtron "image" $.Values.components.devtron.cicdImage "digest" $.Values.components.devtron.cicdImageDigest "global" $.Values.global ) }} {{- if and $.Values.global $.Values.global.containerSecurityContext }} securityContext: {{- toYaml $.Values.global.containerSecurityContext | nindent 12 }} @@ -76,7 +76,7 @@ spec: - secretRef: name: postgresql-migrator {{- if .image }} - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.migrator "global" $.Values.global ) }} {{- else }} image: migrate/migrate {{- end }} @@ -120,7 +120,7 @@ spec: {{- end }} containers: - name: devtron-rollout - image: "quay.io/devtron/kubectl:latest" + image: {{ include "fullImage" (dict "currentPosition" $.Values.kubectlUtility "global" $.Values.global ) }} command: ['sh', '-c', 'kubectl rollout restart deployment/devtron -n devtroncd && kubectl rollout restart deployment/kubelink -n devtroncd'] {{- if .casbin }} {{- if .casbin.resources }} @@ -133,7 +133,7 @@ spec: - /bin/sh - -c - cp -r /scripts/. /shared/ - image: {{ $.Values.components.devtron.image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.devtron "image" $.Values.components.devtron.cicdImage "digest" $.Values.components.devtron.cicdImageDigest "global" $.Values.global ) }} name: init-devtron {{- if and $.Values.global $.Values.global.containerSecurityContext }} securityContext: @@ -165,7 +165,7 @@ spec: - secretRef: name: postgresql-migrator {{- if .image }} - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.migrator "global" $.Values.global ) }} {{- else }} image: migrate/migrate {{- end }} @@ -212,7 +212,7 @@ spec: - /bin/sh - -c - cp -r sql /shared/ - image: {{ $.Values.components.gitsensor.image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.gitsensor "global" $.Values.global ) }} {{- if and $.Values.global $.Values.global.containerSecurityContext }} securityContext: {{- toYaml $.Values.global.containerSecurityContext | nindent 12 }} @@ -245,7 +245,7 @@ spec: - secretRef: name: postgresql-migrator {{- if .image }} - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.migrator "global" $.Values.global ) }} {{- else }} image: migrate/migrate {{- end }} @@ -290,7 +290,7 @@ spec: - /bin/sh - -c - cp -r sql /shared/ - image: {{ $.Values.components.lens.image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.lens "global" $.Values.global ) }} name: init-lens {{- if and $.Values.global $.Values.global.containerSecurityContext }} securityContext: @@ -328,7 +328,7 @@ spec: - secretRef: name: postgresql-migrator {{- if .image }} - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.migrator "global" $.Values.global ) }} {{- else }} image: migrate/migrate {{- end }} @@ -366,7 +366,11 @@ spec: runAsUser: 1000 containers: - name: postgresql-miscellaneous - image: quay.io/devtron/postgres:11.9 + {{- if not $.Values.installer.arch }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.postgres "global" $.Values.global ) }} + {{- else }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.postgres.arm "global" $.Values.global ) }} + {{- end }} securityContext: allowPrivilegeEscalation: false runAsUser: 1000 diff --git a/charts/devtron/templates/minio.yaml b/charts/devtron/templates/minio.yaml index b637e73479..037a400c64 100644 --- a/charts/devtron/templates/minio.yaml +++ b/charts/devtron/templates/minio.yaml @@ -266,7 +266,7 @@ spec: fsGroup: 1000 containers: - name: minio - image: {{ $.Values.minio.image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.minio "global" $.Values.global ) }} imagePullPolicy: {{ $.Values.minio.imagePullPolicy }} command: [ "/bin/sh", @@ -339,7 +339,7 @@ spec: serviceAccountName: "devtron-minio" containers: - name: minio-mc - image: {{ $.Values.minio.mbImage }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.minio.miniomc "global" $.Values.global ) }} imagePullPolicy: {{ $.Values.minio.mbImagePullPolicy }} command: ["/bin/sh", "/config/initialize"] env: @@ -385,7 +385,7 @@ spec: serviceAccountName: "devtron-minio" containers: - name: minio - image: "quay.io/devtron/minio:RELEASE.2020-12-03T05-49-24Z" + image: {{ include "fullImage" (dict "currentPosition" $.Values.minio.miniomc "global" $.Values.global ) }} imagePullPolicy: IfNotPresent command: - "/bin/sh" diff --git a/charts/devtron/templates/nats-server.yaml b/charts/devtron/templates/nats-server.yaml index 87d360b6de..ec2ab5607a 100644 --- a/charts/devtron/templates/nats-server.yaml +++ b/charts/devtron/templates/nats-server.yaml @@ -29,6 +29,9 @@ data: jetstream { max_mem: 1Gi domain: devtron-jet + max_file_store: 5Gi + store_dir: "/data" + } lame_duck_duration: 120s --- @@ -120,7 +123,7 @@ spec: terminationGracePeriodSeconds: 120 containers: - name: nats - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.nats "global" $.Values.global ) }} imagePullPolicy: {{ .imagePullPolicy }} resources: {} @@ -165,7 +168,7 @@ spec: - name: pid mountPath: /var/run/nats - name: data - mountPath: /tmp/nats/jetstream + mountPath: /data # Liveness/Readiness probes against the monitoring. # @@ -203,7 +206,7 @@ spec: ################################# - name: reloader - image: {{ .reloader.image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.nats.reloader "global" $.Values.global ) }} imagePullPolicy: {{ .reloader.imagePullPolicy }} resources: null @@ -227,7 +230,7 @@ spec: ############################## - name: metrics - image: {{ .metrics.image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.nats.metrics "global" $.Values.global ) }} imagePullPolicy: {{ .metrics.imagePullPolicy }} resources: {} @@ -266,7 +269,7 @@ metadata: spec: containers: - name: nats-box - image: quay.io/devtron/nats-box + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.nats.natsBox "global" $.Values.global ) }} env: - name: NATS_HOST value: devtron-nats diff --git a/charts/devtron/templates/notifier.yaml b/charts/devtron/templates/notifier.yaml index 55b1c03190..0082de32c5 100644 --- a/charts/devtron/templates/notifier.yaml +++ b/charts/devtron/templates/notifier.yaml @@ -76,7 +76,7 @@ spec: restartPolicy: Always containers: - name: notifier - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.notifier "global" $.Values.global ) }} imagePullPolicy: {{ .imagePullPolicy }} ports: - name: app diff --git a/charts/devtron/templates/postgresql.yaml b/charts/devtron/templates/postgresql.yaml index 343f69e1ba..4ddf3c7800 100644 --- a/charts/devtron/templates/postgresql.yaml +++ b/charts/devtron/templates/postgresql.yaml @@ -117,7 +117,7 @@ spec: fsGroup: 1001 initContainers: - name: init-chmod-data - image: "quay.io/devtron/minideb:latest" + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.postgres.initContainers "global" $.Values.global ) }} imagePullPolicy: "IfNotPresent" command: - /bin/sh @@ -145,7 +145,7 @@ spec: mountPath: /dev/shm containers: - name: postgresql-postgresql - image: {{ .image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.postgres "global" $.Values.global ) }} imagePullPolicy: {{ .imagePullPolicy }} securityContext: runAsUser: 1001 @@ -212,7 +212,7 @@ spec: mountPath: /bitnami/postgresql subPath: - name: metrics - image: quay.io/devtron/postgres_exporter:v0.4.7 + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.postgres.metrics "global" $.Values.global ) }} imagePullPolicy: "IfNotPresent" env: - name: DATA_SOURCE_URI @@ -453,7 +453,7 @@ spec: runAsGroup: 999 runAsNonRoot: true runAsUser: 999 - image: {{ .armImage }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.postgres.arm "global" $.Values.global ) }} imagePullPolicy: {{ .imagePullPolicy }} {{- if .initContainer }} {{- if .initContainer.resources }} @@ -480,7 +480,7 @@ spec: runAsGroup: 999 runAsNonRoot: true runAsUser: 999 - image: {{ .armImage }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.postgres.arm "global" $.Values.global ) }} imagePullPolicy: {{ .imagePullPolicy }} {{- if .resources }} resources: @@ -546,7 +546,7 @@ spec: - mountPath: /etc/postgresql name: configs - name: metrics - image: prometheuscommunity/postgres-exporter:v0.10.1 + image: {{ include "fullImage" (dict "currentPosition" $.Values.components.postgres.metrics "global" $.Values.global ) }} imagePullPolicy: "IfNotPresent" env: - name: DATA_SOURCE_URI diff --git a/charts/devtron/templates/workflow.yaml b/charts/devtron/templates/workflow.yaml index 8d5a3a5e01..6df3141fff 100644 --- a/charts/devtron/templates/workflow.yaml +++ b/charts/devtron/templates/workflow.yaml @@ -1184,7 +1184,7 @@ spec: - workflow-controller-configmap - --executor-image {{- if $.Values.workflowController.IMDSv2Enforced }} - - {{ $.Values.workflowController.executorImage }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.workflowController.executor "global" $.Values.global ) }} {{- else }} - quay.io/argoproj/argoexec:v3.0.7 {{- end }} @@ -1201,9 +1201,9 @@ spec: value: v1 {{- end }} {{- if $.Values.workflowController.IMDSv2Enforced }} - image: {{ $.Values.workflowController.image }} + image: {{ include "fullImage" (dict "currentPosition" $.Values.workflowController "global" $.Values.global ) }} {{- else }} - image: quay.io/argoproj/workflow-controller:v3.0.7 + image: {{ include "fullImage" (dict "currentPosition" $.Values.workflowController.IMDSv1 "global" $.Values.global ) }} {{- end }} name: workflow-controller {{- if $.Values.workflowController.resources }} diff --git a/charts/devtron/values.yaml b/charts/devtron/values.yaml index 38e88ea3a8..f190081175 100644 --- a/charts/devtron/values.yaml +++ b/charts/devtron/values.yaml @@ -7,10 +7,12 @@ global: allowPrivilegeEscalation: false runAsUser: 1000 runAsNonRoot: true + containerRegistry: "quay.io/devtron" + installer: repo: "devtron-labs/devtron" release: "v0.6.28" - image: quay.io/devtron/inception + image: inception tag: 473deaa4-185-21582 source: "github" # Available options are github and gitee # mode: "dashboard" # Available options are dashboard, full and hyperion (deprecated) NOT USING THIS @@ -60,12 +62,12 @@ components: GLOBAL_API_TIMEOUT: "60000" TRIGGER_API_TIMEOUT: "60000" ENABLE_EXTERNAL_ARGO_CD: "false" - image: "quay.io/devtron/dashboard:9429b066-325-21529" + image: "dashboard:9429b066-325-21529" imagePullPolicy: IfNotPresent devtron: - image: "quay.io/devtron/hyperion:ca439071-280-21596" - cicdImage: "quay.io/devtron/devtron:ca439071-434-21597" + image: "hyperion:ca439071-280-21596" + cicdImage: "devtron:ca439071-434-21597" imagePullPolicy: IfNotPresent customOverrides: DEFAULT_CI_IMAGE: "quay.io/devtron/ci-runner:d5f875c7-138-21576" @@ -92,13 +94,13 @@ components: # - devtron.example.com argocdDexServer: - image: "ghcr.io/dexidp/dex:v2.30.2" + image: "dex:v2.30.2" imagePullPolicy: IfNotPresent initContainer: - authenticator: "quay.io/devtron/authenticator:e414faff-393-13273" + authenticator: "authenticator:e414faff-393-13273" kubelink: - image: "quay.io/devtron/kubelink:7c66e0fc-564-21516" + image: "kubelink:7c66e0fc-564-21516" imagePullPolicy: IfNotPresent configs: ENABLE_HELM_RELEASE_CACHE: "true" @@ -115,7 +117,7 @@ components: keyName: postgresql-password kubewatch: - image: "quay.io/devtron/kubewatch:91c2cece-419-21178" + image: "kubewatch:91c2cece-419-21178" imagePullPolicy: IfNotPresent configs: devtroncd_NAMESPACE: "devtron-ci" @@ -125,13 +127,19 @@ components: NATS_STREAM_MAX_AGE: "10800" postgres: - image: "quay.io/devtron/postgres:11.9.0-debian-10-r26" - armImage: "quay.io/devtron/postgres:11.9" + image: "postgres:11.9.0-debian-10-r26" + arm: + image: "postgres:11.9" + initContainers: + image: minideb:latest + metrics: + image: postgres_exporter:v0.4.7 imagePullPolicy: "IfNotPresent" persistence: volumeSize: "20Gi" + gitsensor: - image: "quay.io/devtron/git-sensor:4bacf5f7-200-21575" + image: "git-sensor:4bacf5f7-200-21575" imagePullPolicy: "IfNotPresent" serviceMonitor: enabled: false @@ -147,7 +155,7 @@ components: secretName: postgresql-postgresql keyName: postgresql-password lens: - image: "quay.io/devtron/lens:70577aaa-333-21179" + image: "lens:70577aaa-333-21179" imagePullPolicy: IfNotPresent configs: GIT_SENSOR_PROTOCOL: GRPC @@ -164,17 +172,19 @@ components: image: nats:2.9.3-alpine imagePullPolicy: IfNotPresent reloader: - image: quay.io/devtron/nats-server-config-reloader:0.6.2 + image: nats-server-config-reloader:0.6.2 imagePullPolicy: IfNotPresent metrics: - image: quay.io/devtron/prometheus-nats-exporter:0.9.0 + image: prometheus-nats-exporter:0.9.0 imagePullPolicy: IfNotPresent + natsBox: + image: nats-box serviceMonitor: enabled: false persistence: storage: 5Gi migrator: - image: "quay.io/devtron/migrator:v4.16.2" + image: "migrator:v4.16.2" envVars: devtron: DB_NAME: "orchestrator" @@ -184,6 +194,14 @@ components: DB_NAME: "git_sensor" lens: DB_NAME: "lens" + devtron: + initContainer: + chartFix: + image: devtron-utils:dup-chart-repo-v1.1.0 + appsyncjob: + chartsync: + image: chart-sync:d0dcc590-373-21074 + extraImage: chart-sync:d0dcc590-373-21074 # values for argocd integration argo-cd: @@ -341,7 +359,7 @@ argo-cd: security: enabled: false imageScanner: - image: "quay.io/devtron/image-scanner:bdbcef05-334-21577" + image: "image-scanner:bdbcef05-334-21577" # Values for trivy trivy: enabled: false @@ -353,7 +371,7 @@ security: notifier: enabled: false imagePullPolicy: IfNotPresent - image: "quay.io/devtron/notifier:e4ffc71a-372-20776" + image: "notifier:e4ffc71a-372-20776" configs: CD_ENVIRONMENT: PROD DB: orchestrator @@ -369,9 +387,10 @@ notifier: minio: enabled: false replicaCount: 1 - image: "quay.io/devtron/minio:RELEASE.2021-02-14T04-01-33Z" + image: "minio:RELEASE.2021-02-14T04-01-33Z" imagePullPolicy: IfNotPresent - mbImage: "quay.io/devtron/minio-mc:RELEASE.2021-02-14T04-28-06Z" + miniomc: + image: "minio-mc:RELEASE.2021-02-14T04-28-06Z" mbImagePullPolicy: IfNotPresent persistence: storage: "50Gi" @@ -380,18 +399,37 @@ workflowController: # Set this to true if you have IMDSv2 enforced or IMDSv1 and v2 on your AWS EKS cluster and false if you are using IMDSv1 with token hop limit set to 1 IMDSv2Enforced: true image: "quay.io/argoproj/workflow-controller:v3.4.3" - executorImage: "quay.io/argoproj/argoexec:v3.4.3" + executor: + image: "quay.io/argoproj/argoexec:v3.4.3" + IMDSv1: + image: quay.io/argoproj/workflow-controller:v3.0.7 # Values for grafana integration monitoring: grafana: enabled: false - image: "quay.io/devtron/grafana:7.3.1" + image: "grafana:7.3.1" imagePullPolicy: IfNotPresent resources: {} + initContainer: + chownData: + image: "busybox:1.31.1" + downloadDashboards: + image: "curl:7.73.0" + grafanaDatasources: + image: "quay.io/kiwigrid/k8s-sidecar:1.1.0" grafanaDashboards: image: "quay.io/kiwigrid/k8s-sidecar:1.1.0" imagePullPolicy: IfNotPresent resources: {} + grafanaOrgJob: + image: "kubectl:latest" + initContainers: + image: k8s-utils:tutum-curl + devtronGrafanaTest: + image: "bats:v1.4.1" persistence: storage: "2Gi" + +kubectlUtility: + image: kubectl:latest