Skip to content

Commit 4ded2da

Browse files
committed
chore(charts): change filer settings
1 parent d04fb84 commit 4ded2da

4 files changed

Lines changed: 9 additions & 1 deletion

File tree

charts/controller/templates/_helpers.tpl

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ env:
1616
value: "{{ .Values.global.registrySecretPrefix }}"
1717
- name: "IMAGE_PULL_POLICY"
1818
value: "{{ .Values.appImagePullPolicy }}"
19+
- name: "DRYCC_FILER_IMAGE"
20+
value: "{{ (tpl .Values.filerImage .) }}"
21+
- name: "DRYCC_FILER_IMAGE_PULL_POLICY"
22+
value: "{{ (tpl .Values.filerImagePullPolicy .) }}"
1923
- name: "KUBERNETES_CLUSTER_DOMAIN"
2024
value: "{{ .Values.global.clusterDomain }}"
2125
{{- if (.Values.appStorageClass) }}

charts/controller/values.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ registrationMode: "admin_only"
3131
k8sApiVerifyTls: "true"
3232
# Set app image pull policy
3333
appImagePullPolicy: "Always"
34+
# Filer settings image and image pull policy
35+
filerImage: "registry.drycc.cc/drycc/filer:canary"
36+
filerImagePullPolicy: "Always"
3437
# Set storageClassName. It is used for application.
3538
appStorageClass: "{{ .Values.storage.csi.storageClassName }}"
3639
# Set runtimeClassName. It is used for application.

rootfs/api/filer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ def get_server(self):
5353
"labels": {"app": self.app_id, "pod": pod_name, "volume": self.volume.name},
5454
"app_type": "filer", "replicas": 1, "deploy_timeout": 120, "volumes": [k8s_volume],
5555
"volume_mounts": [{"mountPath": self.path, "name": self.volume.name}],
56-
"restart_policy": "Never", "image_pull_policy": "Always",
56+
"restart_policy": "Never", "image_pull_policy": settings.DRYCC_FILER_IMAGE_PULL_POLICY,
5757
})
5858
address = self.scheduler.pod.get(self.app_id, pod_name).json()["status"]["podIP"]
5959
return {"address": address, "username": username, "password": password}

rootfs/api/settings/production.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -303,6 +303,7 @@
303303
# Drycc filer image
304304
# Provide get and put operations for `drycc volumes:client`
305305
DRYCC_FILER_IMAGE = os.environ.get('DRYCC_FILER_IMAGE', 'registry.drycc.cc/drycc/filer:canary')
306+
DRYCC_FILER_IMAGE_PULL_POLICY = os.environ.get('DRYCC_FILER_IMAGE_PULL_POLICY', 'IfNotPresent')
306307
DRYCC_FILER_DURATION = int(os.environ.get('DRYCC_FILER_DURATION', '3600'))
307308
DRYCC_FILER_WAITTIME = int(os.environ.get('DRYCC_FILER_WAITTIME', '1200'))
308309

0 commit comments

Comments
 (0)