From 0c6be064e3eaec08f9240bfa4d9349794b6a878b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E1=97=AA=D1=94=CE=BD=CE=B9=CE=B7=20=E1=97=B7=CF=85=D0=BD?= =?UTF-8?q?=CA=9F?= Date: Wed, 18 Nov 2020 13:54:50 -0500 Subject: [PATCH] [node-red] migrate to common library (#180) --- charts/node-red/.helmignore | 1 + charts/node-red/Chart.yaml | 10 +- charts/node-red/OWNERS | 2 - charts/node-red/README.md | 124 ++++++++----------- charts/node-red/ci/ct-values.yaml | 2 + charts/node-red/templates/NOTES.txt | 20 +--- charts/node-red/templates/_helpers.tpl | 32 ----- charts/node-red/templates/common.yaml | 1 + charts/node-red/templates/deployment.yaml | 120 ------------------- charts/node-red/templates/ingress.yaml | 38 ------ charts/node-red/templates/pvc.yaml | 24 ---- charts/node-red/templates/service.yaml | 42 ------- charts/node-red/values.yaml | 138 +++------------------- 13 files changed, 76 insertions(+), 478 deletions(-) create mode 100644 charts/node-red/ci/ct-values.yaml delete mode 100644 charts/node-red/templates/_helpers.tpl create mode 100644 charts/node-red/templates/common.yaml delete mode 100644 charts/node-red/templates/deployment.yaml delete mode 100644 charts/node-red/templates/ingress.yaml delete mode 100644 charts/node-red/templates/pvc.yaml delete mode 100644 charts/node-red/templates/service.yaml diff --git a/charts/node-red/.helmignore b/charts/node-red/.helmignore index 46fd8996..e559de0a 100644 --- a/charts/node-red/.helmignore +++ b/charts/node-red/.helmignore @@ -19,5 +19,6 @@ .project .idea/ *.tmproj +.vscode/ # OWNERS file for Kubernetes OWNERS diff --git a/charts/node-red/Chart.yaml b/charts/node-red/Chart.yaml index 93eeb26f..58f243d7 100644 --- a/charts/node-red/Chart.yaml +++ b/charts/node-red/Chart.yaml @@ -1,8 +1,8 @@ apiVersion: v2 -appVersion: 1.0.6-12 +appVersion: 1.2.5 description: Node-RED is low-code programming for event-driven applications name: node-red -version: 3.3.0 +version: 4.0.0 keywords: - nodered - node-red @@ -14,5 +14,7 @@ sources: maintainers: - name: billimek email: jeff@billimek.com - - name: batazor - email: batazor111@gmail.com +dependencies: + - name: common + repository: https://k8s-at-home.com/charts/ + version: ^1.5.1 diff --git a/charts/node-red/OWNERS b/charts/node-red/OWNERS index edce7340..b90909f4 100644 --- a/charts/node-red/OWNERS +++ b/charts/node-red/OWNERS @@ -1,6 +1,4 @@ approvers: - billimek -- batazor reviewers: - billimek -- batazor diff --git a/charts/node-red/README.md b/charts/node-red/README.md index 2053af96..b373b9ab 100644 --- a/charts/node-red/README.md +++ b/charts/node-red/README.md @@ -1,107 +1,79 @@ -# Node-RED +# Node-Red -Low-code programming for event-driven applications +This is a helm chart for [Node-Red](https://nodered.org/). **This chart is not maintained by the Node-RED project and any issues with the chart should be raised [here](https://github.com/k8s-at-home/charts/issues/new)** ## TL;DR; ```shell -helm repo add k8s-at-home https://k8s-at-home.com/charts/ -helm install k8s-at-home/node-red +$ helm repo add k8s-at-home https://k8s-at-home.com/charts/ +$ helm install k8s-at-home/node-red ``` -## Introduction - -This code is adopted from the [official node-red docker image](https://hub.docker.com/r/nodered/node-red/) which runs the [Node-RED application](https://nodered.org/) - ## Installing the Chart To install the chart with the release name `my-release`: -```shell +```console helm install --name my-release k8s-at-home/node-red ``` + ## Uninstalling the Chart To uninstall/delete the `my-release` deployment: -```shell +```console helm delete my-release --purge ``` The command removes all the Kubernetes components associated with the chart and deletes the release. ## Configuration - -The following tables lists the configurable parameters of the Node-RED chart and their default values. - -| Parameter | Description | Default | -|:------------------------------------- |:----------------------------------------------------------------------- |:------------------------- | -| `image.repository` | node-red image | `nodered/node-red` | -| `image.tag` | node-red image tag | `1.0.6-12-minimal` | -| `image.pullPolicy` | node-red image pull policy | `IfNotPresent` | -| `strategyType` | Specifies the strategy used to replace old Pods by new ones | `Recreate` | -| `serviceAccountName` | Service account to run the pod as | `` | -| `probes.liveness.enabled` | Enable/ disable livenessProbe | `true` | -| `probes.liveness.probePath` | Set livenessProbe path | `/` | -| `probes.liveness.initialDelaySeconds` | Set livenessProbe initial delay | 60 | -| `probes.liveness.failureThreshold` | Set livenessProbe failure threshold | 5 | -| `probes.liveness.timeoutSeconds` | Set livenessProbe timeout | 10 | -| `probes.readiness.enabled` | Enable/ disable readinessProbe | `true` | -| `probes.readiness.probePath` | Set readinessProbe path | `/` | -| `probes.readiness.initialDelaySeconds`| Set readinessProbe initial delay | 60 | -| `probes.readiness.failureThreshold` | Set readinessProbe failure threshold | 5 | -| `probes.readiness.timeoutSeconds` | Set readinessProbe timeout | 10 | -| `probes.startup.enabled` | Enable/ disable readinessProbe | `false` | -| `probes.startup.probePath` | Set startupProbe path | `/` | -| `probes.startup.failureThreshold` | Set startupProbe failure threshold | 30 | -| `probes.startup.periodSeconds` | Set startupProbe period | 10 | -| `flows` | Default flows configuration | `flows.json` | -| `safeMode` | Setting to true starts Node-RED in safe (not running) mode | `false` | -| `enableProjects` | setting to true starts Node-RED with the projects feature enabled | `false` | -| `nodeOptions` | Node.js runtime arguments | `` | -| `extraEnvs` | Extra environment variables which will be appended to the env | `[]` | -| `timezone` | Default timezone | `UTC` | -| `service.type` | Kubernetes service type for the GUI | `ClusterIP` | -| `service.port` | Kubernetes port where the GUI is exposed | `1880` | -| `service.nodePort` | Kubernetes nodePort where the GUI is exposed | `` | -| `service.annotations` | Service annotations for the GUI | `{}` | -| `service.labels` | Custom labels | `{}` | -| `service.loadBalancerIP` | Loadbalance IP for the GUI | `{}` | -| `service.loadBalancerSourceRanges` | List of IP CIDRs allowed access to load balancer (if supported) | None | -| `service.externalTrafficPolicy` | Set the externalTrafficPolicy in the Service to either Cluster or Local | `Cluster` | -| `ingress.enabled` | Enables Ingress | `false` | -| `ingress.annotations` | Ingress annotations | `{}` | -| `ingress.path` | Ingress path | `/` | -| `ingress.hosts` | Ingress accepted hostnames | `chart-example.local` | -| `ingress.tls` | Ingress TLS configuration | `[]` | -| `persistence.enabled` | Use persistent volume to store data | `false` | -| `persistence.size` | Size of persistent volume claim | `5Gi` | -| `persistence.existingClaim` | Use an existing PVC to persist data | `nil` | -| `persistence.storageClass` | Type of persistent volume claim | `-` | -| `persistence.accessModes` | Persistence access modes | `ReadWriteOnce` | -| `persistence.subPath` | Mount a sub dir of the persistent volume | `nil` | -| `resources` | CPU/Memory resource requests/limits | `{}` | -| `nodeSelector` | Node labels for pod assignment | `{}` | -| `tolerations` | Toleration labels for pod assignment | `[]` | -| `affinity` | Affinity settings for pod assignment | `{}` | -| `podAnnotations` | Key-value pairs to add as pod annotations | `{}` | -| `deploymentAnnotations` | Key-value pairs to add as deployment annotations | `{}` | -| `hostAliases` | Specify /etc/hosts entries | `[]` | +Read through the charts [values.yaml](https://github.com/k8s-at-home/charts/blob/master/charts/node-red/values.yaml) +file. It has several commented out suggested values. +Additionally you can take a look at the common library [values.yaml](https://github.com/k8s-at-home/charts/blob/master/charts/common/values.yaml) for more (advanced) configuration options. Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example, - -```shell -helm install --name my-release \ - --set config.timezone="America/New_York" \ +```console +helm install node-red \ + --set env.TZ="America/New_York" \ k8s-at-home/node-red ``` - -Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the chart. For example, - -```shell -helm install --name my-release -f values.yaml k8s-at-home/node-red +Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the +chart. For example, +```console +helm install node-red k8s-at-home/node-red --values values.yaml ``` -Read through the [values.yaml](values.yaml) file. It has several commented out suggested values. +These values will be nested as it is a dependency, for example +```yaml +image: + tag: ... +``` + +--- +**NOTE** + +If you get +```console +Error: rendered manifests contain a resource that already exists. Unable to continue with install: existing resource conflict: ...` +``` +it may be because you uninstalled the chart with `skipuninstall` enabled, you need to manually delete the pvc or use `existingClaim`. + +--- + +## Upgrading an existing Release to a new major version + +A major chart version change (like 4.0.1 -> 5.0.0) indicates that there is an incompatible breaking change potentially needing manual actions. + +### Upgrading from 3.x.x to 4.x.x + +Due to migrating to a centralized common library some values in `values.yaml` have changed. + +Examples: + +* `service.port` has been moved to `service.port.port`. +* `persistence.type` has been moved to `controllerType`. + +Refer to the library values.yaml for more configuration options. diff --git a/charts/node-red/ci/ct-values.yaml b/charts/node-red/ci/ct-values.yaml new file mode 100644 index 00000000..f6ccc628 --- /dev/null +++ b/charts/node-red/ci/ct-values.yaml @@ -0,0 +1,2 @@ +ingress: + enabled: true diff --git a/charts/node-red/templates/NOTES.txt b/charts/node-red/templates/NOTES.txt index af7c23e6..90f7b653 100644 --- a/charts/node-red/templates/NOTES.txt +++ b/charts/node-red/templates/NOTES.txt @@ -1,19 +1 @@ -1. Get the application URL by running these commands: -{{- if .Values.ingress.enabled }} -{{- range .Values.ingress.hosts }} - http{{ if $.Values.ingress.tls }}s{{ end }}://{{ . }}{{ $.Values.ingress.path }} -{{- end }} -{{- else if contains "NodePort" .Values.service.type }} - export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "node-red.fullname" . }}) - export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}") - echo http://$NODE_IP:$NODE_PORT -{{- else if contains "LoadBalancer" .Values.service.type }} - NOTE: It may take a few minutes for the LoadBalancer IP to be available. - You can watch the status of by running 'kubectl get svc -w {{ include "node-red.fullname" . }}' - export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "node-red.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}') - echo http://$SERVICE_IP:{{ .Values.service.port }} -{{- else if contains "ClusterIP" .Values.service.type }} - export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "node-red.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}") - echo "Visit http://127.0.0.1:8080 to use your application" - kubectl port-forward $POD_NAME 8080:80 -{{- end }} +{{- include "common.notes.defaultNotes" . -}} diff --git a/charts/node-red/templates/_helpers.tpl b/charts/node-red/templates/_helpers.tpl deleted file mode 100644 index 9c2178fc..00000000 --- a/charts/node-red/templates/_helpers.tpl +++ /dev/null @@ -1,32 +0,0 @@ -{{/* vim: set filetype=mustache: */}} -{{/* -Expand the name of the chart. -*/}} -{{- define "node-red.name" -}} -{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}} -{{- end -}} - -{{/* -Create a default fully qualified app name. -We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). -If release name contains chart name it will be used as a full name. -*/}} -{{- define "node-red.fullname" -}} -{{- if .Values.fullnameOverride -}} -{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}} -{{- else -}} -{{- $name := default .Chart.Name .Values.nameOverride -}} -{{- if contains $name .Release.Name -}} -{{- .Release.Name | trunc 63 | trimSuffix "-" -}} -{{- else -}} -{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}} -{{- end -}} -{{- end -}} -{{- end -}} - -{{/* -Create chart name and version as used by the chart label. -*/}} -{{- define "node-red.chart" -}} -{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}} -{{- end -}} diff --git a/charts/node-red/templates/common.yaml b/charts/node-red/templates/common.yaml new file mode 100644 index 00000000..a6613c2c --- /dev/null +++ b/charts/node-red/templates/common.yaml @@ -0,0 +1 @@ +{{ include "common.all" . }} diff --git a/charts/node-red/templates/deployment.yaml b/charts/node-red/templates/deployment.yaml deleted file mode 100644 index 71ba8f55..00000000 --- a/charts/node-red/templates/deployment.yaml +++ /dev/null @@ -1,120 +0,0 @@ -apiVersion: apps/v1 -kind: Deployment -metadata: - name: {{ include "node-red.fullname" . }} - {{- if .Values.deploymentAnnotations }} - annotations: - {{- range $key, $value := .Values.deploymentAnnotations }} - {{ $key }}: {{ $value | quote }} - {{- end }} - {{- end }} - labels: - app.kubernetes.io/name: {{ include "node-red.name" . }} - helm.sh/chart: {{ include "node-red.chart" . }} - app.kubernetes.io/instance: {{ .Release.Name }} - app.kubernetes.io/managed-by: {{ .Release.Service }} -spec: - replicas: 1 - strategy: - type: {{ .Values.strategyType }} - selector: - matchLabels: - app.kubernetes.io/name: {{ include "node-red.name" . }} - app.kubernetes.io/instance: {{ .Release.Name }} - template: - metadata: - labels: - app.kubernetes.io/name: {{ include "node-red.name" . }} - app.kubernetes.io/instance: {{ .Release.Name }} - {{- if .Values.podAnnotations }} - annotations: - {{- range $key, $value := .Values.podAnnotations }} - {{ $key }}: {{ $value | quote }} - {{- end }} - {{- end }} - spec: - {{- if .Values.serviceAccountName }} - serviceAccountName: {{ .Values.serviceAccountName }} - {{- end }} - containers: - - name: {{ .Chart.Name }} - image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" - imagePullPolicy: {{ .Values.image.pullPolicy }} - ports: - - name: http - containerPort: 1880 - protocol: TCP - {{- if .Values.probes.liveness.enabled }} - livenessProbe: - httpGet: - path: {{ .Values.probes.liveness.probePath }} - port: http - initialDelaySeconds: {{ .Values.probes.liveness.initialDelaySeconds }} - failureThreshold: {{ .Values.probes.liveness.failureThreshold }} - timeoutSeconds: {{ .Values.probes.liveness.timeoutSeconds }} - {{- end }} - {{- if .Values.probes.readiness.enabled }} - readinessProbe: - httpGet: - path: {{ .Values.probes.readiness.probePath }} - port: http - initialDelaySeconds: {{ .Values.probes.readiness.initialDelaySeconds }} - failureThreshold: {{ .Values.probes.readiness.failureThreshold }} - timeoutSeconds: {{ .Values.probes.readiness.timeoutSeconds }} - {{- end }} - {{- if .Values.probes.startup.enabled }} - startupProbe: - httpGet: - path: {{ .Values.probes.startup.probePath }} - port: http - failureThreshold: {{ .Values.probes.startup.failureThreshold }} - periodSeconds: {{ .Values.probes.startup.periodSeconds }} - {{- end }} - env: - - name: FLOWS - value: "{{ .Values.flows }}" - - name: NODE_RED_ENABLE_SAFE_MODE - value: "{{ .Values.safeMode }}" - - name: NODE_RED_ENABLE_PROJECTS - value: "{{ .Values.enableProjects }}" - - name: NODE_OPTIONS - value: "{{ .Values.nodeOptions }}" - - name: TZ - value: "{{ .Values.timezone }}" - {{- with .Values.extraEnvs }} -{{ toYaml . | indent 12 }} - {{- end }} - volumeMounts: - - name: data - mountPath: /data -{{- if .Values.persistence.subPath }} - subPath: {{ .Values.persistence.subPath }} -{{- end }} - resources: -{{ toYaml .Values.resources | indent 12 }} - volumes: - - name: data - {{- if .Values.persistence.enabled }} - persistentVolumeClaim: - claimName: {{ if .Values.persistence.existingClaim }}{{ .Values.persistence.existingClaim }}{{- else }}{{ template "node-red.fullname" . }}{{- end }} - {{- else }} - emptyDir: {} - {{ end }} - {{- if .Values.hostAliases }} - hostAliases: -{{ toYaml .Values.hostAliases | indent 8 }} - {{- end }} - {{- with .Values.nodeSelector }} - nodeSelector: -{{ toYaml . | indent 8 }} - {{- end }} - {{- with .Values.affinity }} - affinity: -{{ toYaml . | indent 8 }} - {{- end }} - {{- with .Values.tolerations }} - tolerations: -{{ toYaml . | indent 8 }} - {{- end }} - securityContext: - fsGroup: 1001 diff --git a/charts/node-red/templates/ingress.yaml b/charts/node-red/templates/ingress.yaml deleted file mode 100644 index d94f4a76..00000000 --- a/charts/node-red/templates/ingress.yaml +++ /dev/null @@ -1,38 +0,0 @@ -{{- if .Values.ingress.enabled -}} -{{- $fullName := include "node-red.fullname" . -}} -{{- $ingressPath := .Values.ingress.path -}} -apiVersion: extensions/v1beta1 -kind: Ingress -metadata: - name: {{ $fullName }} - labels: - app.kubernetes.io/name: {{ include "node-red.name" . }} - helm.sh/chart: {{ include "node-red.chart" . }} - app.kubernetes.io/instance: {{ .Release.Name }} - app.kubernetes.io/managed-by: {{ .Release.Service }} -{{- with .Values.ingress.annotations }} - annotations: -{{ toYaml . | indent 4 }} -{{- end }} -spec: -{{- if .Values.ingress.tls }} - tls: - {{- range .Values.ingress.tls }} - - hosts: - {{- range .hosts }} - - {{ . | quote }} - {{- end }} - secretName: {{ .secretName }} - {{- end }} -{{- end }} - rules: - {{- range .Values.ingress.hosts }} - - host: {{ . | quote }} - http: - paths: - - path: {{ $ingressPath }} - backend: - serviceName: {{ $fullName }} - servicePort: http - {{- end }} -{{- end }} diff --git a/charts/node-red/templates/pvc.yaml b/charts/node-red/templates/pvc.yaml deleted file mode 100644 index f7f22eee..00000000 --- a/charts/node-red/templates/pvc.yaml +++ /dev/null @@ -1,24 +0,0 @@ -{{- if and .Values.persistence.enabled (not .Values.persistence.existingClaim) }} -kind: PersistentVolumeClaim -apiVersion: v1 -metadata: - name: {{ template "node-red.fullname" . }} - labels: - app.kubernetes.io/name: {{ include "node-red.name" . }} - helm.sh/chart: {{ include "node-red.chart" . }} - app.kubernetes.io/instance: {{ .Release.Name }} - app.kubernetes.io/managed-by: {{ .Release.Service }} -spec: - accessModes: - - {{ .Values.persistence.accessMode | quote }} - resources: - requests: - storage: {{ .Values.persistence.size | quote }} -{{- if .Values.persistence.storageClass }} -{{- if (eq "-" .Values.persistence.storageClass) }} - storageClassName: "" -{{- else }} - storageClassName: "{{ .Values.persistence.storageClass }}" -{{- end }} -{{- end }} -{{- end -}} \ No newline at end of file diff --git a/charts/node-red/templates/service.yaml b/charts/node-red/templates/service.yaml deleted file mode 100644 index ea49c966..00000000 --- a/charts/node-red/templates/service.yaml +++ /dev/null @@ -1,42 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: {{ include "node-red.fullname" . }} - {{- if .Values.service.annotations }} - annotations: - {{- toYaml .Values.service.annotations | nindent 4 }} - {{- end }} - labels: - app.kubernetes.io/name: {{ include "node-red.name" . }} - helm.sh/chart: {{ include "node-red.chart" . }} - app.kubernetes.io/instance: {{ .Release.Name }} - app.kubernetes.io/managed-by: {{ .Release.Service }} -spec: -{{- if (or (eq .Values.service.type "ClusterIP") (empty .Values.service.type)) }} - type: ClusterIP -{{- else if eq .Values.service.type "LoadBalancer" }} - type: {{ .Values.service.type }} - {{- if .Values.service.loadBalancerIP }} - loadBalancerIP: {{ .Values.service.loadBalancerIP }} - {{- end }} - {{- if .Values.service.loadBalancerSourceRanges }} - loadBalancerSourceRanges: -{{ toYaml .Values.service.loadBalancerSourceRanges | indent 4 }} - {{- end -}} -{{- else }} - type: {{ .Values.service.type }} -{{- end }} - {{- if .Values.service.externalTrafficPolicy }} - externalTrafficPolicy: {{ .Values.service.externalTrafficPolicy }} - {{- end }} - ports: - - port: {{ .Values.service.port }} - targetPort: http - protocol: TCP - name: http -{{ if (and (eq .Values.service.type "NodePort") (not (empty .Values.service.nodePort))) }} - nodePort: {{.Values.service.nodePort}} -{{ end }} - selector: - app.kubernetes.io/name: {{ include "node-red.name" . }} - app.kubernetes.io/instance: {{ .Release.Name }} diff --git a/charts/node-red/values.yaml b/charts/node-red/values.yaml index ac75189e..2f26c688 100644 --- a/charts/node-red/values.yaml +++ b/charts/node-red/values.yaml @@ -1,132 +1,28 @@ # Default values for node-red. -# This is a YAML-formatted file. -# Declare variables to be passed into your templates. - -# upgrade strategy type (e.g. Recreate or RollingUpdate) -strategyType: Recreate image: repository: nodered/node-red - tag: 1.0.6-12-minimal pullPolicy: IfNotPresent + tag: 1.2.5 -nameOverride: "" -fullnameOverride: "" +strategy: + type: Recreate -serviceAccountName: "" - -# Probes configuration -# ref: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#container-probes -probes: - liveness: - # Indicates whether the container is running. If the liveness probe fails, the kubelet kills the container - # and the container is subjected to its restart policy. - enabled: true - probePath: / - initialDelaySeconds: 60 - failureThreshold: 5 - timeoutSeconds: 10 - readiness: - # Indicates whether the container is ready to respond to requests. - enabled: true - probePath: / - initialDelaySeconds: 60 - failureThreshold: 5 - timeoutSeconds: 10 - startup: - # Indicates whether the application within the container is started. - # All other probes are disabled if a startup probe is provided, until it succeeds. - enabled: false - probePath: / - failureThreshold: 30 - periodSeconds: 10 - -flows: "flows.json" -safeMode: "false" -enableProjects: "false" -# nodeOptions: "" -extraEnvs: [] -timezone: "UTC" +# See more environment varaibles in the node-red documentation +# https://nodered.org/docs/getting-started/docker +env: {} + # TZ: + # NODE_OPTIONS: + # NODE_RED_ENABLE_PROJECTS: + # NODE_RED_ENABLE_SAFE_MODE: + # FLOWS: service: - type: ClusterIP - port: 1880 - ## Specify the nodePort value for the LoadBalancer and NodePort service types. - ## ref: https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport - ## - # nodePort: - ## Provide any additional annotations which may be required. This can be used to - ## set the LoadBalancer service type to internal only. - ## ref: https://kubernetes.io/docs/concepts/services-networking/service/#internal-load-balancer - ## - annotations: {} - labels: {} - ## Use loadBalancerIP to request a specific static IP, - ## otherwise leave blank - ## - loadBalancerIP: - # loadBalancerSourceRanges: [] - ## Set the externalTrafficPolicy in the Service to either Cluster or Local - # externalTrafficPolicy: Cluster - -hostAliases: [] - # Use hostAliases to add custom entries to /etc/hosts - mapping IP addresses to hostnames. - # ref: https://kubernetes.io/docs/concepts/services-networking/add-entries-to-pod-etc-hosts-with-host-aliases/ - # - ip: "192.168.1.100" - # hostnames: - # - "example.com" - # - "www.example.com" - -ingress: - enabled: false - annotations: {} - # kubernetes.io/ingress.class: nginx - # kubernetes.io/tls-acme: "true" - path: / - hosts: - - chart-example.local - tls: [] - # - secretName: chart-example-tls - # hosts: - # - chart-example.local + port: + port: 1880 persistence: - enabled: false - ## node-red data Persistent Volume Storage Class - ## If defined, storageClassName: - ## If set to "-", storageClassName: "", which disables dynamic provisioning - ## If undefined (the default) or set to null, no storageClassName spec is - ## set, choosing the default provisioner. (gp2 on AWS, standard on - ## GKE, AWS & OpenStack) - ## - # storageClass: "-" - ## - ## If you want to reuse an existing claim, you can pass the name of the PVC using - ## the existingClaim variable - # existingClaim: your-claim - accessMode: ReadWriteOnce - size: 5Gi - ## When mounting the data volume you may specify a subPath - # subPath: /configs/node-red - -resources: {} - # We usually recommend not to specify default resources and to leave this as a conscious - # choice for the user. This also increases chances charts run on environments with little - # resources, such as Minikube. If you do want to specify resources, uncomment the following - # lines, adjust them as necessary, and remove the curly braces after 'resources:'. - # limits: - # cpu: 100m - # memory: 128Mi - # requests: - # cpu: 100m - # memory: 128Mi - -nodeSelector: {} - -tolerations: [] - -affinity: {} - -podAnnotations: {} - -deploymentAnnotations: {} + data: + enabled: false + emptyDir: false + mountPath: /data