Files
chart/library/ix-dev/community/node-red/templates/_nodered.tpl
Stavros Kois df01fb3304 NAS-122777 / 23.10 / Add node-red to community train (#1323)
* add node-red - initial commit

* add templtes

* add ci values and questions

* run single test

* all but one

* add trace logging

* hmmmm

* root

* add tests

* no 18 for now

* update questions and chart.yaml

* fix tests

* bump common
2023-07-06 15:16:27 +03:00

61 lines
2.1 KiB
Smarty

{{- define "nodered.workload" -}}
workload:
nodered:
enabled: true
primary: true
type: Deployment
podSpec:
hostNetwork: {{ .Values.noderedNetwork.hostNetwork }}
containers:
nodered:
enabled: true
primary: true
imageSelector: {{ .Values.noderedConfig.imageSelector }}
# https://github.com/node-red/node-red-docker/wiki/Permissions-and-Persistence
securityContext:
runAsUser: 1000
runAsGroup: 1000
env:
PORT: {{ .Values.noderedNetwork.webPort }}
NODE_RED_ENABLE_SAFE_MODE: {{ .Values.noderedConfig.safeMode }}
NODE_RED_ENABLE_PROJECTS: {{ .Values.noderedConfig.enableProjects }}
{{ with .Values.noderedConfig.additionalEnvs }}
envList:
{{ range $env := . }}
- name: {{ $env.name }}
value: {{ $env.value }}
{{ end }}
{{ end }}
probes:
liveness:
enabled: true
type: exec
command:
- /bin/sh
- -c
- |
NODE_OPTIONS=--dns-result-order=ipv4first node /healthcheck.js
readiness:
enabled: true
type: exec
command:
- /bin/sh
- -c
- |
NODE_OPTIONS=--dns-result-order=ipv4first node /healthcheck.js
startup:
enabled: true
type: exec
command:
- /bin/sh
- -c
- |
NODE_OPTIONS=--dns-result-order=ipv4first node /healthcheck.js
initContainers:
{{- include "ix.v1.common.app.permissions" (dict "containerName" "01-permissions"
"UID" 1000
"GID" 1000
"mode" "check"
"type" "init") | nindent 8 }}
{{- end -}}