mirror of
https://github.com/truenas/charts.git
synced 2026-04-05 03:39:20 +08:00
* add initial files * add some validation and fix image tag * add modules to the config * extend test and add capabilities * add extra test * rsync -> Rsync and add metadata file * add UI * hide questions when module is disablwed * rename test file and add validation to questions * remove dot * update wording * remove logToStdout toggle * update image
98 lines
2.2 KiB
Smarty
98 lines
2.2 KiB
Smarty
{{- define "rsync.workload" -}}
|
|
workload:
|
|
rsync:
|
|
enabled: true
|
|
primary: true
|
|
type: Deployment
|
|
podSpec:
|
|
hostNetwork: {{ .Values.rsyncNetwork.hostNetwork }}
|
|
containers:
|
|
rsync:
|
|
enabled: true
|
|
primary: true
|
|
imageSelector: image
|
|
securityContext:
|
|
runAsUser: 0
|
|
runAsGroup: 0
|
|
runAsNonRoot: false
|
|
readOnlyRootFilesystem: false
|
|
capabilities:
|
|
add:
|
|
- CHOWN
|
|
- DAC_OVERRIDE
|
|
- FOWNER
|
|
- SETGID
|
|
- SETUID
|
|
- SYS_CHROOT
|
|
probes:
|
|
liveness:
|
|
enabled: true
|
|
type: exec
|
|
command:
|
|
- /bin/sh
|
|
- -c
|
|
- |
|
|
pgrep rsync
|
|
readiness:
|
|
enabled: true
|
|
type: exec
|
|
command:
|
|
- /bin/sh
|
|
- -c
|
|
- |
|
|
pgrep rsync
|
|
startup:
|
|
enabled: true
|
|
type: exec
|
|
command:
|
|
- /bin/sh
|
|
- -c
|
|
- |
|
|
pgrep rsync
|
|
|
|
{{/* Service */}}
|
|
service:
|
|
rsync:
|
|
enabled: true
|
|
primary: true
|
|
type: NodePort
|
|
targetSelector: rsync
|
|
ports:
|
|
rsync:
|
|
enabled: true
|
|
primary: true
|
|
port: {{ .Values.rsyncNetwork.rsyncPort }}
|
|
nodePort: {{ .Values.rsyncNetwork.rsyncPort }}
|
|
targetSelector: rsync
|
|
|
|
{{/* Persistence */}}
|
|
persistence:
|
|
temp:
|
|
enabled: true
|
|
type: emptyDir
|
|
targetSelector:
|
|
rsync:
|
|
rsync:
|
|
mountPath: /tmp
|
|
rsync-conf:
|
|
enabled: true
|
|
type: configmap
|
|
objectName: config
|
|
targetSelector:
|
|
rsync:
|
|
rsync:
|
|
mountPath: /etc/rsyncd.conf
|
|
subPath: rsyncd.conf
|
|
readOnly: true
|
|
{{- range $idx, $mod := .Values.rsyncModules }}
|
|
{{ printf "rsyncd-%v" (int $idx) }}:
|
|
enabled: {{ $mod.enabled }}
|
|
type: hostPath
|
|
hostPath: {{ $mod.hostPath | default "" }}
|
|
targetSelector:
|
|
rsync:
|
|
rsync:
|
|
mountPath: {{ printf "/data/%v" $mod.name }}
|
|
{{- end }}
|
|
{{- end -}}
|