Compare commits

..

4 Commits

Author SHA1 Message Date
Feng Ruohang 08905a642d Merge pull request #351 from treydock/helm-updates
Signed-off-by: Feng Ruohang <rh@vonng.com>
2026-11-25 12:21:58 +08:00
Feng Ruohang 3960a36853 Merge branch 'main' into helm-updates 2026-11-25 12:05:02 +08:00
Feng Ruohang c78813cac9 Merge pull request #358 from pgsty/codex/fix-gobwas-ws-6940
Signed-off-by: Feng Ruohang <rh@vonng.com>
2026-11-25 12:04:42 +08:00
Trey Dockendorf 2b96153a61 [helm] Improvements to Helm chart
* Support releasing on “chart-<version>” tags, fixes #223
* Add commonLabels that are used on all resources
* Support templated values in numerous locations
* Add oidc.existingConfigMapName and oidc.existingConfigUrlKey
* Add networkPolicy.allowFrom
* support targetLabels on ServiceMonitor
* Support Probe relabelingConfigs
* Allow postJob default containerSecurityContext
* Allow policies to be templated string
* Set MINIO_BROWSER_REDIRECT_URL
* Ensure job egress only enabled when networkPolicy.egress.enabled set

Signed-off-by: Trey Dockendorf <tdockendorf@osc.edu>
2026-11-24 16:34:30 -05:00
23 changed files with 229 additions and 75 deletions
+31
View File
@@ -0,0 +1,31 @@
name: Publish Helm Chart to GHCR
on:
push:
tags:
- "chart-.*"
permissions:
contents: read
packages: write
jobs:
publish:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v7
- name: Install Helm
uses: azure/setup-helm@v4
- name: Log in to GitHub Container Registry
run: |
echo "${{ secrets.GITHUB_TOKEN }}" | helm registry login ghcr.io \
--username ${{ github.actor }} \
--password-stdin
- name: Package and Push Helm Chart
run: |
helm package helm/silo
helm push silo-*.tgz oci://ghcr.io/${{ github.repository_owner }}/charts
+1 -1
View File
@@ -1,7 +1,7 @@
apiVersion: v1 apiVersion: v1
description: S3-Interface Libre Object Storage description: S3-Interface Libre Object Storage
name: silo name: silo
version: 7.0.5 version: 7.1.0
appVersion: RELEASE.2026-11-12T00-00-00Z appVersion: RELEASE.2026-11-12T00-00-00Z
keywords: keywords:
- silo - silo
+8 -8
View File
@@ -7,15 +7,15 @@ The chart and server are licensed under AGPL-3.0-or-later.
## Prerequisites ## Prerequisites
- Kubernetes 1.19 or later - Kubernetes 1.19 or later
- Helm 3 - Helm 3 or 4
- A PersistentVolume provisioner unless `persistence.enabled=false` - A PersistentVolume provisioner unless `persistence.enabled=false`
## Install ## Install
From this repository: From GHCR:
```bash ```bash
helm install silo ./helm/silo \ helm install silo oci://ghcr.io/pgsty/charts/silo \
--namespace silo --create-namespace \ --namespace silo --create-namespace \
--set rootUser=silo-admin \ --set rootUser=silo-admin \
--set rootPassword='replace-with-a-long-random-secret' --set rootPassword='replace-with-a-long-random-secret'
@@ -24,7 +24,7 @@ helm install silo ./helm/silo \
For a disposable standalone installation: For a disposable standalone installation:
```bash ```bash
helm install silo ./helm/silo \ helm install silo oci://ghcr.io/pgsty/charts/silo \
--namespace silo --create-namespace \ --namespace silo --create-namespace \
--set mode=standalone \ --set mode=standalone \
--set replicas=1 \ --set replicas=1 \
@@ -64,7 +64,7 @@ helm get values my-release -n my-namespace -a > values.before-silo.yaml
SILO_TAG='<published-silo-release-tag>' SILO_TAG='<published-silo-release-tag>'
MCLI_TAG='<published-mcli-release-tag>' MCLI_TAG='<published-mcli-release-tag>'
helm template my-release ./helm/silo \ helm template my-release oci://ghcr.io/pgsty/charts/silo \
-n my-namespace \ -n my-namespace \
-f values.before-silo.yaml \ -f values.before-silo.yaml \
--set nameOverride=minio \ --set nameOverride=minio \
@@ -84,7 +84,7 @@ mounts. After review, upgrade the chart and image together:
```bash ```bash
SILO_TAG='<published-silo-release-tag>' SILO_TAG='<published-silo-release-tag>'
MCLI_TAG='<published-mcli-release-tag>' MCLI_TAG='<published-mcli-release-tag>'
helm upgrade my-release ./helm/silo \ helm upgrade my-release oci://ghcr.io/pgsty/charts/silo \
-n my-namespace \ -n my-namespace \
-f values.before-silo.yaml \ -f values.before-silo.yaml \
--set nameOverride=minio \ --set nameOverride=minio \
@@ -126,13 +126,13 @@ The default PersistentVolumeClaim mounts at `/export`. Use an existing claim
with: with:
```bash ```bash
helm install silo ./helm/silo --set persistence.existingClaim=PVC_NAME helm install silo oci://ghcr.io/pgsty/charts/silo --set persistence.existingClaim=PVC_NAME
``` ```
Create a TLS Secret containing `private.key` and `public.crt`, then set: Create a TLS Secret containing `private.key` and `public.crt`, then set:
```bash ```bash
helm upgrade --install silo ./helm/silo \ helm upgrade --install silo oci://ghcr.io/pgsty/charts/silo \
--set tls.enabled=true \ --set tls.enabled=true \
--set tls.certSecret=silo-tls --set tls.certSecret=silo-tls
``` ```
@@ -119,5 +119,5 @@ connectToSilo $scheme
{{ $global := . }} {{ $global := . }}
# Create the buckets # Create the buckets
{{- range .Values.buckets }} {{- range .Values.buckets }}
createBucket {{ tpl .name $global }} {{ .policy | default "none" | quote }} {{ .purge | default false }} {{ .versioning | default "" }} {{ .objectlocking | default false }}{{- end }} createBucket {{ tpl .name $global }} {{ tpl .policy $global | default "none" | quote }} {{ .purge | default false }} {{ .versioning | default "" }} {{ .objectlocking | default false }}{{- end }}
{{- end }} {{- end }}
@@ -68,8 +68,12 @@ scheme=http
connectToSilo $scheme connectToSilo $scheme
{{ if .Values.policies }} {{ if .Values.policies }}
{{- $policies := .Values.policies }}
{{- if typeIs "string" .Values.policies }}
{{- $policies = tpl .Values.policies . | fromYamlArray }}
{{- end }}
# Create the policies # Create the policies
{{- range $idx, $policy := .Values.policies }} {{- range $idx, $policy := $policies }}
createPolicy {{ $policy.name }} policy_{{ $idx }} createPolicy {{ $policy.name }} policy_{{ $idx }}
{{- end }} {{- end }}
{{- end }} {{- end }}
+5 -5
View File
@@ -131,14 +131,14 @@ Also, we can not use a single if because lazy evaluation is not an option
{{- if .Values.global }} {{- if .Values.global }}
{{- if .Values.global.imagePullSecrets }} {{- if .Values.global.imagePullSecrets }}
imagePullSecrets: imagePullSecrets:
{{ toYaml .Values.global.imagePullSecrets }} {{ tpl (toYaml .Values.global.imagePullSecrets) $ }}
{{- else if .Values.imagePullSecrets }} {{- else if .Values.imagePullSecrets }}
imagePullSecrets: imagePullSecrets:
{{ toYaml .Values.imagePullSecrets }} {{ tpl (toYaml .Values.imagePullSecrets) $ }}
{{- end -}} {{- end -}}
{{- else if .Values.imagePullSecrets }} {{- else if .Values.imagePullSecrets }}
imagePullSecrets: imagePullSecrets:
{{ toYaml .Values.imagePullSecrets }} {{ tpl (toYaml .Values.imagePullSecrets) $ }}
{{- end -}} {{- end -}}
{{- end -}} {{- end -}}
@@ -201,7 +201,7 @@ otherwise it generates a random value.
{{- define "silo.root.username" -}} {{- define "silo.root.username" -}}
{{- if .Values.rootUser }} {{- if .Values.rootUser }}
{{- .Values.rootUser | toString }} {{- tpl .Values.rootUser . | toString }}
{{- else }} {{- else }}
{{- include "silo.getValueFromSecret" (dict "Namespace" .Release.Namespace "Name" (include "silo.fullname" .) "Length" 20 "Key" "rootUser") }} {{- include "silo.getValueFromSecret" (dict "Namespace" .Release.Namespace "Name" (include "silo.fullname" .) "Length" 20 "Key" "rootUser") }}
{{- end }} {{- end }}
@@ -209,7 +209,7 @@ otherwise it generates a random value.
{{- define "silo.root.password" -}} {{- define "silo.root.password" -}}
{{- if .Values.rootPassword }} {{- if .Values.rootPassword }}
{{- .Values.rootPassword | toString }} {{- tpl .Values.rootPassword . | toString }}
{{- else }} {{- else }}
{{- include "silo.getValueFromSecret" (dict "Namespace" .Release.Namespace "Name" (include "silo.fullname" .) "Length" 40 "Key" "rootPassword") }} {{- include "silo.getValueFromSecret" (dict "Namespace" .Release.Namespace "Name" (include "silo.fullname" .) "Length" 40 "Key" "rootPassword") }}
{{- end }} {{- end }}
@@ -8,6 +8,9 @@ metadata:
chart: {{ template "silo.chart" . }} chart: {{ template "silo.chart" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
spec: spec:
endpointSelector: endpointSelector:
matchLabels: matchLabels:
+8 -1
View File
@@ -7,6 +7,9 @@ metadata:
chart: {{ template "silo.chart" . }} chart: {{ template "silo.chart" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
data: data:
initialize: |- initialize: |-
{{- include (print $.Template.BasePath "/_helper_create_bucket.txt") . | nindent 4 }} {{- include (print $.Template.BasePath "/_helper_create_bucket.txt") . | nindent 4 }}
@@ -14,7 +17,11 @@ data:
{{- include (print $.Template.BasePath "/_helper_create_user.txt") . | nindent 4 }} {{- include (print $.Template.BasePath "/_helper_create_user.txt") . | nindent 4 }}
add-policy: |- add-policy: |-
{{- include (print $.Template.BasePath "/_helper_create_policy.txt") . | nindent 4 }} {{- include (print $.Template.BasePath "/_helper_create_policy.txt") . | nindent 4 }}
{{- range $idx, $policy := .Values.policies }} {{- $policies := .Values.policies }}
{{- if typeIs "string" .Values.policies }}
{{- $policies = tpl .Values.policies . | fromYamlArray }}
{{- end }}
{{- range $idx, $policy := $policies }}
# Policy: {{ $policy.name }} # Policy: {{ $policy.name }}
policy_{{ $idx }}.json: |- policy_{{ $idx }}.json: |-
{{- include (print $.Template.BasePath "/_helper_policy.tpl") . | nindent 4 }} {{- include (print $.Template.BasePath "/_helper_policy.tpl") . | nindent 4 }}
+7 -4
View File
@@ -12,10 +12,13 @@ metadata:
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- with .Values.consoleIngress.labels }} {{- with .Values.consoleIngress.labels }}
{{- toYaml . | nindent 4 }} {{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
{{- with .Values.commonLabels }}
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }} {{- end }}
{{- with .Values.consoleIngress.annotations }} {{- with .Values.consoleIngress.annotations }}
annotations: {{- toYaml . | nindent 4 }} annotations: {{- tpl (toYaml .) $ | nindent 4 }}
{{- end }} {{- end }}
spec: spec:
{{- if .Values.consoleIngress.ingressClassName }} {{- if .Values.consoleIngress.ingressClassName }}
@@ -26,9 +29,9 @@ spec:
{{- range .Values.consoleIngress.tls }} {{- range .Values.consoleIngress.tls }}
- hosts: - hosts:
{{- range .hosts }} {{- range .hosts }}
- {{ . | quote }} - {{ tpl . $ | quote }}
{{- end }} {{- end }}
secretName: {{ .secretName }} secretName: {{ tpl .secretName $ }}
{{- end }} {{- end }}
{{- end }} {{- end }}
rules: rules:
+6 -2
View File
@@ -8,8 +8,12 @@ metadata:
chart: {{ template "silo.chart" . }} chart: {{ template "silo.chart" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- if .Values.consoleService.annotations }} {{- with .Values.commonLabels }}
annotations: {{- toYaml .Values.consoleService.annotations | nindent 4 }} {{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
{{- with .Values.consoleService.annotations }}
annotations:
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }} {{- end }}
spec: spec:
type: {{ .Values.consoleService.type }} type: {{ .Values.consoleService.type }}
+28 -10
View File
@@ -10,11 +10,15 @@ metadata:
chart: {{ template "silo.chart" . }} chart: {{ template "silo.chart" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- if .Values.additionalLabels }} {{- with .Values.additionalLabels }}
{{- toYaml .Values.additionalLabels | nindent 4 }} {{- tpl (toYaml .) $ | nindent 4 }}
{{- end }} {{- end }}
{{- if .Values.additionalAnnotations }} {{- with .Values.commonLabels }}
annotations: {{- toYaml .Values.additionalAnnotations | nindent 4 }} {{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
{{- with .Values.additionalAnnotations }}
annotations:
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }} {{- end }}
spec: spec:
strategy: strategy:
@@ -35,8 +39,11 @@ spec:
labels: labels:
app: {{ template "silo.name" . }} app: {{ template "silo.name" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
{{- if .Values.podLabels }} {{- with .Values.podLabels }}
{{- toYaml .Values.podLabels | nindent 8 }} {{- tpl (toYaml .) $ | nindent 8 }}
{{- end }}
{{- with .Values.commonLabels }}
{{- tpl (toYaml .) $ | nindent 8 }}
{{- end }} {{- end }}
annotations: annotations:
{{- if not .Values.ignoreChartChecksums }} {{- if not .Values.ignoreChartChecksums }}
@@ -62,7 +69,7 @@ spec:
{{- end }} {{- end }}
containers: containers:
- name: {{ include "silo.name" . }} - name: {{ include "silo.name" . }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" image: "{{ tpl .Values.image.repository . }}:{{ tpl .Values.image.tag . }}"
imagePullPolicy: {{ .Values.image.pullPolicy }} imagePullPolicy: {{ .Values.image.pullPolicy }}
command: command:
- "/bin/sh" - "/bin/sh"
@@ -111,7 +118,14 @@ spec:
{{- end }} {{- end }}
{{- if .Values.oidc.enabled }} {{- if .Values.oidc.enabled }}
- name: MINIO_IDENTITY_OPENID_CONFIG_URL - name: MINIO_IDENTITY_OPENID_CONFIG_URL
{{- if and .Values.oidc.existingConfigMapName .Values.oidc.existingConfigUrlKey }}
valueFrom:
configMapKeyRef:
name: {{ .Values.oidc.existingConfigMapName }}
key: {{ .Values.oidc.existingConfigUrlKey }}
{{- else }}
value: {{ .Values.oidc.configUrl }} value: {{ .Values.oidc.configUrl }}
{{- end }}
- name: MINIO_IDENTITY_OPENID_CLIENT_ID - name: MINIO_IDENTITY_OPENID_CLIENT_ID
{{- if and .Values.oidc.existingClientSecretName .Values.oidc.existingClientIdKey }} {{- if and .Values.oidc.existingClientSecretName .Values.oidc.existingClientIdKey }}
valueFrom: valueFrom:
@@ -135,11 +149,15 @@ spec:
- name: MINIO_IDENTITY_OPENID_CLAIM_PREFIX - name: MINIO_IDENTITY_OPENID_CLAIM_PREFIX
value: {{ .Values.oidc.claimPrefix }} value: {{ .Values.oidc.claimPrefix }}
- name: MINIO_IDENTITY_OPENID_SCOPES - name: MINIO_IDENTITY_OPENID_SCOPES
value: {{ .Values.oidc.scopes }} value: {{ tpl .Values.oidc.scopes . }}
- name: MINIO_IDENTITY_OPENID_COMMENT - name: MINIO_IDENTITY_OPENID_COMMENT
value: {{ .Values.oidc.comment }} value: {{ .Values.oidc.comment }}
{{- if .Values.oidc.redirectUri }}
- name: MINIO_IDENTITY_OPENID_REDIRECT_URI - name: MINIO_IDENTITY_OPENID_REDIRECT_URI
value: {{ .Values.oidc.redirectUri }} value: {{ tpl .Values.oidc.redirectUri . }}
{{- end }}
- name: MINIO_BROWSER_REDIRECT_URL
value: {{ tpl .Values.oidc.redirectUrl . }}
- name: MINIO_IDENTITY_OPENID_DISPLAY_NAME - name: MINIO_IDENTITY_OPENID_DISPLAY_NAME
value: {{ .Values.oidc.displayName }} value: {{ .Values.oidc.displayName }}
{{- end }} {{- end }}
@@ -181,7 +199,7 @@ spec:
{{- end }} {{- end }}
{{- end }} {{- end }}
{{- with .Values.nodeSelector }} {{- with .Values.nodeSelector }}
nodeSelector: {{- toYaml . | nindent 8 }} nodeSelector: {{- tpl (toYaml .) $ | nindent 8 }}
{{- end }} {{- end }}
{{- include "silo.imagePullSecrets" . | indent 6 }} {{- include "silo.imagePullSecrets" . | indent 6 }}
{{- with .Values.affinity }} {{- with .Values.affinity }}
+7 -4
View File
@@ -12,10 +12,13 @@ metadata:
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- with .Values.ingress.labels }} {{- with .Values.ingress.labels }}
{{- toYaml . | nindent 4 }} {{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
{{- with .Values.commonLabels }}
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }} {{- end }}
{{- with .Values.ingress.annotations }} {{- with .Values.ingress.annotations }}
annotations: {{- toYaml . | nindent 4 }} annotations: {{- tpl (toYaml .) $ | nindent 4 }}
{{- end }} {{- end }}
spec: spec:
{{- if .Values.ingress.ingressClassName }} {{- if .Values.ingress.ingressClassName }}
@@ -26,9 +29,9 @@ spec:
{{- range .Values.ingress.tls }} {{- range .Values.ingress.tls }}
- hosts: - hosts:
{{- range .hosts }} {{- range .hosts }}
- {{ . | quote }} - {{ tpl . $ | quote }}
{{- end }} {{- end }}
secretName: {{ .secretName }} secretName: {{ tpl .secretName $ }}
{{- end }} {{- end }}
{{- end }} {{- end }}
rules: rules:
+11 -3
View File
@@ -8,6 +8,9 @@ metadata:
chart: {{ template "silo.chart" . }} chart: {{ template "silo.chart" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
spec: spec:
podSelector: podSelector:
matchLabels: matchLabels:
@@ -19,11 +22,16 @@ spec:
protocol: TCP protocol: TCP
- port: {{ .Values.minioConsolePort }} - port: {{ .Values.minioConsolePort }}
protocol: TCP protocol: TCP
{{- if not .Values.networkPolicy.allowExternal }} {{- if or (not .Values.networkPolicy.allowExternal) .Values.networkPolicy.allowFrom }}
from: from:
{{- if not .Values.networkPolicy.allowExternal }}
- podSelector: - podSelector:
matchLabels: matchLabels:
{{ template "silo.name" . }}-client: "true" {{ template "silo.name" . }}-client: "true"
{{- end }}
{{- with .Values.networkPolicy.allowFrom }}
{{- tpl (toYaml .) $ | nindent 8 }}
{{- end }}
{{- end }} {{- end }}
{{- if .Values.networkPolicy.egress.enabled }} {{- if .Values.networkPolicy.egress.enabled }}
egress: egress:
@@ -34,6 +42,7 @@ spec:
{{- toYaml . | nindent 12 }} {{- toYaml . | nindent 12 }}
{{- end }} {{- end }}
{{- end }} {{- end }}
{{- if .Values.networkPolicy.egress.enabled }}
--- ---
kind: NetworkPolicy kind: NetworkPolicy
apiVersion: {{ template "silo.networkPolicy.apiVersion" . }} apiVersion: {{ template "silo.networkPolicy.apiVersion" . }}
@@ -55,12 +64,11 @@ spec:
protocol: TCP protocol: TCP
- port: {{ .Values.minioConsolePort }} - port: {{ .Values.minioConsolePort }}
protocol: TCP protocol: TCP
{{- if .Values.networkPolicy.egress.enabled }}
- ports: - ports:
{{ .Values.networkPolicy.egress.ports | toJson }} {{ .Values.networkPolicy.egress.ports | toJson }}
{{- with .Values.networkPolicy.egress.to }} {{- with .Values.networkPolicy.egress.to }}
to: to:
{{- toYaml . | nindent 12 }} {{- toYaml . | nindent 12 }}
{{- end }} {{- end }}
{{- end }} {{- end }}
{{- end }} {{- end }}
@@ -9,6 +9,9 @@ metadata:
name: {{ template "silo.fullname" . }} name: {{ template "silo.fullname" . }}
labels: labels:
app: {{ template "silo.name" . }} app: {{ template "silo.name" . }}
{{- with .Values.commonLabels }}
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
spec: spec:
maxUnavailable: {{ .Values.podDisruptionBudget.maxUnavailable }} maxUnavailable: {{ .Values.podDisruptionBudget.maxUnavailable }}
selector: selector:
+20 -14
View File
@@ -8,11 +8,14 @@ metadata:
chart: {{ template "silo.chart" . }} chart: {{ template "silo.chart" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
annotations: annotations:
"helm.sh/hook": post-install,post-upgrade "helm.sh/hook": post-install,post-upgrade
"helm.sh/hook-delete-policy": hook-succeeded,before-hook-creation "helm.sh/hook-delete-policy": hook-succeeded,before-hook-creation
{{- with .Values.postJob.annotations }} {{- with .Values.postJob.annotations }}
{{- toYaml . | nindent 4 }} {{- tpl (toYaml .) $ | nindent 4 }}
{{- end }} {{- end }}
spec: spec:
template: template:
@@ -23,14 +26,17 @@ spec:
{{- if .Values.podLabels }} {{- if .Values.podLabels }}
{{- toYaml .Values.podLabels | nindent 8 }} {{- toYaml .Values.podLabels | nindent 8 }}
{{- end }} {{- end }}
{{- with .Values.commonLabels }}
{{- tpl (toYaml .) $ | nindent 8 }}
{{- end }}
{{- if .Values.postJob.podAnnotations }} {{- if .Values.postJob.podAnnotations }}
annotations: {{- toYaml .Values.postJob.podAnnotations | nindent 8 }} annotations: {{- toYaml .Values.postJob.podAnnotations | nindent 8 }}
{{- end }} {{- end }}
spec: spec:
restartPolicy: OnFailure restartPolicy: OnFailure
{{- include "silo.imagePullSecrets" . | indent 6 }} {{- include "silo.imagePullSecrets" . | indent 6 }}
{{- if .Values.nodeSelector }} {{- if or .Values.nodeSelector .Values.postJob.nodeSelector }}
nodeSelector: {{- toYaml .Values.postJob.nodeSelector | nindent 8 }} nodeSelector: {{- tpl (toYaml .Values.postJob.nodeSelector | default .Values.nodeSelector) . | nindent 8 }}
{{- end }} {{- end }}
{{- with .Values.postJob.affinity }} {{- with .Values.postJob.affinity }}
affinity: {{- toYaml . | nindent 8 }} affinity: {{- toYaml . | nindent 8 }}
@@ -39,7 +45,7 @@ spec:
tolerations: {{- toYaml . | nindent 8 }} tolerations: {{- toYaml . | nindent 8 }}
{{- end }} {{- end }}
{{- if .Values.postJob.securityContext.enabled }} {{- if .Values.postJob.securityContext.enabled }}
securityContext: {{ omit .Values.postJob.securityContext "enabled" | toYaml | nindent 12 }} securityContext: {{ omit .Values.postJob.securityContext "enabled" | toYaml | nindent 8 }}
{{- end }} {{- end }}
volumes: volumes:
- name: etc-path - name: etc-path
@@ -88,9 +94,9 @@ spec:
{{- if .Values.policies }} {{- if .Values.policies }}
initContainers: initContainers:
- name: silo-make-policy - name: silo-make-policy
image: "{{ .Values.mcImage.repository }}:{{ .Values.mcImage.tag }}" image: "{{ tpl .Values.mcImage.repository . }}:{{ tpl .Values.mcImage.tag . }}"
{{- if .Values.makePolicyJob.securityContext.enabled }} {{- if .Values.makePolicyJob.securityContext.enabled }}
{{- with .Values.makePolicyJob.containerSecurityContext }} {{- with .Values.makePolicyJob.containerSecurityContext | default .Values.postJob.containerSecurityContext }}
securityContext: {{ toYaml . | nindent 12 }} securityContext: {{ toYaml . | nindent 12 }}
{{- end }} {{- end }}
{{- end }} {{- end }}
@@ -122,9 +128,9 @@ spec:
containers: containers:
{{- if .Values.buckets }} {{- if .Values.buckets }}
- name: silo-make-bucket - name: silo-make-bucket
image: "{{ .Values.mcImage.repository }}:{{ .Values.mcImage.tag }}" image: "{{ tpl .Values.mcImage.repository . }}:{{ tpl .Values.mcImage.tag . }}"
{{- if .Values.makeBucketJob.securityContext.enabled }} {{- if .Values.makeBucketJob.securityContext.enabled }}
{{- with .Values.makeBucketJob.containerSecurityContext }} {{- with .Values.makeBucketJob.containerSecurityContext | default .Values.postJob.containerSecurityContext }}
securityContext: {{ toYaml . | nindent 12 }} securityContext: {{ toYaml . | nindent 12 }}
{{- end }} {{- end }}
{{- end }} {{- end }}
@@ -155,9 +161,9 @@ spec:
{{- end }} {{- end }}
{{- if .Values.users }} {{- if .Values.users }}
- name: silo-make-user - name: silo-make-user
image: "{{ .Values.mcImage.repository }}:{{ .Values.mcImage.tag }}" image: "{{ tpl .Values.mcImage.repository . }}:{{ tpl .Values.mcImage.tag . }}"
{{- if .Values.makeUserJob.securityContext.enabled }} {{- if .Values.makeUserJob.securityContext.enabled }}
{{- with .Values.makeUserJob.containerSecurityContext }} {{- with .Values.makeUserJob.containerSecurityContext | default .Values.postJob.containerSecurityContext }}
securityContext: {{ toYaml . | nindent 12 }} securityContext: {{ toYaml . | nindent 12 }}
{{- end }} {{- end }}
{{- end }} {{- end }}
@@ -188,9 +194,9 @@ spec:
{{- end }} {{- end }}
{{- if .Values.customCommands }} {{- if .Values.customCommands }}
- name: silo-custom-command - name: silo-custom-command
image: "{{ .Values.mcImage.repository }}:{{ .Values.mcImage.tag }}" image: "{{ tpl .Values.mcImage.repository . }}:{{ tpl .Values.mcImage.tag . }}"
{{- if .Values.customCommandJob.securityContext.enabled }} {{- if .Values.customCommandJob.securityContext.enabled }}
{{- with .Values.customCommandJob.containerSecurityContext }} {{- with .Values.customCommandJob.containerSecurityContext | default .Values.postJob.containerSecurityContext }}
securityContext: {{ toYaml . | nindent 12 }} securityContext: {{ toYaml . | nindent 12 }}
{{- end }} {{- end }}
{{- end }} {{- end }}
@@ -224,9 +230,9 @@ spec:
{{- end }} {{- end }}
{{- if .Values.svcaccts }} {{- if .Values.svcaccts }}
- name: silo-make-svcacct - name: silo-make-svcacct
image: "{{ .Values.mcImage.repository }}:{{ .Values.mcImage.tag }}" image: "{{ tpl .Values.mcImage.repository . }}:{{ tpl .Values.mcImage.tag . }}"
{{- if .Values.makeServiceAccountJob.securityContext.enabled }} {{- if .Values.makeServiceAccountJob.securityContext.enabled }}
{{- with .Values.makeServiceAccountJob.containerSecurityContext }} {{- with .Values.makeServiceAccountJob.containerSecurityContext | default .Values.postJob.containerSecurityContext }}
securityContext: {{ toYaml . | nindent 12 }} securityContext: {{ toYaml . | nindent 12 }}
{{- end }} {{- end }}
{{- end }} {{- end }}
+8 -4
View File
@@ -9,8 +9,12 @@ metadata:
chart: {{ template "silo.chart" . }} chart: {{ template "silo.chart" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- if .Values.persistence.annotations }} {{- with .Values.commonLabels }}
annotations: {{- toYaml .Values.persistence.annotations | nindent 4 }} {{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
{{- with .Values.persistence.annotations }}
annotations:
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }} {{- end }}
spec: spec:
accessModes: accessModes:
@@ -18,11 +22,11 @@ spec:
resources: resources:
requests: requests:
storage: {{ .Values.persistence.size | quote }} storage: {{ .Values.persistence.size | quote }}
{{- if .Values.persistence.storageClass }} {{- if or .Values.persistence.storageClass .Values.global.storageClass }}
{{- if (eq "-" .Values.persistence.storageClass) }} {{- if (eq "-" .Values.persistence.storageClass) }}
storageClassName: "" storageClassName: ""
{{- else }} {{- else }}
storageClassName: "{{ .Values.persistence.storageClass }}" storageClassName: "{{ .Values.persistence.storageClass | default .Values.global.storageClass }}"
{{- end }} {{- end }}
{{- end }} {{- end }}
{{- if .Values.persistence.volumeName }} {{- if .Values.persistence.volumeName }}
+3
View File
@@ -8,6 +8,9 @@ metadata:
chart: {{ template "silo.chart" . }} chart: {{ template "silo.chart" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
type: Opaque type: Opaque
data: data:
rootUser: {{ include "silo.root.username" . | b64enc | quote }} rootUser: {{ include "silo.root.username" . | b64enc | quote }}
@@ -8,6 +8,9 @@ metadata:
chart: {{ template "silo.chart" . }} chart: {{ template "silo.chart" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
allowHostDirVolumePlugin: false allowHostDirVolumePlugin: false
allowHostIPC: false allowHostIPC: false
allowHostNetwork: false allowHostNetwork: false
+6 -2
View File
@@ -9,8 +9,12 @@ metadata:
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
monitoring: "true" monitoring: "true"
{{- if .Values.service.annotations }} {{- with .Values.commonLabels }}
annotations: {{- toYaml .Values.service.annotations | nindent 4 }} {{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
{{- with .Values.service.annotations }}
annotations:
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }} {{- end }}
spec: spec:
type: {{ .Values.service.type }} type: {{ .Values.service.type }}
+4
View File
@@ -3,4 +3,8 @@ apiVersion: v1
kind: ServiceAccount kind: ServiceAccount
metadata: metadata:
name: {{ .Values.serviceAccount.name | quote }} name: {{ .Values.serviceAccount.name | quote }}
{{- with .Values.commonLabels }}
labels:
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
{{- end }} {{- end }}
+19 -8
View File
@@ -11,8 +11,11 @@ metadata:
chart: {{ template "silo.chart" . }} chart: {{ template "silo.chart" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- if .Values.metrics.serviceMonitor.additionalLabels }} {{- with .Values.metrics.serviceMonitor.additionalLabels }}
{{- toYaml .Values.metrics.serviceMonitor.additionalLabels | nindent 4 }} {{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
{{- with .Values.commonLabels }}
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }} {{- end }}
{{- if .Values.metrics.serviceMonitor.annotations }} {{- if .Values.metrics.serviceMonitor.annotations }}
annotations: {{- toYaml .Values.metrics.serviceMonitor.annotations | nindent 4 }} annotations: {{- toYaml .Values.metrics.serviceMonitor.annotations | nindent 4 }}
@@ -39,8 +42,8 @@ spec:
{{- if .Values.metrics.serviceMonitor.scrapeTimeout }} {{- if .Values.metrics.serviceMonitor.scrapeTimeout }}
scrapeTimeout: {{ .Values.metrics.serviceMonitor.scrapeTimeout }} scrapeTimeout: {{ .Values.metrics.serviceMonitor.scrapeTimeout }}
{{- end }} {{- end }}
{{- if .Values.metrics.serviceMonitor.relabelConfigs }} {{- with .Values.metrics.serviceMonitor.relabelConfigs }}
{{- toYaml .Values.metrics.serviceMonitor.relabelConfigs | nindent 6 }} {{- tpl (toYaml .) $ | nindent 6 }}
{{- end }} {{- end }}
{{- if not .Values.metrics.serviceMonitor.public }} {{- if not .Values.metrics.serviceMonitor.public }}
bearerTokenSecret: bearerTokenSecret:
@@ -55,6 +58,10 @@ spec:
app: {{ include "silo.name" . }} app: {{ include "silo.name" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
monitoring: "true" monitoring: "true"
{{- with .Values.metrics.serviceMonitor.targetLabels }}
targetLabels:
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
{{- end }} {{- end }}
{{- if .Values.metrics.serviceMonitor.enabled }} {{- if .Values.metrics.serviceMonitor.enabled }}
--- ---
@@ -70,8 +77,8 @@ metadata:
chart: {{ template "silo.chart" . }} chart: {{ template "silo.chart" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- if .Values.metrics.serviceMonitor.additionalLabels }} {{- with .Values.metrics.serviceMonitor.additionalLabels }}
{{- toYaml .Values.metrics.serviceMonitor.additionalLabels | nindent 4 }} {{- tpl (toYaml .) $ | nindent 4 }}
{{- end }} {{- end }}
spec: spec:
jobName: {{ template "silo.fullname" . }} jobName: {{ template "silo.fullname" . }}
@@ -91,13 +98,17 @@ spec:
{{- else }} {{- else }}
scheme: http scheme: http
{{- end }} {{- end }}
{{- if .Values.metrics.serviceMonitor.relabelConfigsCluster }} {{- with .Values.metrics.serviceMonitor.relabelConfigsCluster }}
{{- toYaml .Values.metrics.serviceMonitor.relabelConfigsCluster | nindent 2 }} {{- tpl (toYaml .) $ | nindent 2 }}
{{- end }} {{- end }}
targets: targets:
staticConfig: staticConfig:
static: static:
- {{ template "silo.fullname" . }}.{{ .Release.Namespace }} - {{ template "silo.fullname" . }}.{{ .Release.Namespace }}
{{- with .Values.metrics.serviceMonitor.probeRelabelingConfigs }}
relabelingConfigs:
{{- tpl (toYaml .) $ | nindent 8 }}
{{- end }}
{{- if not .Values.metrics.serviceMonitor.public }} {{- if not .Values.metrics.serviceMonitor.public }}
{{- if .Values.metrics.serviceMonitor.interval }} {{- if .Values.metrics.serviceMonitor.interval }}
interval: {{ .Values.metrics.serviceMonitor.interval }} interval: {{ .Values.metrics.serviceMonitor.interval }}
+17 -7
View File
@@ -20,6 +20,9 @@ metadata:
chart: {{ template "silo.chart" . }} chart: {{ template "silo.chart" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- with .Values.commonLabels }}
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
spec: spec:
publishNotReadyAddresses: true publishNotReadyAddresses: true
clusterIP: None clusterIP: None
@@ -41,11 +44,15 @@ metadata:
chart: {{ template "silo.chart" . }} chart: {{ template "silo.chart" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
heritage: {{ .Release.Service }} heritage: {{ .Release.Service }}
{{- if .Values.additionalLabels }} {{- with .Values.additionalLabels }}
{{- toYaml .Values.additionalLabels | nindent 4 }} {{- tpl (toYaml .) $ | nindent 4 }}
{{- end }} {{- end }}
{{- if .Values.additionalAnnotations }} {{- with .Values.commonLabels }}
annotations: {{- toYaml .Values.additionalAnnotations | nindent 4 }} {{- tpl (toYaml .) $ | nindent 4 }}
{{- end }}
{{- with .Values.additionalAnnotations }}
annotations:
{{- tpl (toYaml .) $ | nindent 4 }}
{{- end }} {{- end }}
spec: spec:
updateStrategy: updateStrategy:
@@ -63,8 +70,11 @@ spec:
labels: labels:
app: {{ template "silo.name" . }} app: {{ template "silo.name" . }}
release: {{ .Release.Name }} release: {{ .Release.Name }}
{{- if .Values.podLabels }} {{- with .Values.podLabels }}
{{- toYaml .Values.podLabels | nindent 8 }} {{- tpl (toYaml .) $ | nindent 8 }}
{{- end }}
{{- with .Values.commonLabels }}
{{- tpl (toYaml .) $ | nindent 8 }}
{{- end }} {{- end }}
annotations: annotations:
{{- if not .Values.ignoreChartChecksums }} {{- if not .Values.ignoreChartChecksums }}
@@ -90,7 +100,7 @@ spec:
{{- end }} {{- end }}
containers: containers:
- name: {{ include "silo.name" . }} - name: {{ include "silo.name" . }}
image: {{ .Values.image.repository }}:{{ .Values.image.tag }} image: {{ tpl .Values.image.repository . }}:{{ tpl .Values.image.tag . }}
imagePullPolicy: {{ .Values.image.pullPolicy }} imagePullPolicy: {{ .Values.image.pullPolicy }}
command: [ command: [
"/bin/sh", "/bin/sh",
+25
View File
@@ -37,6 +37,9 @@ additionalLabels: {}
## Additional annotations to include with deployment or statefulset ## Additional annotations to include with deployment or statefulset
additionalAnnotations: {} additionalAnnotations: {}
## Common labels applied to all resources
commonLabels: {}
## Typically the deployment/statefulset includes checksums of secrets/config, ## Typically the deployment/statefulset includes checksums of secrets/config,
## So that when these change on a subsequent helm install, the deployment/statefulset ## So that when these change on a subsequent helm install, the deployment/statefulset
## is restarted. This can result in unnecessary restarts under GitOps tooling such as ## is restarted. This can result in unnecessary restarts under GitOps tooling such as
@@ -358,6 +361,7 @@ makePolicyJob:
enabled: false enabled: false
runAsUser: 1000 runAsUser: 1000
runAsGroup: 1000 runAsGroup: 1000
containerSecurityContext: {}
resources: resources:
requests: requests:
memory: 128Mi memory: 128Mi
@@ -388,6 +392,7 @@ makeUserJob:
enabled: false enabled: false
runAsUser: 1000 runAsUser: 1000
runAsGroup: 1000 runAsGroup: 1000
containerSecurityContext: {}
resources: resources:
requests: requests:
memory: 128Mi memory: 128Mi
@@ -428,6 +433,7 @@ makeServiceAccountJob:
enabled: false enabled: false
runAsUser: 1000 runAsUser: 1000
runAsGroup: 1000 runAsGroup: 1000
containerSecurityContext: {}
resources: resources:
requests: requests:
memory: 128Mi memory: 128Mi
@@ -465,6 +471,7 @@ makeBucketJob:
enabled: false enabled: false
runAsUser: 1000 runAsUser: 1000
runAsGroup: 1000 runAsGroup: 1000
containerSecurityContext: {}
resources: resources:
requests: requests:
memory: 128Mi memory: 128Mi
@@ -483,6 +490,7 @@ customCommandJob:
enabled: false enabled: false
runAsUser: 1000 runAsUser: 1000
runAsGroup: 1000 runAsGroup: 1000
containerSecurityContext: {}
resources: resources:
requests: requests:
memory: 128Mi memory: 128Mi
@@ -510,6 +518,7 @@ postJob:
runAsUser: 1000 runAsUser: 1000
runAsGroup: 1000 runAsGroup: 1000
fsGroup: 1000 fsGroup: 1000
containerSecurityContext: {}
nodeSelector: {} nodeSelector: {}
tolerations: [] tolerations: []
affinity: {} affinity: {}
@@ -532,6 +541,9 @@ extraSecret: ~
oidc: oidc:
enabled: false enabled: false
configUrl: "https://identity-provider-url/.well-known/openid-configuration" configUrl: "https://identity-provider-url/.well-known/openid-configuration"
# Provide existing ConfigMap for the Config URL
existingConfigMapName: ""
existingConfigUrlKey: ""
clientId: "silo" clientId: "silo"
clientSecret: "" clientSecret: ""
# Provide existing client secret from the Kubernetes Secret resource, existing secret will have priority over `clientId` and/or `clientSecret`` # Provide existing client secret from the Kubernetes Secret resource, existing secret will have priority over `clientId` and/or `clientSecret``
@@ -540,7 +552,10 @@ oidc:
existingClientSecretKey: "" existingClientSecretKey: ""
claimName: "policy" claimName: "policy"
scopes: "openid,profile,email" scopes: "openid,profile,email"
# Deprecated: Use redirectUrl and set this to `false` or an empty string
redirectUri: "https://console-endpoint-url/oauth_callback" redirectUri: "https://console-endpoint-url/oauth_callback"
# Use in favor of `redirectUri` to set `MINIO_BROWSER_REDIRECT_URL`
redirectUrl: "https://console-endpoint-url"
# Can leave empty # Can leave empty
claimPrefix: "" claimPrefix: ""
comment: "" comment: ""
@@ -553,6 +568,12 @@ networkPolicy:
flavor: kubernetes flavor: kubernetes
# Allow external access to the Silo API. # Allow external access to the Silo API.
allowExternal: true allowExternal: true
# Additional from values to add to the Ingress
allowFrom: []
## E.X.
# - namespaceSelector:
# matchLabels:
# kubernetes.io/metadata.name: prometheus
## @params networkPolicy.egress configuration of the egress traffic ## @params networkPolicy.egress configuration of the egress traffic
egress: egress:
## @param networkPolicy.egress.enabled When enabled, an egress network policy will be ## @param networkPolicy.egress.enabled When enabled, an egress network policy will be
@@ -604,6 +625,8 @@ metrics:
public: true public: true
additionalLabels: {} additionalLabels: {}
annotations: {} annotations: {}
# targetLabels for the ServiceMonitor
targetLabels: []
# for node metrics # for node metrics
relabelConfigs: {} relabelConfigs: {}
# for cluster metrics # for cluster metrics
@@ -612,6 +635,8 @@ metrics:
# metricRelabelings: # metricRelabelings:
# - regex: (server|pod) # - regex: (server|pod)
# action: labeldrop # action: labeldrop
# Probe relabelingConfigs added to the probe target
probeRelabelingConfigs: []
namespace: ~ namespace: ~
# Scrape interval, for example `interval: 30s` # Scrape interval, for example `interval: 30s`
interval: ~ interval: ~