aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLazyDBA247-Anyvision <yonin@anyvision.co>2020-09-10 09:26:12 +0300
committerLazyDBA247-Anyvision <yonin@anyvision.co>2020-09-10 09:26:12 +0300
commit2bed15f1dcbbaab1172e965258bc15d44b8f1b75 (patch)
treedf219efd95f1c7b205562cc606c5dc582fb7f562
parente73f0d4e8150c141702d52a102a761cd1409c177 (diff)
downloadseaweedfs-2bed15f1dcbbaab1172e965258bc15d44b8f1b75.tar.xz
seaweedfs-2bed15f1dcbbaab1172e965258bc15d44b8f1b75.zip
update and add options to the filer statefulset & filer cmd
-rw-r--r--k8s/seaweedfs/templates/filer-statefulset.yaml20
-rw-r--r--k8s/seaweedfs/values.yaml16
2 files changed, 36 insertions, 0 deletions
diff --git a/k8s/seaweedfs/templates/filer-statefulset.yaml b/k8s/seaweedfs/templates/filer-statefulset.yaml
index 0bf20f922..d1dd851fe 100644
--- a/k8s/seaweedfs/templates/filer-statefulset.yaml
+++ b/k8s/seaweedfs/templates/filer-statefulset.yaml
@@ -99,6 +99,9 @@ spec:
{{- end }}
filer \
-port={{ .Values.filer.port }} \
+ {{- if .Values.filer.redirectOnRead }}
+ -redirectOnRead \
+ {{- end }}
{{- if .Values.filer.disableHttp }}
-disableHttp \
{{- end }}
@@ -106,7 +109,24 @@ spec:
-disableDirListing \
{{- end }}
-dirListLimit={{ .Values.filer.dirListLimit }} \
+ {{- if .Values.global.enableReplication }}
+ -defaultReplicaPlacement={{ .Values.global.replicationPlacment }} \
+ {{- else }}
+ -defaultReplicaPlacement={{ .Values.filer.defaultReplicaPlacement }} \
+ {{- end }}
+ {{- if .Values.filer.disableDirListing }}
+ -disableDirListing \
+ {{- end }}
+ {{- if .Values.filer.maxMB }}
+ -maxMB={{ .Values.filer.maxMB }} \
+ {{- end }}
+ {{- if .Values.filer.encryptVolumeData }}
+ -encryptVolumeData \
+ {{- end }}
-ip=${POD_IP} \
+ {{- if gt (.Values.filer.replicas | int) 1 }}
+ -peers={{ range $index := until (.Values.filer.replicas | int) }}${SEAWEEDFS_FULLNAME}-filer-{{ $index }}.${SEAWEEDFS_FULLNAME}-filer:{{ $.Values.filer.port }}{{ if lt $index (sub ($.Values.filer.replicas | int) 1) }},{{ end }}{{ end }}
+ {{- end }}
-master={{ range $index := until (.Values.master.replicas | int) }}${SEAWEEDFS_FULLNAME}-master-{{ $index }}.${SEAWEEDFS_FULLNAME}-master:{{ $.Values.master.port }}{{ if lt $index (sub ($.Values.master.replicas | int) 1) }},{{ end }}{{ end }}
{{- if or (.Values.global.enableSecurity) (.Values.filer.extraVolumeMounts) }}
volumeMounts:
diff --git a/k8s/seaweedfs/values.yaml b/k8s/seaweedfs/values.yaml
index 38e886819..3e1bce181 100644
--- a/k8s/seaweedfs/values.yaml
+++ b/k8s/seaweedfs/values.yaml
@@ -186,6 +186,20 @@ filer:
port: 8888
grpcPort: 18888
loggingOverrideLevel: null
+ # replication type is XYZ:
+ # X number of replica in other data centers
+ # Y number of replica in other racks in the same data center
+ # Z number of replica in other servers in the same rack
+ defaultReplicaPlacement: "000"
+ # turn off directory listing
+ disableDirListing: false
+ # split files larger than the limit, default 32
+ maxMB: null
+ # encrypt data on volume servers
+ encryptVolumeData: false
+
+ # Whether proxy or redirect to volume server during file GET request
+ redirectOnRead: false
# Limit sub dir listing size (default 100000)
dirListLimit: 100000
@@ -269,6 +283,8 @@ filer:
WEED_FILER_BUCKETS_FOLDER: "/buckets"
# directories under this folder will be store message queue data
WEED_FILER_QUEUES_FOLDER: "/queues"
+ # WEED_FILER_OPTIONS_BUCKETS_FSYNC a list of buckets names with all write requests fsync=true
+ WEED_FILER_OPTIONS_BUCKETS_FSYNC: []
s3:
enabled: true