SeaweedFS is a distributed storage system for object storage (S3), file systems, Iceberg table buckets, and Lance vector buckets, designed to handle billions of files with O(1) disk access and effortless horizontal scaling.
Go blob-storagecloud-drivedistributed-file-systemdistributed-storageerasure-codingfusehadoop-hdfshdfskuberneteslancelancedbobject-storageposixs3s3-storageseaweedfstiered-file-systemvector-search
[heml] complete redesign of labels (#4788)
Dmitriy Pavlov56aef679128c
diff --git a/k8s/charts/seaweedfs/templates/ca-cert.yaml b/k8s/charts/seaweedfs/templates/ca-cert.yamlindex 9b74db0b13..c1d432d312 100644--- a/k8s/charts/seaweedfs/templates/ca-cert.yaml+++ b/k8s/charts/seaweedfs/templates/ca-cert.yaml@@ -4,6 +4,11 @@ kind: Certificatemetadata:name: {{ template "seaweedfs.name" . }}-ca-certnamespace: {{ .Release.Namespace }}+ labels:+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}spec:secretName: {{ template "seaweedfs.name" . }}-ca-certcommonName: "{{ template "seaweedfs.name" . }}-root-ca"diff --git a/k8s/charts/seaweedfs/templates/cert-caissuer.yaml b/k8s/charts/seaweedfs/templates/cert-caissuer.yamlindex 864652393a..4c26930438 100644--- a/k8s/charts/seaweedfs/templates/cert-caissuer.yaml+++ b/k8s/charts/seaweedfs/templates/cert-caissuer.yaml@@ -4,6 +4,11 @@ kind: Issuermetadata:name: {{ template "seaweedfs.name" . }}-ca-issuernamespace: {{ .Release.Namespace }}+ labels:+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}spec:ca:secretName: {{ template "seaweedfs.name" . }}-ca-certdiff --git a/k8s/charts/seaweedfs/templates/cert-clusterissuer.yaml b/k8s/charts/seaweedfs/templates/cert-clusterissuer.yamlindex 2604927dbb..c46aa47565 100644--- a/k8s/charts/seaweedfs/templates/cert-clusterissuer.yaml+++ b/k8s/charts/seaweedfs/templates/cert-clusterissuer.yaml@@ -3,6 +3,11 @@ apiVersion: cert-manager.io/v1{{ if .Values.global.certificates.alphacrds }}alphkind: ClusterIssuermetadata:name: {{ template "seaweedfs.name" . }}-clusterissuer+ labels:+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}spec:selfSigned: {}{{- end }}diff --git a/k8s/charts/seaweedfs/templates/client-cert.yaml b/k8s/charts/seaweedfs/templates/client-cert.yamlindex 7960c3f8d6..5904a00b6d 100644--- a/k8s/charts/seaweedfs/templates/client-cert.yaml+++ b/k8s/charts/seaweedfs/templates/client-cert.yaml@@ -4,6 +4,11 @@ kind: Certificatemetadata:name: {{ template "seaweedfs.name" . }}-client-certnamespace: {{ .Release.Namespace }}+ labels:+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}spec:secretName: {{ template "seaweedfs.name" . }}-client-certissuerRef:diff --git a/k8s/charts/seaweedfs/templates/filer-cert.yaml b/k8s/charts/seaweedfs/templates/filer-cert.yamlindex 3c3565d33b..8b5dbe257b 100644--- a/k8s/charts/seaweedfs/templates/filer-cert.yaml+++ b/k8s/charts/seaweedfs/templates/filer-cert.yaml@@ -4,6 +4,12 @@ kind: Certificatemetadata:name: {{ template "seaweedfs.name" . }}-filer-certnamespace: {{ .Release.Namespace }}+ labels:+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: filerspec:secretName: {{ template "seaweedfs.name" . }}-filer-certissuerRef:diff --git a/k8s/charts/seaweedfs/templates/filer-service-client.yaml b/k8s/charts/seaweedfs/templates/filer-service-client.yamlindex 929b6f8bc9..41251c8976 100644--- a/k8s/charts/seaweedfs/templates/filer-service-client.yaml+++ b/k8s/charts/seaweedfs/templates/filer-service-client.yaml@@ -4,8 +4,11 @@ metadata:name: {{ template "seaweedfs.name" . }}-filer-clientnamespace: {{ .Release.Namespace }}labels:- app: {{ template "seaweedfs.name" . }}- component: filer+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: filer{{- if .Values.filer.metricsPort }}monitoring: "true"{{- end }}@@ -27,5 +30,5 @@ spec:protocol: TCP{{- end }}selector:- app: {{ template "seaweedfs.name" . }}- component: filer+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ app.kubernetes.io/component: filerdiff --git a/k8s/charts/seaweedfs/templates/filer-service.yaml b/k8s/charts/seaweedfs/templates/filer-service.yamlindex ac44fa42b0..352a20676a 100644--- a/k8s/charts/seaweedfs/templates/filer-service.yaml+++ b/k8s/charts/seaweedfs/templates/filer-service.yaml@@ -6,8 +6,11 @@ metadata:name: {{ template "seaweedfs.name" . }}-filernamespace: {{ .Release.Namespace }}labels:- app: {{ template "seaweedfs.name" . }}- component: filer+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: filerspec:clusterIP: NonepublishNotReadyAddresses: true@@ -39,5 +42,5 @@ spec:protocol: TCP{{- end }}selector:- app: {{ template "seaweedfs.name" . }}- component: filer+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ app.kubernetes.io/component: filerdiff --git a/k8s/charts/seaweedfs/templates/filer-servicemonitor.yaml b/k8s/charts/seaweedfs/templates/filer-servicemonitor.yamlindex 4a891463cf..8035d7ffbd 100644--- a/k8s/charts/seaweedfs/templates/filer-servicemonitor.yaml+++ b/k8s/charts/seaweedfs/templates/filer-servicemonitor.yaml@@ -6,8 +6,11 @@ metadata:name: {{ template "seaweedfs.name" . }}-filernamespace: {{ .Release.Namespace }}labels:- app: {{ template "seaweedfs.name" . }}- component: filer+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: filerspec:endpoints:- interval: 30s@@ -15,7 +18,7 @@ spec:scrapeTimeout: 5sselector:matchLabels:- app: {{ template "seaweedfs.name" . }}- component: filer+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ app.kubernetes.io/component: filer{{- end }}{{- end }}\ No newline at end of filediff --git a/k8s/charts/seaweedfs/templates/filer-statefulset.yaml b/k8s/charts/seaweedfs/templates/filer-statefulset.yamlindex 7a2810a714..522a7dcfad 100644--- a/k8s/charts/seaweedfs/templates/filer-statefulset.yaml+++ b/k8s/charts/seaweedfs/templates/filer-statefulset.yaml@@ -5,10 +5,11 @@ metadata:name: {{ template "seaweedfs.name" . }}-filernamespace: {{ .Release.Namespace }}labels:- app: {{ template "seaweedfs.name" . }}- chart: {{ template "seaweedfs.chart" . }}- heritage: {{ .Release.Service }}- release: {{ .Release.Name }}+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: filerspec:serviceName: {{ template "seaweedfs.name" . }}-filerpodManagementPolicy: Parallel@@ -21,17 +22,17 @@ spec:{{- end }}selector:matchLabels:- app: {{ template "seaweedfs.name" . }}- chart: {{ template "seaweedfs.chart" . }}- release: {{ .Release.Name }}- component: filer+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: filertemplate:metadata:labels:- app: {{ template "seaweedfs.name" . }}- chart: {{ template "seaweedfs.chart" . }}- release: {{ .Release.Name }}- component: filer+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: filerspec:restartPolicy: {{ default .Values.global.restartPolicy .Values.filer.restartPolicy }}{{- if .Values.filer.affinity }}@@ -180,8 +181,10 @@ spec:{{- end }}-master={{ range $index := until (.Values.master.replicas | int) }}${SEAWEEDFS_FULLNAME}-master-{{ $index }}.${SEAWEEDFS_FULLNAME}-master.{{ $.Release.Namespace }}:{{ $.Values.master.port }}{{ if lt $index (sub ($.Values.master.replicas | int) 1) }},{{ end }}{{ end }}volumeMounts:+ {{- if eq .Values.filer.logs.type "hostPath" }}- name: seaweedfs-filer-log-volumemountPath: "/logs/"+ {{- end }}- mountPath: /etc/swname: config-usersreadOnly: truediff --git a/k8s/charts/seaweedfs/templates/ingress.yaml b/k8s/charts/seaweedfs/templates/filler-ingress.yamlsimilarity index 50%rename from k8s/charts/seaweedfs/templates/ingress.yamlrename to k8s/charts/seaweedfs/templates/filler-ingress.yamlindex 183cf1a23d..b16fd74037 100644--- a/k8s/charts/seaweedfs/templates/ingress.yaml+++ b/k8s/charts/seaweedfs/templates/filler-ingress.yaml@@ -12,6 +12,12 @@ metadata:namespace: {{ .Release.Namespace }}annotations:{{ omit .Values.filer.ingress.annotations "kubernetes.io/ingress.class" | toYaml | nindent 4 }}+ labels:+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: filerspec:ingressClassName: {{ .Values.filer.ingress.className | quote }}tls:@@ -35,41 +41,4 @@ spec:{{- if .Values.filer.ingress.host }}host: {{ .Values.filer.ingress.host }}{{- end }}-{{- end }}-----{{- if .Values.master.ingress.enabled }}-{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion }}-apiVersion: networking.k8s.io/v1-{{- else if semverCompare ">=1.14-0" .Capabilities.KubeVersion.GitVersion }}-apiVersion: networking.k8s.io/v1beta1-{{- else }}-apiVersion: extensions/v1beta1-{{- end }}-kind: Ingress-metadata:- name: ingress-{{ template "seaweedfs.name" . }}-master- namespace: {{ .Release.Namespace }}- annotations:- {{ omit .Values.master.ingress.annotations "kubernetes.io/ingress.class" | toYaml | nindent 4 }}-spec:- ingressClassName: {{ .Values.master.ingress.className | quote }}- rules:- - http:- paths:- - path: /sw-master/?(.*)- pathType: ImplementationSpecific- backend:-{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion }}- service:- name: {{ template "seaweedfs.name" . }}-master- port:- number: {{ .Values.master.port }}- #name:-{{- else }}- serviceName: {{ template "seaweedfs.name" . }}-master- servicePort: {{ .Values.master.port }}-{{- end }}-{{- if .Values.filer.ingress.host }}- host: {{ .Values.master.ingress.host }}-{{- end }}-{{- end }}+{{- end }}\ No newline at end of filediff --git a/k8s/charts/seaweedfs/templates/master-cert.yaml b/k8s/charts/seaweedfs/templates/master-cert.yamlindex 1377ccda49..bb935eedb6 100644--- a/k8s/charts/seaweedfs/templates/master-cert.yaml+++ b/k8s/charts/seaweedfs/templates/master-cert.yaml@@ -4,6 +4,12 @@ kind: Certificatemetadata:name: {{ template "seaweedfs.name" . }}-master-certnamespace: {{ .Release.Namespace }}+ labels:+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: masterspec:secretName: {{ template "seaweedfs.name" . }}-master-certissuerRef:diff --git a/k8s/charts/seaweedfs/templates/master-ingress.yaml b/k8s/charts/seaweedfs/templates/master-ingress.yamlnew file mode 100644index 0000000000..4522f0a067--- /dev/null+++ b/k8s/charts/seaweedfs/templates/master-ingress.yaml@@ -0,0 +1,42 @@+{{- if .Values.master.ingress.enabled }}+{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion }}+apiVersion: networking.k8s.io/v1+{{- else if semverCompare ">=1.14-0" .Capabilities.KubeVersion.GitVersion }}+apiVersion: networking.k8s.io/v1beta1+{{- else }}+apiVersion: extensions/v1beta1+{{- end }}+kind: Ingress+metadata:+ name: ingress-{{ template "seaweedfs.name" . }}-master+ namespace: {{ .Release.Namespace }}+ annotations:+ {{ omit .Values.master.ingress.annotations "kubernetes.io/ingress.class" | toYaml | nindent 4 }}+ labels:+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: master+spec:+ ingressClassName: {{ .Values.master.ingress.className | quote }}+ rules:+ - http:+ paths:+ - path: /sw-master/?(.*)+ pathType: ImplementationSpecific+ backend:+{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion }}+ service:+ name: {{ template "seaweedfs.name" . }}-master+ port:+ number: {{ .Values.master.port }}+ #name:+{{- else }}+ serviceName: {{ template "seaweedfs.name" . }}-master+ servicePort: {{ .Values.master.port }}+{{- end }}+{{- if .Values.filer.ingress.host }}+ host: {{ .Values.master.ingress.host }}+{{- end }}+{{- end }}diff --git a/k8s/charts/seaweedfs/templates/master-service.yaml b/k8s/charts/seaweedfs/templates/master-service.yamlindex 77710220bf..978f9c8815 100644--- a/k8s/charts/seaweedfs/templates/master-service.yaml+++ b/k8s/charts/seaweedfs/templates/master-service.yaml@@ -4,8 +4,10 @@ metadata:name: {{ template "seaweedfs.name" . }}-masternamespace: {{ .Release.Namespace }}labels:- app: {{ template "seaweedfs.name" . }}- component: master+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ app.kubernetes.io/component: master+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}annotations:service.alpha.kubernetes.io/tolerate-unready-endpoints: "true"spec:@@ -27,5 +29,5 @@ spec:protocol: TCP{{- end }}selector:- app: {{ template "seaweedfs.name" . }}- component: master+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ app.kubernetes.io/component: masterdiff --git a/k8s/charts/seaweedfs/templates/master-servicemonitor.yaml b/k8s/charts/seaweedfs/templates/master-servicemonitor.yamlindex 64ee180350..0332f756d6 100644--- a/k8s/charts/seaweedfs/templates/master-servicemonitor.yaml+++ b/k8s/charts/seaweedfs/templates/master-servicemonitor.yaml@@ -6,8 +6,11 @@ metadata:name: {{ template "seaweedfs.name" . }}-masternamespace: {{ .Release.Namespace }}labels:- app: {{ template "seaweedfs.name" . }}- component: master+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: masterspec:endpoints:- interval: 30sdiff --git a/k8s/charts/seaweedfs/templates/master-statefulset.yaml b/k8s/charts/seaweedfs/templates/master-statefulset.yamlindex e1b272ab40..2b4a8b5c9a 100644--- a/k8s/charts/seaweedfs/templates/master-statefulset.yaml+++ b/k8s/charts/seaweedfs/templates/master-statefulset.yaml@@ -5,10 +5,10 @@ metadata:name: {{ template "seaweedfs.name" . }}-masternamespace: {{ .Release.Namespace }}labels:- app: {{ template "seaweedfs.name" . }}- chart: {{ template "seaweedfs.chart" . }}- heritage: {{ .Release.Service }}- release: {{ .Release.Name }}+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}spec:serviceName: {{ template "seaweedfs.name" . }}-masterpodManagementPolicy: Parallel@@ -21,17 +21,17 @@ spec:{{- end }}selector:matchLabels:- app: {{ template "seaweedfs.name" . }}- chart: {{ template "seaweedfs.chart" . }}- release: {{ .Release.Name }}- component: master+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: mastertemplate:metadata:labels:- app: {{ template "seaweedfs.name" . }}- chart: {{ template "seaweedfs.chart" . }}- release: {{ .Release.Name }}- component: master+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: masterspec:restartPolicy: {{ default .Values.global.restartPolicy .Values.master.restartPolicy }}{{- if .Values.master.affinity }}@@ -135,8 +135,10 @@ spec:volumeMounts:- name : data-{{ .Release.Namespace }}mountPath: /data+ {{- if eq .Values.master.logs.type "hostPath" }}- name: seaweedfs-master-log-volumemountPath: "/logs/"+ {{- end }}{{- if .Values.global.enableSecurity }}- name: security-configreadOnly: truediff --git a/k8s/charts/seaweedfs/templates/s3-deployment.yaml b/k8s/charts/seaweedfs/templates/s3-deployment.yamlindex 2040e71612..a996b6ef6b 100644--- a/k8s/charts/seaweedfs/templates/s3-deployment.yaml+++ b/k8s/charts/seaweedfs/templates/s3-deployment.yaml@@ -5,25 +5,25 @@ metadata:name: {{ template "seaweedfs.name" . }}-s3namespace: {{ .Release.Namespace }}labels:- app: {{ template "seaweedfs.name" . }}- chart: {{ template "seaweedfs.chart" . }}- heritage: {{ .Release.Service }}- release: {{ .Release.Name }}+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}spec:replicas: {{ .Values.s3.replicas }}selector:matchLabels:- app: {{ template "seaweedfs.name" . }}- chart: {{ template "seaweedfs.chart" . }}- release: {{ .Release.Name }}- component: s3+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: s3template:metadata:labels:- app: {{ template "seaweedfs.name" . }}- chart: {{ template "seaweedfs.chart" . }}- release: {{ .Release.Name }}- component: s3+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: s3spec:restartPolicy: {{ default .Values.global.restartPolicy .Values.s3.restartPolicy }}{{- if .Values.s3.tolerations }}diff --git a/k8s/charts/seaweedfs/templates/s3-service.yaml b/k8s/charts/seaweedfs/templates/s3-service.yamlindex 133ce33724..32fef5d812 100644--- a/k8s/charts/seaweedfs/templates/s3-service.yaml+++ b/k8s/charts/seaweedfs/templates/s3-service.yaml@@ -4,8 +4,10 @@ metadata:name: {{ template "seaweedfs.name" . }}-s3namespace: {{ .Release.Namespace }}labels:- app: {{ template "seaweedfs.name" . }}- component: s3+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ app.kubernetes.io/component: s3+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}spec:ports:- name: "swfs-s3"@@ -25,5 +27,5 @@ spec:protocol: TCP{{- end }}selector:- app: {{ template "seaweedfs.name" . }}- component: {{ if .Values.s3.enabled }}s3{{ else }}filer{{ end }}+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ app.kubernetes.io/component: {{ if .Values.s3.enabled }}s3{{ else }}filer{{ end }}diff --git a/k8s/charts/seaweedfs/templates/s3-servicemonitor.yaml b/k8s/charts/seaweedfs/templates/s3-servicemonitor.yamlindex 5df5370867..876f72dcdc 100644--- a/k8s/charts/seaweedfs/templates/s3-servicemonitor.yaml+++ b/k8s/charts/seaweedfs/templates/s3-servicemonitor.yaml@@ -6,8 +6,11 @@ metadata:name: {{ template "seaweedfs.name" . }}-s3namespace: {{ .Release.Namespace }}labels:- app: {{ template "seaweedfs.name" . }}- component: s3+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: s3spec:endpoints:- interval: 30sdiff --git a/k8s/charts/seaweedfs/templates/seaweedfs-s3-secret.yaml b/k8s/charts/seaweedfs/templates/seaweedfs-s3-secret.yamlindex 4e9189633e..0f36743800 100644--- a/k8s/charts/seaweedfs/templates/seaweedfs-s3-secret.yaml+++ b/k8s/charts/seaweedfs/templates/seaweedfs-s3-secret.yaml@@ -12,6 +12,12 @@ metadata:annotations:"helm.sh/resource-policy": keep"helm.sh/hook": "pre-install"+ labels:+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: s3stringData:admin_access_key_id: {{ $access_key_admin }}admin_secret_access_key: {{ $secret_key_admin }}diff --git a/k8s/charts/seaweedfs/templates/secret-seaweedfs-db.yaml b/k8s/charts/seaweedfs/templates/secret-seaweedfs-db.yamlindex c6132c9ea4..9a1aca91dc 100644--- a/k8s/charts/seaweedfs/templates/secret-seaweedfs-db.yaml+++ b/k8s/charts/seaweedfs/templates/secret-seaweedfs-db.yaml@@ -7,6 +7,11 @@ metadata:annotations:"helm.sh/resource-policy": keep"helm.sh/hook": "pre-install"+ labels:+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}stringData:user: "YourSWUser"password: "HardCodedPassword"diff --git a/k8s/charts/seaweedfs/templates/security-configmap.yaml b/k8s/charts/seaweedfs/templates/security-configmap.yamlindex 7d06614ec3..8f82c25a9b 100644--- a/k8s/charts/seaweedfs/templates/security-configmap.yaml+++ b/k8s/charts/seaweedfs/templates/security-configmap.yaml@@ -5,10 +5,10 @@ metadata:name: {{ template "seaweedfs.name" . }}-security-confignamespace: {{ .Release.Namespace }}labels:- app: {{ template "seaweedfs.name" . }}- chart: {{ template "seaweedfs.chart" . }}- heritage: {{ .Release.Service }}- release: {{ .Release.Name }}+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}data:security.toml: |-# this file is read by master, volume server, and filerdiff --git a/k8s/charts/seaweedfs/templates/service-account.yaml b/k8s/charts/seaweedfs/templates/service-account.yamlindex 89f5311744..a0ca3f0046 100644--- a/k8s/charts/seaweedfs/templates/service-account.yaml+++ b/k8s/charts/seaweedfs/templates/service-account.yaml@@ -5,6 +5,11 @@ kind: ClusterRoleapiVersion: rbac.authorization.k8s.io/v1metadata:name: seaweedfs-rw-cr+ labels:+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}rules:- apiGroups: [""]resources: ["pods"]@@ -15,11 +20,21 @@ kind: ServiceAccountmetadata:name: seaweedfs-rw-sanamespace: {{ .Release.Namespace }}+ labels:+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}---kind: ClusterRoleBindingapiVersion: rbac.authorization.k8s.io/v1metadata:name: system:serviceaccount:seaweedfs-rw-sa:default+ labels:+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}subjects:- kind: ServiceAccountname: seaweedfs-rw-sadiff --git a/k8s/charts/seaweedfs/templates/volume-cert.yaml b/k8s/charts/seaweedfs/templates/volume-cert.yamlindex 4167867b1f..c6b333f7c0 100644--- a/k8s/charts/seaweedfs/templates/volume-cert.yaml+++ b/k8s/charts/seaweedfs/templates/volume-cert.yaml@@ -4,6 +4,12 @@ kind: Certificatemetadata:name: {{ template "seaweedfs.name" . }}-volume-certnamespace: {{ .Release.Namespace }}+ labels:+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: volumespec:secretName: {{ template "seaweedfs.name" . }}-volume-certissuerRef:diff --git a/k8s/charts/seaweedfs/templates/volume-service.yaml b/k8s/charts/seaweedfs/templates/volume-service.yamlindex 1e07865c07..20539c5a1c 100644--- a/k8s/charts/seaweedfs/templates/volume-service.yaml+++ b/k8s/charts/seaweedfs/templates/volume-service.yaml@@ -4,8 +4,10 @@ metadata:name: {{ template "seaweedfs.name" . }}-volumenamespace: {{ .Release.Namespace }}labels:- app: {{ template "seaweedfs.name" . }}- component: volume+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ app.kubernetes.io/component: volume+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}spec:clusterIP: Noneports:@@ -24,5 +26,5 @@ spec:protocol: TCP{{- end }}selector:- app: {{ template "seaweedfs.name" . }}- component: volume\ No newline at end of file+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ app.kubernetes.io/component: volume\ No newline at end of filediff --git a/k8s/charts/seaweedfs/templates/volume-servicemonitor.yaml b/k8s/charts/seaweedfs/templates/volume-servicemonitor.yamlindex 2dcca5ac8d..d2ee8b4c7d 100644--- a/k8s/charts/seaweedfs/templates/volume-servicemonitor.yaml+++ b/k8s/charts/seaweedfs/templates/volume-servicemonitor.yaml@@ -6,8 +6,11 @@ metadata:name: {{ template "seaweedfs.name" . }}-volumenamespace: {{ .Release.Namespace }}labels:- app: {{ template "seaweedfs.name" . }}- component: volume+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: volumespec:endpoints:- interval: 30s@@ -15,7 +18,7 @@ spec:scrapeTimeout: 5sselector:matchLabels:- app: {{ template "seaweedfs.name" . }}- component: volume+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ app.kubernetes.io/component: volume{{- end }}{{- end }}\ No newline at end of filediff --git a/k8s/charts/seaweedfs/templates/volume-statefulset.yaml b/k8s/charts/seaweedfs/templates/volume-statefulset.yamlindex 4abadb24d5..18b342dca2 100644--- a/k8s/charts/seaweedfs/templates/volume-statefulset.yaml+++ b/k8s/charts/seaweedfs/templates/volume-statefulset.yaml@@ -5,27 +5,27 @@ metadata:name: {{ template "seaweedfs.name" . }}-volumenamespace: {{ .Release.Namespace }}labels:- app: {{ template "seaweedfs.name" . }}- chart: {{ template "seaweedfs.chart" . }}- heritage: {{ .Release.Service }}- release: {{ .Release.Name }}+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/managed-by: {{ .Release.Service }}+ app.kubernetes.io/instance: {{ .Release.Name }}spec:serviceName: {{ template "seaweedfs.name" . }}-volumereplicas: {{ .Values.volume.replicas }}podManagementPolicy: Parallelselector:matchLabels:- app: {{ template "seaweedfs.name" . }}- chart: {{ template "seaweedfs.chart" . }}- release: {{ .Release.Name }}- component: volume+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: volumetemplate:metadata:labels:- app: {{ template "seaweedfs.name" . }}- chart: {{ template "seaweedfs.chart" . }}- release: {{ .Release.Name }}- component: volume+ app.kubernetes.io/name: {{ template "seaweedfs.name" . }}+ helm.sh/chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}+ app.kubernetes.io/instance: {{ .Release.Name }}+ app.kubernetes.io/component: volumespec:{{- if .Values.volume.affinity }}affinity:@@ -145,8 +145,10 @@ spec:- name: idxmountPath: "{{ .Values.volume.dir_idx }}/"{{- end }}+ {{- if eq .Values.volume.logs.type "hostPath" }}- name: logsmountPath: "/logs/"+ {{- end }}{{- if .Values.global.enableSecurity }}- name: security-configreadOnly: truediff --git a/k8s/charts/seaweedfs/values.yaml b/k8s/charts/seaweedfs/values.yamlindex 165be23f37..8431047b9b 100644--- a/k8s/charts/seaweedfs/values.yaml+++ b/k8s/charts/seaweedfs/values.yaml@@ -265,7 +265,6 @@ volume:# ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/priorityClassName: ""-filer:enabled: truerepository: null