diff --git a/charts/harbor-operator/README.md b/charts/harbor-operator/README.md index f8cf072bc..effedef23 100644 --- a/charts/harbor-operator/README.md +++ b/charts/harbor-operator/README.md @@ -36,6 +36,7 @@ Deploy Harbor Operator | fullnameOverride | string | `""` | | | harborClass | string | `""` | Class name of the Harbor operator | | image.pullPolicy | string | `"IfNotPresent"` | The image pull policy for the controller. | +| image.registry | string | `"docker.io"` | The image registry whose default is docker.io. | | image.repository | string | `"goharbor/harbor-operator"` | The image repository whose default is the chart appVersion. | | image.tag | string | `"dev_master"` | The image tag whose default is the chart appVersion. | | imagePullSecrets | list | `[]` | Reference to one or more secrets to be used when pulling images For example: `[ {"name":"image-pull-secret"} ]` | diff --git a/charts/harbor-operator/templates/deployment.yaml b/charts/harbor-operator/templates/deployment.yaml index c8fb1e34e..7ba20688d 100644 --- a/charts/harbor-operator/templates/deployment.yaml +++ b/charts/harbor-operator/templates/deployment.yaml @@ -33,7 +33,7 @@ spec: valueFrom: fieldRef: fieldPath: metadata.namespace - image: '{{.Values.image.repository}}:{{.Values.image.tag|default .Chart.AppVersion}}' + image: '{{.Values.image.registry}}/{{.Values.image.repository}}:{{.Values.image.tag|default .Chart.AppVersion}}' imagePullPolicy: {{ .Values.image.pullPolicy | quote }} livenessProbe: httpGet: diff --git a/charts/harbor-operator/values.yaml b/charts/harbor-operator/values.yaml index cba44af9e..617a7e2cb 100644 --- a/charts/harbor-operator/values.yaml +++ b/charts/harbor-operator/values.yaml @@ -1,4 +1,6 @@ image: + # image.registry -- The image registry whose default is docker.io. + registry: docker.io # image.repository -- The image repository whose default is the chart appVersion. repository: goharbor/harbor-operator # image.pullPolicy -- The image pull policy for the controller. diff --git a/config/helm/deployment/kustomization.yaml b/config/helm/deployment/kustomization.yaml index f7b00aebb..c75c1221b 100644 --- a/config/helm/deployment/kustomization.yaml +++ b/config/helm/deployment/kustomization.yaml @@ -7,7 +7,7 @@ generatorOptions: images: - name: goharbor/harbor-operator:dev - newName: '{{.Values.image.repository}}' + newName: '{{.Values.image.registry}}/{{.Values.image.repository}}' newTag: '{{.Values.image.tag|default .Chart.AppVersion}}' patches: