Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion helm/solr-operator/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ annotations:
- name: Github PR
url: https://github.com/apache/solr-operator/pull/790
- kind: fixed
description: Correct the placement and syntax of the imagePullSecret in the Solr-Operator Helm chart
description: Correct the placement and syntax of the image.imagePullSecret in the Solr-Operator Helm chart
links:
- name: Github PR
url: https://github.com/apache/solr-operator/pull/782
Expand All @@ -124,6 +124,13 @@ annotations:
url: https://github.com/apache/solr-operator/issues/817
- name: Github PR
url: https://github.com/apache/solr-operator/pull/818
- kind: added
description: Support global.imagePullSecrets for pulling images from private registries, this is merged with image.imagePullSecret. Both accept plain strings in addition to objects
links:
- name: Github Issue
url: https://github.com/apache/solr-operator/issues/338
- name: Github PR
url: https://github.com/apache/solr-operator/pull/832
artifacthub.io/images: |
- name: solr-operator
image: apache/solr-operator:v0.10.0-prerelease
Expand Down
1 change: 1 addition & 0 deletions helm/solr-operator/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,7 @@ The command removes all the Kubernetes components associated with the chart and

| Key | Type | Default | Description |
|-----|------|---------|-------------|
| global.imagePullSecrets | []object/string | `[]` | Secrets for pulling images from private registries. Accepts both Kubernetes-native format (`[{name: "secret"}]`) and plain strings (`["secret"]`). |
| image.repository | string | `"apache/solr-operator"` | The repository of the Solr Operator image |
| image.tag | string | `"v0.10.0-prerelease"` | The tag/version of the Solr Operator to run |
| image.pullPolicy | string | `"IfNotPresent"` | |
Expand Down
17 changes: 13 additions & 4 deletions helm/solr-operator/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,23 @@ spec:
{{ toYaml .Values.labels | nindent 8 }}
{{- end }}
spec:
{{- if or .Values.global.imagePullSecrets .Values.image.imagePullSecret }}
imagePullSecrets:
{{- range .Values.global.imagePullSecrets }}
{{- if kindIs "string" . }}
- name: {{ . }}
{{- else }}
- name: {{ required "Each entry in global.imagePullSecrets must be a string or an object with a 'name' field" .name }}
{{- end }}
{{- end }}
{{- with .Values.image.imagePullSecret }}
- name: {{ . }}
{{- end }}
{{- end }}
serviceAccountName: {{ include "solr-operator.serviceAccountName" . }}
{{- if .Values.priorityClassName }}
priorityClassName: {{ .Values.priorityClassName }}
{{- end }}
{{- if .Values.image.imagePullSecret }}
imagePullSecrets:
- name: {{ .Values.image.imagePullSecret }}
{{- end }}
containers:
- name: {{ .Chart.Name }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
Expand Down
5 changes: 5 additions & 0 deletions helm/solr-operator/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@

replicaCount: 1

global:
# List the secrets needed to pull images from a private registry.
# Accepts both Kubernetes-native format [{name: "secret"}] and plain strings ["secret"].
imagePullSecrets: []

# Development mode configures certain settings for convenient development.
# When 'true', logging will use: encoder=console, level=debug, stacktrace-level=warn
development: false
Expand Down
7 changes: 7 additions & 0 deletions helm/solr/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,13 @@ annotations:
links:
- name: Github PR
url: https://github.com/apache/solr-operator/pull/811
- kind: added
description: global.imagePullSecrets and podOptions.imagePullSecrets now accept plain strings in addition to objects, and are merged correctly into the Solr pods
links:
- name: Github Issue
url: https://github.com/apache/solr-operator/issues/338
- name: Github PR
url: https://github.com/apache/solr-operator/pull/832
artifacthub.io/containsSecurityUpdates: "false"
artifacthub.io/recommendations: |
- url: https://artifacthub.io/packages/helm/apache-solr/solr-operator
Expand Down
4 changes: 2 additions & 2 deletions helm/solr/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ Configure Solr to use a separate TLS certificate for client auth.

| Key | Type | Default | Description |
|-----|------|---------|-------------|
| global.imagePullSecrets | []object | | The list of imagePullSecrets to include in pods |
| global.imagePullSecrets | []object/string | | The list of imagePullSecrets to include in all pods (Solr and ZK). Accepts both Kubernetes-native format (`[{name: "secret"}]`) and plain strings (`["secret"]`). |
| global.clusterDomain | string | | The cluster domain the Kubernetes is addressed under. |

### Custom Kubernetes Options
Expand Down Expand Up @@ -300,7 +300,7 @@ When using the helm chart, omit `customSolrKubeOptions.`
| podOptions.readinessProbe | object | | Custom readiness probe for the Solr container |
| podOptions.startupProbe | object | | Custom startup probe for the Solr container |
| podOptions.lifecycle | object | | Custom lifecycle for the Solr container |
| podOptions.imagePullSecrets | []object | | List of image pull secrets to inject into the Solr pod, in addition to `global.imagePullSecrets` |
| podOptions.imagePullSecrets | []object/string | | List of image pull secrets to inject into the Solr pod, in addition to `global.imagePullSecrets`. Accepts both Kubernetes-native format (`[{name: "secret"}]`) and plain strings (`["secret"]`). |
| podOptions.volumes | []object | | List of additional volumes to attach to the Solr pod, and optionally how to mount them to the Solr container |
| statefulSetOptions.annotations | map[string]string | | Custom annotations to add to the Solr statefulSet |
| statefulSetOptions.labels | map[string]string | | Custom labels to add to the Solr statefulSet |
Expand Down
8 changes: 7 additions & 1 deletion helm/solr/templates/_custom_option_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,13 @@ containerSecurityContext:
{{ end }}
{{- if (or .Values.podOptions.imagePullSecrets .Values.global.imagePullSecrets) -}}
imagePullSecrets:
{{- toYaml (append .Values.podOptions.imagePullSecrets .Values.global.imagePullSecrets) | nindent 2 }}
{{- range (concat .Values.podOptions.imagePullSecrets .Values.global.imagePullSecrets) }}
{{- if kindIs "string" . }}
- name: {{ . }}
{{- else }}
- name: {{ required "Each entry in imagePullSecrets must be a string or an object with a 'name' field" .name }}
{{- end }}
{{- end }}
{{ end }}
{{- if .Values.podOptions.volumes -}}
volumes:
Expand Down
5 changes: 5 additions & 0 deletions helm/solr/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ fullnameOverride: ""
replicas: null

global:
# List the secrets needed to pull images from a private registry.
# Accepts both Kubernetes-native format [{name: "secret"}] and plain strings ["secret"].
# These are merged with podOptions.imagePullSecrets and applied to the Solr pods.
imagePullSecrets: []
clusterDomain: ""

Expand Down Expand Up @@ -325,6 +328,8 @@ podOptions:
# Lifecycle for the Solr container
lifecycle: {}

# List of image pull secrets to inject into the Solr pod, in addition to global.imagePullSecrets.
# Accepts both Kubernetes-native format [{name: "secret"}] and plain strings ["secret"].
imagePullSecrets: []

resources: {}
Expand Down
Loading