2020-03-03 15:56:39 +08:00
|
|
|
apiVersion: v1
|
|
|
|
kind: Service
|
|
|
|
metadata:
|
|
|
|
name: {{ template "seaweedfs.name" . }}-s3
|
|
|
|
namespace: {{ .Release.Namespace }}
|
|
|
|
labels:
|
|
|
|
app: {{ template "seaweedfs.name" . }}
|
|
|
|
component: s3
|
|
|
|
spec:
|
|
|
|
ports:
|
|
|
|
- name: "swfs-s3"
|
2021-02-09 15:55:58 +08:00
|
|
|
port: {{ if .Values.s3.enabled }}{{ .Values.s3.port }}{{ else }}{{ .Values.filer.s3.port }}{{ end }}
|
|
|
|
targetPort: {{ if .Values.s3.enabled }}{{ .Values.s3.port }}{{ else }}{{ .Values.filer.s3.port }}{{ end }}
|
2020-03-03 15:56:39 +08:00
|
|
|
protocol: TCP
|
2021-02-09 15:55:58 +08:00
|
|
|
{{- if and .Values.s3.enabled .Values.s3.metricsPort }}
|
|
|
|
- name: "metrics"
|
2020-11-08 08:07:47 +08:00
|
|
|
port: {{ .Values.s3.metricsPort }}
|
2020-10-15 21:10:22 +08:00
|
|
|
targetPort: {{ .Values.s3.metricsPort }}
|
|
|
|
protocol: TCP
|
2020-11-08 08:07:16 +08:00
|
|
|
{{- end }}
|
2020-03-03 15:56:39 +08:00
|
|
|
selector:
|
|
|
|
app: {{ template "seaweedfs.name" . }}
|
2021-02-09 15:55:58 +08:00
|
|
|
component: {{ if .Values.s3.enabled }}s3{{ else }}filer{{ end }}
|