Files
rustfs/helm/rustfs/templates/service.yaml
T
majinghe 44f3f3d070 add standalone mode support (#881)
* add standalone mode support

* update readme file

* change non-root from 1000 to 10001

* delete self sign crt content

* modify security content

* fix synatx error for readme file.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* update image repository and tag info.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* fix helm chart syntax issue.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* fix helm chart syntax issue.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: houseme <housemecn@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: loverustfs <hello@rustfs.com>
2025-11-19 13:56:21 +08:00

64 lines
1.5 KiB
YAML

{{- if .Values.mode.distributed.enabled }}
apiVersion: v1
kind: Service
metadata:
name: {{ include "rustfs.fullname" . }}-headless
labels:
{{- include "rustfs.labels" . | nindent 4 }}
spec:
clusterIP: None
publishNotReadyAddresses: true
ports:
{{- if .Values.ingress.enabled }}
- port: 9000
{{- else }}
- port: {{ .Values.service.ep_port }}
{{- end }}
targetPort: {{ .Values.service.ep_port }}
protocol: TCP
name: endpoint
- port: {{ .Values.service.console_port }}
targetPort: 9001
protocol: TCP
name: console
selector:
app: {{ include "rustfs.name" . }}
{{- end }}
---
apiVersion: v1
kind: Service
metadata:
name: {{ include "rustfs.fullname" . }}-svc
{{- if .Values.mode.distributed.enabled }}
{{- if eq .Values.ingress.className "traefik" }}
{{- with .Values.ingress.traefikAnnotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- end }}
{{- end }}
labels:
{{- include "rustfs.labels" . | nindent 4 }}
spec:
{{- if .Values.ingress.enabled }}
type: ClusterIP
{{- else }}
type: NodePort
sessionAffinity: ClientIP
sessionAffinityConfig:
clientIP:
timeoutSeconds: 10800
{{- end }}
ports:
- port: {{ .Values.service.ep_port }}
targetPort: {{ .Values.service.ep_port }}
protocol: TCP
name: endpoint
- port: {{ .Values.service.console_port }}
targetPort: {{ .Values.service.console_port }}
protocol: TCP
name: console
selector:
app: {{ include "rustfs.name" . }}