Compare commits

...

13 Commits

Author SHA1 Message Date
coldfire84
4cfc8fc0db [node-red] Add startupProbe (#147)
* Add startupProbe to Node-RED chart in order to address slow starting container being killed due to liveness probe failures.

* Bump node-red chart version

* Update version to reflect new feature.

* Paramaterisation of liveness, readiness and startup probe configuration.

Configure startup probe to disabled by default.

Co-authored-by: Jeff Billimek <jeff@billimek.com>
2020-11-14 12:29:03 -05:00
Bernd Schörgers
0ec462c58e [multiple] Bump library version (#157) 2020-11-14 09:42:45 -05:00
Bernd Schörgers
533f78729b [common] Resolve indenting issues, fixes #155 (#156) 2020-11-14 08:41:05 -05:00
ᗪєνιη ᗷυнʟ
a9e5b0efd0 [zwave2mqtt] convert to use common library (#151) 2020-11-14 08:35:18 -05:00
Bernd Schörgers
7ce69b4b01 [multiple] Bump library version (#145) 2020-11-12 14:00:52 -05:00
Bernd Schörgers
1aa1b7f67e [common] Fix fluxv2 issues (#144)
Co-authored-by: ᗪєνιη ᗷυнʟ <onedr0p@users.noreply.github.com>
2020-11-12 13:17:01 -05:00
Bernd Schörgers
7d02733b54 [multiple] Bump library version (#143)
Co-authored-by: ᗪєνιη ᗷυнʟ <onedr0p@users.noreply.github.com>
2020-11-11 16:50:43 -05:00
Bernd Schörgers
e54addcc77 [common] Allow setting strategy and replicas (#142) 2020-11-11 16:09:17 -05:00
Bernd Schörgers
e3420259d5 [multiple] Update common library (#141) 2020-11-11 14:09:22 -05:00
Bernd Schörgers
62955c1d38 [common] Use k8s-at-home wireguard image (#140) 2020-11-11 13:26:31 -05:00
Michael Kötter
407949920e [unifi] syslog & promtail logging (#105)
* add syslog service

* promtail sidecar

* bump version

* update README

Co-authored-by: Jeff Billimek <jeff@billimek.com>
2020-11-11 08:46:50 -05:00
Holden Omans
5f0a25248b [homebridge] Missing strategyType in homebridge deployment (#110)
* Missing strategyType in homebridge deployment

* Update Chart.yaml

* Update values.yaml

Co-authored-by: Jeff Billimek <jeff@billimek.com>
2020-11-11 08:39:24 -05:00
Bernd Schörgers
8946802950 [CI] Fix deprecation warning (#136) 2020-11-10 10:48:35 -05:00
62 changed files with 520 additions and 501 deletions

View File

@@ -9,7 +9,7 @@ jobs:
- name: Fetch history
run: |
git fetch --prune --unshallow;
echo ::set-env name=commitmsg::$(git log --format=%B -n 1 ${{ github.event.after }})
echo "commitmsg=$(git log --format=%B -n 1 ${{ github.event.after }})" >> $GITHUB_ENV
- name: Run chart-testing (lint)
id: lint
uses: helm/chart-testing-action@v1.0.0

View File

@@ -2,7 +2,7 @@ apiVersion: v2
appVersion: v0.9.0.5
description: Bazarr is a companion application to Sonarr and Radarr. It manages and downloads subtitles based on your requirements
name: bazarr
version: 4.0.2
version: 4.4.0
keywords:
- bazarr
- radarr
@@ -21,4 +21,4 @@ maintainers:
dependencies:
- name: common
repository: https://k8s-at-home.com/charts/
version: ^1.1.0
version: ^1.5.0

View File

@@ -5,6 +5,9 @@ image:
pullPolicy: IfNotPresent
tag: version-v0.9.0.5
strategy:
type: Recreate
service:
port:
port: 6767

View File

@@ -2,7 +2,7 @@ apiVersion: v2
name: common
description: Function library for k8s-at-home charts
type: library
version: 1.1.0
version: 1.5.0
keywords:
- k8s-at-home
- common

View File

@@ -1,8 +1,6 @@
{{- define "common.all" -}}
{{- /* Merge the local chart values and the common chart defaults */ -}}
{{- $defaultValues := .Values.common -}}
{{- $_ := deepCopy $defaultValues | merge .Values -}}
{{- $_ := unset .Values "common" -}}
{{- include "common.values.setup" . }}
{{- /* Enable OpenVPN VPN add-on if required */ -}}
{{- if .Values.addons.vpn.enabled }}

View File

@@ -4,16 +4,20 @@ kind: Deployment
metadata:
name: {{ template "common.names.fullname" . }}
labels:
{{- include "common.labels" . | nindent 4 }}
{{- with .Values.controllerLabels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- include "common.labels" . | nindent 4 }}
{{- with .Values.controllerLabels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.controllerAnnotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
replicas: 1
replicas: {{ .Values.replicas }}
{{- with .Values.strategy }}
strategy:
{{- toYaml . | nindent 4 }}
{{- end }}
selector:
matchLabels:
{{- include "common.labels.selectorLabels" . | nindent 6 }}
@@ -49,14 +53,14 @@ spec:
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | indent 8 }}
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.affinity }}
affinity:
{{- toYaml . | indent 8 }}
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | indent 8 }}
{{- toYaml . | nindent 8 }}
{{- end }}
{{- end }}

View File

@@ -4,7 +4,6 @@
{{- /* Generate primary ingress */ -}}
{{- $ingressValues := .Values.ingress -}}
{{- $_ := set $ingressValues "svcPort" $svcPort -}}
{{- $_ := set . "ObjectValues" (dict "ingress" $ingressValues) -}}
{{- include "common.classes.ingress" . }}
@@ -13,7 +12,6 @@
{{- if $extraIngress.enabled -}}
{{- print ("---") | nindent 0 -}}
{{- $ingressValues := $extraIngress -}}
{{- $_ := set $ingressValues "svcPort" $svcPort -}}
{{- if not $ingressValues.nameSuffix -}}
{{- $_ := set $ingressValues "nameSuffix" $index -}}
{{ end -}}

View File

@@ -13,7 +13,11 @@ metadata:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
replicas: 1
replicas: {{ .Values.replicas }}
{{- with .Values.strategy }}
updateStrategy:
{{- toYaml . | nindent 4 }}
{{- end }}
selector:
matchLabels:
{{- include "common.labels.selectorLabels" . | nindent 6 }}
@@ -50,14 +54,14 @@ spec:
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | indent 8 }}
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.affinity }}
affinity:
{{- toYaml . | indent 8 }}
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | indent 8 }}
{{- toYaml . | nindent 8 }}
{{- end }}
{{- end }}

View File

@@ -5,15 +5,15 @@ The OpenVPN container(s) to be inserted
name: openvpn
image: "{{ .Values.addons.vpn.openvpn.image.repository }}:{{ .Values.addons.vpn.openvpn.image.tag }}"
imagePullPolicy: {{ .Values.addons.vpn.imagePullPolicy }}
{{- with .Values.addons.vpn.securityContext }}
securityContext:
capabilities:
add:
- NET_ADMIN
{{- toYaml . | nindent 2 }}
{{- end }}
{{- with .Values.addons.vpn.env }}
env:
{{- range $k, $v := . }}
- name: {{ $k }}
value: {{ $v }}
value: {{ $v | quote }}
{{- end }}
{{- end }}
{{- if or .Values.addons.vpn.openvpn.auth .Values.addons.vpn.openvpn.authSecret }}
@@ -52,10 +52,10 @@ volumeMounts:
{{- end }}
{{- with .Values.addons.vpn.livenessProbe }}
livenessProbe:
{{- toYaml . | nindent 4 }}
{{- toYaml . | nindent 2 }}
{{- end -}}
{{- with .Values.addons.vpn.resources }}
resources:
{{- toYaml . | nindent 4 }}
{{- toYaml . | nindent 2 }}
{{- end }}
{{- end -}}

View File

@@ -3,7 +3,7 @@ Template to render Wireguard addon
*/}}
{{- define "common.addon.wireguard" -}}
{{/* Append the Wireguard container to the additionalContainers */}}
{{- $container := include "common.addon.wireguard.container" . | fromYaml -}}
{{- $container := fromYaml (include "common.addon.wireguard.container" .) -}}
{{- if $container -}}
{{- $additionalContainers := append .Values.additionalContainers $container -}}
{{- $_ := set .Values "additionalContainers" $additionalContainers -}}

View File

@@ -5,24 +5,22 @@ The Wireguard container(s) to be inserted
name: wireguard
image: "{{ .Values.addons.vpn.wireguard.image.repository }}:{{ .Values.addons.vpn.wireguard.image.tag }}"
imagePullPolicy: {{ .Values.addons.vpn.imagePullPolicy }}
{{- with .Values.addons.vpn.securityContext }}
securityContext:
privileged: true
capabilities:
add:
- NET_ADMIN
- SYS_MODULE
{{- toYaml . | nindent 2 }}
{{- end }}
{{- with .Values.addons.vpn.env }}
env:
{{- range $k, $v := . }}
- name: {{ $k }}
value: {{ $v }}
value: {{ $v | quote }}
{{- end }}
{{- end }}
{{- if or .Values.addons.vpn.configFile .Values.addons.vpn.scripts.up .Values.addons.vpn.scripts.down .Values.addons.vpn.additionalVolumeMounts .Values.persistence.shared.enabled }}
volumeMounts:
{{- if .Values.addons.vpn.configFile }}
- name: vpnconfig
mountPath: /config/wg0.conf
mountPath: /etc/wireguard/wg0.conf
subPath: vpnConfigfile
{{- end }}
{{- if .Values.addons.vpn.scripts.up }}
@@ -45,10 +43,10 @@ volumeMounts:
{{- end }}
{{- with .Values.addons.vpn.livenessProbe }}
livenessProbe:
{{- toYaml . | nindent 4 }}
{{- toYaml . | nindent 2 }}
{{- end -}}
{{- with .Values.addons.vpn.resources }}
resources:
{{- toYaml . | nindent 4 }}
{{- toYaml . | nindent 2 }}
{{- end }}
{{- end -}}

View File

@@ -9,7 +9,8 @@
{{- if hasKey $values "nameSuffix" -}}
{{- $ingressName = printf "%v-%v" $ingressName $values.nameSuffix -}}
{{ end -}}
{{- $svcPort := $values.svcPort -}}
{{- $svcName := $values.serviceName | default (include "common.names.fullname" .) -}}
{{- $svcPort := $values.servicePort | default $.Values.service.port.port -}}
apiVersion: {{ include "common.capabilities.ingress.apiVersion" . }}
kind: Ingress
metadata:
@@ -39,7 +40,7 @@ spec:
{{- range .paths }}
- path: {{ .path }}
backend:
serviceName: {{ $ingressName }}
serviceName: {{ $svcName }}
servicePort: {{ $svcPort }}
{{- end }}
{{- end }}

View File

@@ -0,0 +1,9 @@
{{- define "common.values.setup" -}}
{{- /* Merge the local chart values and the common chart defaults */ -}}
{{- if .Values.common -}}
{{- $defaultValues := deepCopy .Values.common -}}
{{- $userValues := deepCopy (omit .Values "common") -}}
{{- $mergedValues := mustMergeOverwrite $defaultValues $userValues -}}
{{- $_ := set . "Values" (deepCopy $mergedValues) -}}
{{- end }}
{{- end }}

View File

@@ -6,15 +6,15 @@ volumes included by the controller
{{- if $persistence.enabled }}
- name: {{ $index }}
{{- if $persistence.existingClaim }}
{{/* Always prefer an existingClaim if that is set */}}
{{- /* Always prefer an existingClaim if that is set */}}
persistentVolumeClaim:
claimName: {{ $persistence.existingClaim }}
{{- else -}}
{{- if $persistence.emptyDir -}}
{{/* Always prefer an emptyDir next if that is set */}}
{{- /* Always prefer an emptyDir next if that is set */}}
emptyDir: {}
{{- else -}}
{{/* Otherwise refer to the PVC name */}}
{{- /* Otherwise refer to the PVC name */}}
persistentVolumeClaim:
{{- if $persistence.nameSuffix }}
claimName: {{ printf "%s-%s" (include "common.names.fullname" $) $persistence.nameSuffix }}

View File

@@ -5,6 +5,12 @@ controllerAnnotations: {}
# Set labels on the deployment/statefulset
controllerLabels: {}
replicas: 1
strategy:
## For Deployments, valid values are Recreate and RollingUpdate
## For StatefulSets, valid values are OnDelete and RollingUpdate
type: RollingUpdate
# Set annotations on the pod
podAnnotations: {}
@@ -37,7 +43,7 @@ service:
type: ClusterIP
# Specify the default port information
port:
port: ""
port:
name: http
protocol: TCP
targetPort: http
@@ -96,8 +102,8 @@ ingress:
# - host: chart-example.local
# paths:
# - path: /api
# # Ignored if not kubeVersion >= 1.14-0
# pathType: Prefix
# # Ignored if not kubeVersion >= 1.14-0
# pathType: Prefix
# tls: []
# # - secretName: chart-example-tls
# # hosts:
@@ -135,6 +141,12 @@ additionalVolumes: []
additionalVolumeMounts: []
nodeSelector: {}
affinity: {}
tolerations: []
addons:
vpn:
enabled: false
@@ -154,14 +166,21 @@ addons:
# under the VPN_AUTH key
authSecret: # my-vpn-secret
# OpenVPN specific configuration
# WireGuard specific configuration
wireguard:
image:
repository: linuxserver/wireguard
tag: version-v1.0.20200827
repository: k8sathome/wireguard
tag: 1.0.20200827
imagePullPolicy: IfNotPresent
# Set the VPN container securityContext
securityContext:
capabilities:
add:
- NET_ADMIN
- SYS_MODULE
# All variables specified here will be added to the vpn sidecar container
# See the documentation of the VPN image for all config values
env: {}

View File

@@ -1,6 +1,6 @@
apiVersion: v2
appVersion: 3.1.0
version: 1.0.1
version: 1.0.2
name: homebridge
description: A lightweight NodeJS server that emulates the iOS HomeKit API
type: application

View File

@@ -6,6 +6,8 @@ metadata:
{{- include "homebridge.labels" . | nindent 4 }}
spec:
replicas: {{ .Values.replicaCount }}
strategy:
type: {{ .Values.strategyType }}
selector:
matchLabels:
{{- include "homebridge.selectorLabels" . | nindent 6 }}

View File

@@ -12,6 +12,9 @@ imagePullSecrets: []
nameOverride: ""
fullnameOverride: ""
# upgrade strategy type (e.g. Recreate or RollingUpdate)
strategyType: Recreate
timezone: "UTC"
puid: 1000
pgid: 1000

View File

@@ -2,7 +2,7 @@ apiVersion: v2
appVersion: v0.16.2106
description: API Support for your favorite torrent trackers
name: jackett
version: 5.0.4
version: 5.4.0
keywords:
- jackett
- torrent
@@ -17,4 +17,4 @@ maintainers:
dependencies:
- name: common
repository: https://k8s-at-home.com/charts/
version: ^1.1.0
version: ^1.5.0

View File

@@ -5,6 +5,9 @@ image:
pullPolicy: IfNotPresent
tag: version-v0.16.2106
strategy:
type: Recreate
service:
port:
port: 9117

View File

@@ -2,7 +2,7 @@ apiVersion: v2
appVersion: 0.8.0.1886
description: Looks and smells like Sonarr but made for music
name: lidarr
version: 5.0.2
version: 5.4.0
keywords:
- lidarr
- torrent
@@ -18,4 +18,4 @@ maintainers:
dependencies:
- name: common
repository: https://k8s-at-home.com/charts/
version: ^1.1.0
version: ^1.5.0

View File

@@ -5,6 +5,9 @@ image:
pullPolicy: IfNotPresent
tag: version-0.8.0.1886
strategy:
type: Recreate
service:
port:
port: 8686

View File

@@ -2,7 +2,7 @@ apiVersion: v2
appVersion: 1.0.6-12
description: Node-RED is low-code programming for event-driven applications
name: node-red
version: 3.1.0
version: 3.2.0
keywords:
- nodered
- node-red

View File

@@ -36,46 +36,58 @@ The command removes all the Kubernetes components associated with the chart and
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 | `` |
| `livenessProbePath` | Default livenessProbe path | `/` |
| `readinessProbePath` | Default readinessProbe path | `/` |
| `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 | `{}` |
| 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 | `{}` |
Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example,

View File

@@ -44,14 +44,32 @@ spec:
- name: http
containerPort: 1880
protocol: TCP
{{- if .Values.probes.liveness.enabled }}
livenessProbe:
httpGet:
path: {{ .Values.livenessProbePath }}
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.readinessProbePath }}
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 }}"

View File

@@ -15,8 +15,31 @@ fullnameOverride: ""
serviceAccountName: ""
livenessProbePath: /
readinessProbePath: /
# 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"

View File

@@ -2,7 +2,7 @@ apiVersion: v2
appVersion: v21.0
description: NZBGet is a Usenet downloader client
name: nzbget
version: 6.0.1
version: 6.4.0
keywords:
- nzbget
- usenet
@@ -17,4 +17,4 @@ maintainers:
dependencies:
- name: common
repository: https://k8s-at-home.com/charts/
version: ^1.1.0
version: ^1.5.0

View File

@@ -5,6 +5,9 @@ image:
pullPolicy: IfNotPresent
tag: version-v21.0
strategy:
type: Recreate
service:
port:
port: 6789

View File

@@ -2,7 +2,7 @@ apiVersion: v2
appVersion: v3.4.3
description: Usenet meta search
name: nzbhydra2
version: 4.0.2
version: 4.4.0
keywords:
- nzbhydra2
- usenet
@@ -17,4 +17,4 @@ maintainers:
dependencies:
- name: common
repository: https://k8s-at-home.com/charts/
version: ^1.1.0
version: ^1.5.0

View File

@@ -5,6 +5,9 @@ image:
pullPolicy: IfNotPresent
tag: version-v3.4.3
strategy:
type: Recreate
service:
port:
port: 5076

View File

@@ -2,7 +2,7 @@ apiVersion: v2
appVersion: 4.0.681
description: Want a Movie or TV Show on Plex or Emby? Use Ombi!
name: ombi
version: 5.0.2
version: 5.4.0
keywords:
- ombi
- plex
@@ -21,4 +21,4 @@ maintainers:
dependencies:
- name: common
repository: https://k8s-at-home.com/charts/
version: ^1.1.0
version: ^1.5.0

View File

@@ -5,6 +5,9 @@ image:
pullPolicy: IfNotPresent
tag: version-v4.0.681
strategy:
type: Recreate
service:
port:
port: 3579

View File

@@ -2,7 +2,7 @@ apiVersion: v2
appVersion: latest
description: HTPC/Homelab Services Organizer
name: organizr
version: 2.0.2
version: 2.4.0
keywords:
- organizr
home: https://github.com/k8s-at-home/charts/tree/master/charts/organizr
@@ -16,4 +16,4 @@ maintainers:
dependencies:
- name: common
repository: https://k8s-at-home.com/charts/
version: ^1.1.0
version: ^1.5.0

View File

@@ -5,6 +5,9 @@ image:
pullPolicy: Always
tag: latest
strategy:
type: Recreate
service:
port:
port: 80

View File

@@ -2,7 +2,7 @@ apiVersion: v2
appVersion: 4.3.0
description: qBittorrent is a cross-platform free and open-source BitTorrent client
name: qbittorrent
version: 6.0.1
version: 6.4.0
keywords:
- qbittorrent
- torrrent
@@ -16,4 +16,4 @@ maintainers:
dependencies:
- name: common
repository: https://k8s-at-home.com/charts/
version: ^1.1.0
version: ^1.5.0

View File

@@ -5,6 +5,9 @@ image:
pullPolicy: IfNotPresent
tag: version-4.3.0202010181232-7086-1c663adeeubuntu18.04.1
strategy:
type: Recreate
env: {}
# TZ: UTC
# PUID: 1001

View File

@@ -2,7 +2,7 @@ apiVersion: v2
appVersion: 3.0.0.3989
description: A fork of Sonarr to work with movies à la Couchpotato
name: radarr
version: 7.0.2
version: 7.4.0
keywords:
- radarr
- torrent
@@ -18,4 +18,4 @@ maintainers:
dependencies:
- name: common
repository: https://k8s-at-home.com/charts/
version: ^1.1.0
version: ^1.5.0

View File

@@ -5,6 +5,9 @@ image:
pullPolicy: IfNotPresent
tag: version-3.0.0.3989
strategy:
type: Recreate
service:
port:
port: 7878

View File

@@ -2,7 +2,7 @@ apiVersion: v2
appVersion: 3.1.0
description: Free and easy binary newsreader
name: sabnzbd
version: 3.0.2
version: 3.4.0
keywords:
- sabnzbd
- usenet
@@ -17,4 +17,4 @@ maintainers:
dependencies:
- name: common
repository: https://k8s-at-home.com/charts/
version: ^1.1.0
version: ^1.5.0

View File

@@ -5,6 +5,9 @@ image:
pullPolicy: IfNotPresent
tag: version-3.1.0
strategy:
type: Recreate
service:
port:
port: 8080

View File

@@ -2,7 +2,7 @@ apiVersion: v2
appVersion: 3.0.4.993
description: Smart PVR for newsgroup and bittorrent users
name: sonarr
version: 7.0.3
version: 7.4.0
keywords:
- sonarr
- torrent
@@ -18,4 +18,4 @@ maintainers:
dependencies:
- name: common
repository: https://k8s-at-home.com/charts/
version: ^1.1.0
version: ^1.5.0

View File

@@ -5,6 +5,9 @@ image:
pullPolicy: IfNotPresent
tag: version-3.0.4.993
strategy:
type: Recreate
service:
port:
port: 8989

View File

@@ -2,7 +2,7 @@ apiVersion: v2
appVersion: v2.6.1
description: A Python based monitoring and tracking tool for Plex Media Server
name: tautulli
version: 5.0.2
version: 5.4.0
keywords:
- tautulli
- plex
@@ -17,4 +17,4 @@ maintainers:
dependencies:
- name: common
repository: https://k8s-at-home.com/charts/
version: ^1.1.0
version: ^1.5.0

View File

@@ -5,6 +5,9 @@ image:
pullPolicy: IfNotPresent
tag: v2.5.4
strategy:
type: Recreate
service:
port:
port: 8181

View File

@@ -2,7 +2,7 @@ apiVersion: v2
appVersion: 5.12.35
description: Ubiquiti Network's Unifi Controller
name: unifi
version: 1.0.0
version: 1.1.0
keywords:
- ubiquiti
- unifi

View File

@@ -86,7 +86,14 @@ The following tables lists the configurable parameters of the Unifi chart and th
| `discoveryService.loadBalancerIP` | `{}` | Loadbalance IP for AP discovery |
| `discoveryService.loadBalancerSourceRanges` | None | List of IP CIDRs allowed access to load balancer (if supported) |
| `discoveryService.externalTrafficPolicy` | `Cluster` | Set the externalTrafficPolicy in the Service to either Cluster or Local |
| `unifiedService.enabled` | `false` | Use a single service for GUI, controller, STUN, and discovery |
| `syslogService.type` | `NodePort` | Kubernetes service type for remote syslog capture |
| `syslogService.port` | `5514` | Kubernetes UDP port for remote syslog capture |
| `syslogService.annotations` | `{}` | Service annotations for remote syslog capture |
| `syslogService.labels` | `{}` | Custom labels |
| `syslogService.loadBalancerIP` | `{}` | Loadbalancer IP for remote syslog capture |
| `syslogService.loadBalancerSourceRanges` | None | List of IP CIDRs allowed access to load balancer (if supported) |
| `syslogService.externalTrafficPolicy` | `Cluster` | Set the externalTrafficPolicy in the Service to either Cluster or Local |
| `unifiedService.enabled` | `false` | Use a single service for GUI, controller, STUN, discovery and syslog |
| `unifiedService.type` | `ClusterIP` | Kubernetes service type for the unified service |
| `unifiedService.annotations` | `{}` | Annotations for the unified service |
| `unifiedService.labels` | `{}` | Custom labels for the unified service |
@@ -108,6 +115,11 @@ The following tables lists the configurable parameters of the Unifi chart and th
| `customCert.certName` | `tls.crt` | Name of the the certificate file in `<unifi-data>/cert` |
| `customCert.keyName` | `tls.key` | Name of the the private key file in `<unifi-data>/cert` |
| `customCert.certSecret` | `nil` | Name of the the k8s tls secret where the certificate and its key are stored. |
| `logging.promtail.enabled` | `false` | Enable a Promtail sidecar to collect controller logs |
| `logging.promtail.image.repository` | `grafana/promtail` | Promtail image repository |
| `logging.promtail.image.tag` | `1.6.0` | Promtail image tag |
| `logging.promtail.image.pullPolicy` | `IfNotPresent` | Promtail image pull policy |
| `logging.promtail.loki.url` | `http://loki.logs.svc.cluster.local:3100/loki/api/v1/push` | URL of the Loki push API |
| `mongodb.enabled` | `false` | Use external MongoDB for data storage |
| `mongodb.dbUri` | `mongodb://mongo/unifi` | external MongoDB URI |
| `mongodb.statDbUri` | `mongodb://mongo/unifi_stat` | external MongoDB statdb URI |
@@ -163,6 +175,9 @@ Read through the [values.yaml](values.yaml) file. It has several commented out s
- `stunService`: Also used periodically by the unifi devices to communicate
with the controller using UDP. See [this article][ubnt 3] and [this other
article][ubnt 4] for more information.
- `syslogService`: Used to capture syslog from Unifi devices if the feature is
enabled in the site configuration. This needs to be reachable by Unifi devices
on port 5514/UDP.
## Ingress and HTTPS

View File

@@ -34,6 +34,21 @@ spec:
{{- end }}
spec:
containers:
{{- if .Values.logging.promtail.enabled }}
- name: {{ .Chart.Name }}-promtail
image: "{{ .Values.logging.promtail.image.repository }}:{{ .Values.logging.promtail.image.tag }}"
imagePullPolicy: {{ .Values.logging.promtail.image.pullPolicy }}
args:
- -config.file=/etc/promtail/promtail.yaml
volumeMounts:
- name: promtail-config
mountPath: /etc/promtail/promtail.yaml
subPath: promtail.yaml
readOnly: true
- mountPath: /unifi/log
name: unifi-data
subPath: {{ ternary "log" (printf "%s/%s" .Values.persistence.subPath "log") (empty .Values.persistence.subPath) }}
{{- end }}
- name: {{ .Chart.Name }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
@@ -50,6 +65,9 @@ spec:
- name: stun
containerPort: 3478
protocol: UDP
- name: syslog
containerPort: 5514
protocol: UDP
{{ if .Values.captivePortalService.enabled }}
- name: captive-http
containerPort: 8880
@@ -151,6 +169,17 @@ spec:
secret:
secretName: "{{ .Values.customCert.certSecret }}"
{{- end }}
{{- if .Values.logging.promtail.enabled }}
- name: promtail-config
projected:
defaultMode: 0444
sources:
- configMap:
name: {{ template "unifi.fullname" . }}-promtail
items:
- key: promtail.yaml
path: promtail.yaml
{{- end }}
{{- if .Values.extraVolumes }}{{ toYaml .Values.extraVolumes | trim | nindent 8 }}{{ end }}
{{- with .Values.nodeSelector }}
nodeSelector:

View File

@@ -0,0 +1,34 @@
{{- if .Values.logging.promtail.enabled }}
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ template "unifi.fullname" . }}-promtail
labels:
app.kubernetes.io/name: {{ include "unifi.name" . }}
helm.sh/chart: {{ include "unifi.chart" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
data:
promtail.yaml: |
server:
disable: true
positions:
filename: /tmp/positions.yaml
clients:
- url: {{ .Values.logging.promtail.loki.url }}
scrape_configs:
- job_name: unifi-logs
static_configs:
- targets:
- localhost
labels:
job: unifi-logs
__path__: "/unifi/log/*.log"
- job_name: unifi-remote-logs
static_configs:
- targets:
- localhost
labels:
job: unifi-remote-logs
__path__: "/unifi/log/remote/*.log"
{{- end }}

View File

@@ -0,0 +1,54 @@
{{ if not .Values.syslogService.enabled }}
apiVersion: v1
kind: Service
metadata:
name: {{ template "unifi.fullname" . }}-syslog
labels:
app.kubernetes.io/name: {{ include "unifi.name" . }}
helm.sh/chart: {{ include "unifi.chart" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
{{- if .Values.syslogService.labels }}
{{ toYaml .Values.syslogService.labels | indent 4 }}
{{- end }}
{{- with .Values.syslogService.annotations }}
annotations:
{{ toYaml . | indent 4 }}
{{- end }}
spec:
{{- if (or (eq .Values.syslogService.type "ClusterIP") (empty .Values.syslogService.type)) }}
type: ClusterIP
{{- if .Values.syslogService.clusterIP }}
clusterIP: {{ .Values.syslogService.clusterIP }}
{{end}}
{{- else if eq .Values.syslogService.type "LoadBalancer" }}
type: {{ .Values.syslogService.type }}
{{- if .Values.syslogService.loadBalancerIP }}
loadBalancerIP: {{ .Values.syslogService.loadBalancerIP }}
{{- end }}
{{- if .Values.syslogService.loadBalancerSourceRanges }}
loadBalancerSourceRanges:
{{ toYaml .Values.syslogService.loadBalancerSourceRanges | indent 4 }}
{{- end -}}
{{- else }}
type: {{ .Values.syslogService.type }}
{{- end }}
{{- if .Values.syslogService.externalIPs }}
externalIPs:
{{ toYaml .Values.syslogService.externalIPs | indent 4 }}
{{- end }}
{{- if .Values.syslogService.externalTrafficPolicy }}
externalTrafficPolicy: {{ .Values.syslogService.externalTrafficPolicy }}
{{- end }}
ports:
- port: {{ .Values.syslogService.port }}
targetPort: syslog
protocol: UDP
name: syslog
{{ if (and (eq .Values.syslogService.type "NodePort") (not (empty .Values.syslogService.nodePort))) }}
nodePort: {{.Values.syslogService.nodePort}}
{{ end }}
selector:
app.kubernetes.io/name: {{ include "unifi.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{ end }}

View File

@@ -61,6 +61,13 @@ spec:
name: stun
{{ if (and (eq .Values.unifiedService.type "NodePort") (not (empty .Values.stunService.nodePort))) }}
nodePort: {{.Values.stunService.nodePort}}
{{ end }}
- port: {{ .Values.syslogService.port }}
targetPort: syslog
protocol: UDP
name: syslog
{{ if (and (eq .Values.unifiedService.type "NodePort") (not (empty .Values.syslogService.nodePort))) }}
nodePort: {{.Values.syslogService.nodePort}}
{{ end }}
- name: https-gui
port: {{ .Values.guiService.port }}

View File

@@ -10,10 +10,10 @@ image:
tag: 5.12.35
pullPolicy: IfNotPresent
# If enabled, the controller, discovery, GUI, and STUN services will not be
# If enabled, the controller, discovery, GUI, STUN and syslog services will not be
# created.
# Instead, one service will be created with the port and nodePort settings from
# controllerService, discoveryService, guiService, and stunService.
# controllerService, discoveryService, guiService, stunService and syslogService.
# This is useful if, for example, the ClusterIP network is routable and being
# accessed directly by access points, and the APs don't have a way to discern
# different services on different IPs.
@@ -169,6 +169,27 @@ discoveryService:
## Set the externalTrafficPolicy in the Service to either Cluster or Local
# externalTrafficPolicy: Cluster
syslogService:
type: NodePort
port: 5514 # udp
## 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
ingress:
enabled: false
annotations: {}
@@ -200,6 +221,17 @@ customCert:
# you can pass the name of that secret using certSecret variable
# certSecret: unifi-tls
# Logging configuration
logging:
promtail:
enabled: false
image:
repository: grafana/promtail
tag: 1.6.0
pullPolicy: IfNotPresent
loki:
url: http://loki.logs.svc.cluster.local:3100/loki/api/v1/push
# define an external mongoDB instead of using the built-in mongodb
mongodb:
enabled: false

View File

@@ -1,8 +1,8 @@
apiVersion: v2
appVersion: 4.0.3
appVersion: 4.0.6
description: Fully configurable Zwave to MQTT gateway and Control Panel using NodeJS and Vue
name: zwave2mqtt
version: 4.0.0
version: 5.1.0
keywords:
- zwave
- mqtt
@@ -14,3 +14,7 @@ sources:
maintainers:
- name: billimek
email: jeff@billimek.com
dependencies:
- name: common
repository: https://k8s-at-home.com/charts/
version: ^1.5.0

View File

@@ -1,6 +1,6 @@
# zwave2mqtt: Fully configurable Zwave to MQTT Gateway and Control Panel
# zwave2mqtt
This is a helm chart for [zwave2mqtt](https://github.com/OpenZWave/Zwave2Mqtt)
This is a helm chart for [zwave2mqtt](https://zwave2mqtt.org/).
## TL;DR;
@@ -19,7 +19,20 @@ helm install --name my-release k8s-at-home/zwave2mqtt
**IMPORTANT NOTE:** a zwave controller device must be accessible on the node where this pod runs, in order for this chart to function properly.
A way to achieve this can be with nodeAffinity rules, for example:
First, you will need to mount your zwave device into the pod, you can do so by adding the following to your values:
```yaml
additionalVolumeMounts:
- name: usb
mountPath: /path/to/device
additionalVolumes:
- name: usb
hostPath:
path: /path/to/device
```
Second you will need to set a nodeAffinity rule, for example:
```yaml
affinity:
@@ -45,31 +58,49 @@ helm delete my-release --purge
The command removes all the Kubernetes components associated with the chart and deletes the release.
## Configuration
Read through the [values.yaml](https://github.com/k8s-at-home/charts/blob/master/charts/zwave2mqtt/values.yaml) file. It has several commented out suggested values.
Read through the charts [values.yaml](https://github.com/k8s-at-home/charts/blob/master/charts/zwave2mqtt/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,
```console
helm install --name my-release \
--set rtspPassword="nosecrets" \
helm install my-release \
--set env.TZ="America/New_York" \
k8s-at-home/zwave2mqtt
```
Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the chart. For example,
Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the
chart. For example,
```console
helm install --name my-release -f values.yaml stable/zwave2mqtt
helm install my-release k8s-at-home/zwave2mqtt --values values.yaml
```
```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 2.2.2 -> 3.0.0) indicates that there is an
incompatible breaking change needing manual actions.
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
### Upgrading from 4.x.x to 5.x.x
Upgrading to this release it is suggested to enable the flag in Settings > Zwave > Auto update database
As of 5.0.0 this chart was migrated to a centralized [common](https://github.com/k8s-at-home/charts/tree/master/charts/common) library, some values in `values.yaml` have changed.
In order to use an updated configuration for the devices, you have to send a refreshNodeInfo to that node
Examples:
* `service.port` has been moved to `service.port.port`.
* `persistence.type` has been moved to `controllerType`.
Refer to the [common](https://github.com/k8s-at-home/charts/tree/master/charts/common) library for more configuration options.

View File

@@ -0,0 +1,2 @@
ingress:
enabled: true

View File

@@ -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 "zwave2mqtt.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 "zwave2mqtt.fullname" . }}'
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "zwave2mqtt.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 "zwave2mqtt.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
echo "Visit http://127.0.0.1:5000 to use your application"
kubectl port-forward $POD_NAME 5000:5000
{{- end }}
{{- include "common.notes.defaultNotes" . -}}

View File

@@ -1,45 +0,0 @@
{{/* vim: set filetype=mustache: */}}
{{/*
Expand the name of the chart.
*/}}
{{- define "zwave2mqtt.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 "zwave2mqtt.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 "zwave2mqtt.chart" -}}
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
{{- end -}}
{{/*
Common labels
*/}}
{{- define "zwave2mqtt.labels" -}}
app.kubernetes.io/name: {{ include "zwave2mqtt.name" . }}
helm.sh/chart: {{ include "zwave2mqtt.chart" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- if .Chart.AppVersion }}
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
{{- end }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
{{- end -}}

View File

@@ -0,0 +1 @@
{{ include "common.all" . }}

View File

@@ -1,92 +0,0 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "zwave2mqtt.fullname" . }}
labels:
{{ include "zwave2mqtt.labels" . | indent 4 }}
spec:
replicas: 1
revisionHistoryLimit: 3
strategy:
type: {{ .Values.strategyType }}
selector:
matchLabels:
app.kubernetes.io/name: {{ include "zwave2mqtt.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
template:
metadata:
labels:
app.kubernetes.io/name: {{ include "zwave2mqtt.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- if .Values.podAnnotations }}
annotations:
{{- range $key, $value := .Values.podAnnotations }}
{{ $key }}: {{ $value | quote }}
{{- end }}
{{- end }}
spec:
{{- with .Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
containers:
- name: {{ .Chart.Name }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
securityContext:
privileged: true
ports:
- name: http
containerPort: 8091
protocol: TCP
livenessProbe:
httpGet:
path: /
port: http
scheme: HTTP
initialDelaySeconds: {{ .Values.probes.liveness.initialDelaySeconds }}
failureThreshold: {{ .Values.probes.liveness.failureThreshold }}
timeoutSeconds: {{ .Values.probes.liveness.timeoutSeconds }}
readinessProbe:
httpGet:
path: /
port: http
scheme: HTTP
initialDelaySeconds: {{ .Values.probes.readiness.initialDelaySeconds }}
failureThreshold: {{ .Values.probes.readiness.failureThreshold }}
timeoutSeconds: {{ .Values.probes.readiness.timeoutSeconds }}
env:
{{- if .Values.timezone }}
- name: TZ
value: "{{ .Values.timezone }}"
{{- end }}
volumeMounts:
- mountPath: {{ .Values.device }}
name: usb
- mountPath: /usr/src/app/store
name: config
resources:
{{- toYaml .Values.resources | nindent 12 }}
volumes:
- name: config
{{- if .Values.persistence.enabled }}
persistentVolumeClaim:
claimName: {{ if .Values.persistence.existingClaim }}{{ .Values.persistence.existingClaim }}{{- else }}{{ template "zwave2mqtt.fullname" . }}{{- end }}
{{- else }}
emptyDir: {}
{{- end }}
- name: usb
hostPath:
path: {{ .Values.device }}
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.affinity }}
affinity:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}

View File

@@ -1,35 +0,0 @@
{{- if .Values.ingress.enabled -}}
{{- $fullName := include "zwave2mqtt.fullname" . -}}
{{- $ingressPath := .Values.ingress.path -}}
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
name: {{ $fullName }}
labels:
{{ include "zwave2mqtt.labels" . | indent 4 }}
{{- with .Values.ingress.annotations }}
annotations:
{{- toYaml . | nindent 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 }}

View File

@@ -1,29 +0,0 @@
{{- if and .Values.persistence.enabled (not .Values.persistence.existingClaim) }}
kind: PersistentVolumeClaim
apiVersion: v1
metadata:
name: {{ template "zwave2mqtt.fullname" . }}
{{- if .Values.persistence.skipuninstall }}
annotations:
"helm.sh/resource-policy": keep
{{- end }}
labels:
app.kubernetes.io/name: {{ include "zwave2mqtt.name" . }}
helm.sh/chart: {{ include "zwave2mqtt.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 -}}

View File

@@ -1,49 +0,0 @@
apiVersion: v1
kind: Service
metadata:
name: {{ template "zwave2mqtt.fullname" . }}
labels:
{{ include "zwave2mqtt.labels" . | indent 4 }}
{{- if .Values.service.labels }}
{{ toYaml .Values.service.labels | indent 4 }}
{{- end }}
{{- with .Values.service.annotations }}
annotations:
{{ toYaml . | indent 4 }}
{{- end }}
spec:
{{- if (or (eq .Values.service.type "ClusterIP") (empty .Values.service.type)) }}
type: ClusterIP
{{- if .Values.service.clusterIP }}
clusterIP: {{ .Values.service.clusterIP }}
{{end}}
{{- 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.externalIPs }}
externalIPs:
{{ toYaml .Values.service.externalIPs | indent 4 }}
{{- end }}
{{- if .Values.service.externalTrafficPolicy }}
externalTrafficPolicy: {{ .Values.service.externalTrafficPolicy }}
{{- end }}
ports:
- name: http
port: {{ .Values.service.port }}
protocol: TCP
targetPort: http
{{ if (and (eq .Values.service.type "NodePort") (not (empty .Values.service.nodePort))) }}
nodePort: {{.Values.service.nodePort}}
{{ end }}
selector:
app.kubernetes.io/name: {{ include "zwave2mqtt.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}

View File

@@ -1,105 +1,58 @@
# Default values for zwave2mqtt.
# 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: robertslando/zwave2mqtt
tag: 4.0.3
pullPolicy: IfNotPresent
tag: 4.0.6
# timezone to run the service as
# timezone: "America/New York"
strategy:
type: Recreate
# device where the zwave device can be accessed
device: "/dev/ttyASM0"
imagePullSecrets: []
nameOverride: ""
fullnameOverride: ""
# Probes configuration
probes:
liveness:
initialDelaySeconds: 30
failureThreshold: 5
timeoutSeconds: 10
readiness:
initialDelaySeconds: 30
failureThreshold: 5
timeoutSeconds: 10
persistence:
enabled: false
## zwave2mqtt configuration data Persistent Volume Storage Class
## If defined, storageClassName: <storageClass>
## 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: 1Gi
## Do not delete the pvc upon helm uninstall
skipuninstall: false
env:
OZW_AUTO_UPDATE_CONFIG: true
service:
type: ClusterIP
port: 8091
## 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
port:
port: 8091
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
securityContext:
privileged: true
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
persistence:
config:
enabled: false
emptyDir: false
mountPath: /usr/src/app/store
## Persistent Volume Storage Class
## If defined, storageClassName: <storageClass>
## 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: "-"
# accessMode: ReadWriteOnce
# size: 1Gi
## Do not delete the pvc upon helm uninstall
# skipuninstall: false
# existingClaim: ""
nodeSelector: {}
# Path to your zwave device in the container
additionalVolumeMounts:
- name: usb
mountPath: /dev/serial/by-id/usb-0658_0200-if00
tolerations: []
# Path to your zwave device on the host
additionalVolumes:
- name: usb
hostPath:
path: /dev/serial/by-id/usb-0658_0200-if00
affinity: {}
podAnnotations: {}
# affinity:
# nodeAffinity:
# requiredDuringSchedulingIgnoredDuringExecution:
# nodeSelectorTerms:
# - matchExpressions:
# - key: app
# operator: In
# values:
# - zwave-controller