Skip to content

Commit f864775

Browse files
meili-bors[bot]R0BB3RTbrunoocasali
authored
Merge #261
261: feat: add digest support for image r=brunoocasali a=R0BB3RT # Pull Request ## Related issue Fixes #260 ## What does this PR do? - Adds support for specifying a container image by digest in the Meilisearch Helm chart. - This makes it possible to deploy Meilisearch in Kubernetes clusters that enforce immutable image references (e.g., via Sigstore Policy Controller). - The change is backward-compatible: existing repository:tag configurations continue to work without modification. ## Basic example ``` image: repository: getmeili/meilisearch digest: "sha256:19b825993dbe80c61eec65de7e7096cd545a09a744d8d00f3dd117185ebb36f9" tag: "" # leave empty when using digest ``` Renders as: `image: getmeili/meilisearch@sha256:19b825993dbe80c61eec65de7e7096cd545a09a744d8d00f3dd117185ebb36f9` If digest is not defined, the chart continues to render: `image: getmeili/meilisearch:latest` (or whatever tag is provided). ## PR checklist Please check if your PR fulfills the following requirements: - [x] Does this PR fix an existing issue, or have you listed the changes applied in the PR description (and why they are needed)? - [x] Have you read the contributing guidelines? - [x] Have you made sure that the title is accurate and descriptive of the changes? Co-authored-by: R0BB3RT <[email protected]> Co-authored-by: Bruno Casali <[email protected]> Co-authored-by: brunoocasali <[email protected]>
2 parents d3a2c56 + 312d933 commit f864775

File tree

4 files changed

+4
-3
lines changed

4 files changed

+4
-3
lines changed

charts/meilisearch/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ apiVersion: v1
22
appVersion: "v1.18.0"
33
description: A Helm chart for the Meilisearch search engine
44
name: meilisearch
5-
version: 0.17.0
5+
version: 0.17.1
66
icon: https://raw.githubusercontent.com/meilisearch/integration-guides/main/assets/logos/logo.svg
77
home: https://github.com/meilisearch/meilisearch-kubernetes/tree/main/charts/meilisearch
88
maintainers:

charts/meilisearch/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@ You can also use `auth.existingMasterKeySecret` to use an existing secret that h
6868
| image.pullSecret | string | `nil` | Secret to authenticate against the docker registry |
6969
| image.repository | string | `"getmeili/meilisearch"` | Meilisearch image name |
7070
| image.tag | string | `"v1.2.0"` | Meilisearch image tag |
71+
| image.digest | string | `""` | Meilisearch image digest in the way sha256:aa.... Please note this parameter, if set, will override the tag |
7172
| ingress.annotations | object | `{}` | Ingress annotations |
7273
| ingress.className | string | `"nginx"` | Ingress ingressClassName |
7374
| ingress.enabled | bool | `false` | Enable ingress controller resource |

charts/meilisearch/templates/statefulset.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ spec:
5757

5858
containers:
5959
- name: {{ .Chart.Name }}
60-
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
60+
image: "{{ .Values.image.repository }}{{- if .Values.image.digest }}@{{ .Values.image.digest }}{{- else }}:{{ .Values.image.tag }}{{- end }}"
6161
imagePullPolicy: {{ .Values.image.pullPolicy }}
6262
securityContext:
6363
{{ toYaml .Values.securityContext | indent 12 }}

manifests/meilisearch.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ spec:
7575
app.kubernetes.io/component: search-engine
7676
app.kubernetes.io/part-of: meilisearch
7777
annotations:
78-
checksum/config: e94f5cb3ce20f3053874a38a565d15332a00d03e78a7d14f0dc491ee22aeac5b
78+
checksum/config: 46784f3f8961bc1abfab68cae9f48677d8e1334cbaffd6c4f2cf0da7aa56a4ac
7979
spec:
8080
serviceAccountName: meilisearch
8181
securityContext:

0 commit comments

Comments
 (0)