mirror of
https://github.com/k8s-at-home/charts.git
synced 2025-02-03 07:49:03 +00:00
[deconz] Migrate to common (reason: Fix labels that prevent upgrading) (#695)
* fix: missing probe timeout value
* fix!: remove version from immutable fields
* Revert "fix: missing probe timeout value"
This reverts commit c4ff58480a
.
* fix: missing probe timeout value
* feat!: migrate to common chart with new version
* docs: regenerate
* docs: add migration steps
* style: fix linting
This commit is contained in:
parent
f49a054d38
commit
00ea6e06c3
@ -14,10 +14,13 @@
|
||||
*.swp
|
||||
*.bak
|
||||
*.tmp
|
||||
*.orig
|
||||
*~
|
||||
# Various IDEs
|
||||
.project
|
||||
.idea/
|
||||
*.tmproj
|
||||
.vscode/
|
||||
# OWNERS file for Kubernetes
|
||||
OWNERS
|
||||
# helm-docs templates
|
||||
*.gotmpl
|
||||
|
@ -1,12 +1,14 @@
|
||||
apiVersion: v2
|
||||
appVersion: 2.10.03
|
||||
description: deCONZ is an easy to use control software, with which you can set up and control Zigbee networks of any size without further programming effort.
|
||||
name: deconz
|
||||
description: A Helm chart for deploying deCONZ
|
||||
version: 2.0.3
|
||||
appVersion: 2.05.80
|
||||
version: 3.0.0
|
||||
kubeVersion: ">=1.16.0-0"
|
||||
keywords:
|
||||
- deconz
|
||||
- home-automation
|
||||
- zigbee
|
||||
- conbee
|
||||
home: https://github.com/k8s-at-home/charts/tree/master/charts/stable/deconz
|
||||
icon: https://avatars1.githubusercontent.com/u/4217524?s=400&v=4
|
||||
sources:
|
||||
@ -15,3 +17,7 @@ sources:
|
||||
maintainers:
|
||||
- name: billimek
|
||||
email: jeff@billimek.com
|
||||
dependencies:
|
||||
- name: common
|
||||
repository: https://library-charts.k8s-at-home.com
|
||||
version: 1.0.0
|
||||
|
@ -1,8 +1,8 @@
|
||||
# deconz
|
||||
|
||||
![Version: 2.0.3](https://img.shields.io/badge/Version-2.0.3-informational?style=flat-square) ![AppVersion: 2.05.80](https://img.shields.io/badge/AppVersion-2.05.80-informational?style=flat-square)
|
||||
![Version: 3.0.0](https://img.shields.io/badge/Version-3.0.0-informational?style=flat-square) ![AppVersion: 2.10.03](https://img.shields.io/badge/AppVersion-2.10.03-informational?style=flat-square)
|
||||
|
||||
A Helm chart for deploying deCONZ
|
||||
deCONZ is an easy to use control software, with which you can set up and control Zigbee networks of any size without further programming effort.
|
||||
|
||||
**This chart is not maintained by the upstream project and any issues with the chart should be raised [here](https://github.com/k8s-at-home/charts/issues/new/choose)**
|
||||
|
||||
@ -13,10 +13,13 @@ A Helm chart for deploying deCONZ
|
||||
|
||||
## Requirements
|
||||
|
||||
Kubernetes: `>=1.16.0-0`
|
||||
|
||||
## Dependencies
|
||||
|
||||
| Repository | Name | Version |
|
||||
|------------|------|---------|
|
||||
| https://library-charts.k8s-at-home.com | common | 1.0.0 |
|
||||
|
||||
## TL;DR
|
||||
|
||||
@ -73,65 +76,23 @@ N/A
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| affinity | object | `{}` | Affinity settings for pod assignment |
|
||||
| autoscaling.enabled | bool | `false` | Enables Pod auto-scaling |
|
||||
| autoscaling.maxReplicas | int | `1` | Maximum number of replicas to auto-scale to |
|
||||
| autoscaling.minReplicas | int | `1` | Minimum number of replicas to auto-scale to |
|
||||
| extraVolumes | list | `[]` | Optionally add additional Volumes Volumes will be mounted to the folder specified under mountPath If no mountPath is set it will be mounted to /mnt/<name> |
|
||||
| fullnameOverride | string | `""` | |
|
||||
| image.pullPolicy | string | `"IfNotPresent"` | Image pull policy |
|
||||
| image.repository | string | `"marthoc/deconz"` | Image repository |
|
||||
| image.tag | string | `"amd64-2.05.80"` | Image tag. Possible values listed [here](https://hub.docker.com/r/marthoc/deconz/tags/). |
|
||||
| imagePullSecrets | list | `[]` | |
|
||||
| ingress.annotations | object | `{}` | Ingress annotations |
|
||||
| ingress.enabled | bool | `false` | Enables Ingress |
|
||||
| ingress.hosts | list | `[{"host":"deconz.local"}]` | Ingress accepted hostnames |
|
||||
| ingress.labels | object | `{}` | |
|
||||
| ingress.path | string | `"/"` | Ingress path |
|
||||
| ingress.tls | list | `[]` | Ingress TLS configuration |
|
||||
| nameOverride | string | `""` | |
|
||||
| nodeSelector | object | `{}` | Node labels for pod assignment |
|
||||
| persistence.accessMode | string | `"ReadWriteOnce"` | Use an existing PVC to persist data existingClaim: deconz-data -- Persistence access mode |
|
||||
| persistence.annotations | object | `{}` | Key-value pairs to add as persistent volume claim annotations |
|
||||
| persistence.enabled | bool | `false` | Use persistent volume to store configuration data |
|
||||
| persistence.size | string | `"1Gi"` | Size of persistent volume claim |
|
||||
| podAnnotations | object | `{}` | Key-value pairs to add as pod annotations |
|
||||
| podSecurityContext | object | `{}` | |
|
||||
| probes.liveness.enabled | bool | `true` | Enables liveness probe for the Pod |
|
||||
| probes.liveness.failureThreshold | int | `5` | Specify liveness `failureThreshold` parameter for the Pod |
|
||||
| probes.liveness.initialDelaySeconds | int | `30` | Specify liveness `initialDelaySeconds` parameter for the Pod |
|
||||
| probes.liveness.timeoutSeconds | int | `10` | Specify liveness `timeoutSeconds` parameter for the Pod |
|
||||
| probes.readiness.enabled | bool | `true` | Enables readiness probe for the Pod |
|
||||
| probes.readiness.failureThreshold | int | `5` | Specify readiness `failureThreshold` parameter for the Pod |
|
||||
| probes.readiness.initialDelaySeconds | int | `30` | Specify readiness `initialDelaySeconds` parameter for the Pod |
|
||||
| probes.startup.enabled | bool | `false` | Enables startup probe for the Pod |
|
||||
| probes.startup.failureThreshold | int | `30` | Specify startup `failureThreshold` parameter for the Pod |
|
||||
| probes.startup.periodSeconds | int | `10` | Specify startup `periodSeconds` parameter for the Pod |
|
||||
| replicaCount | int | `1` | Number of replicas to scale to |
|
||||
| resources | object | `{}` | CPU/Memory resource requests/limits |
|
||||
| securityContext.privileged | bool | `true` | |
|
||||
| service.annotations | object | `{}` | Service annotations for the GUI |
|
||||
| service.clusterIP | string | `""` | |
|
||||
| service.externalIPs | list | `[]` | |
|
||||
| service.externalTrafficPolicy | string | `"Local"` | Set the externalTrafficPolicy in the Service to either Cluster or Local |
|
||||
| service.httpPort | int | `80` | Kubernetes port where the GUI is exposed |
|
||||
| service.labels | object | `{}` | Custom labels |
|
||||
| service.loadBalancerIP | string | `""` | Loadbalancer IP for the GUI |
|
||||
| service.loadBalancerSourceRanges | string | `nil` | List of IP CIDRs allowed access to load balancer (if supported) |
|
||||
| service.type | string | `"ClusterIP"` | Kubernetes service type for the GUI |
|
||||
| service.vncPort | int | `5900` | Kubernetes port where the VNC server is exposed |
|
||||
| service.websocketPort | int | `443` | Kubernetes port where the websocket is exposed |
|
||||
| serviceAccount.annotations | object | `{}` | Annotations to add to the service account |
|
||||
| serviceAccount.create | bool | `true` | Specifies whether a service account should be created |
|
||||
| serviceAccount.name | string | `""` | The name of the service account to use. @default: a name is generated using the fullname template |
|
||||
| strategyType | string | `"Recreate"` | Specifies the strategy used to replace old Pods by new ones |
|
||||
| timezone | string | `"UTC"` | Timezone the instance should run as, e.g. 'America/New_York' |
|
||||
| tolerations | list | `[]` | Toleration labels for pod assignment |
|
||||
| vnc.enabled | bool | `true` | Enabled the built-in VNC server to access the application |
|
||||
| vnc.existingSecret | string | `""` | Existing Kubernetes secret containing the VNC password |
|
||||
| vnc.password | string | `"changeme"` | VNC server password |
|
||||
| zigbeeDevice.enabled | bool | `false` | Enables passing through a Zigbee device |
|
||||
| zigbeeDevice.hostPath | string | `"/dev/ttyUSB1"` | HostPath of the Zigbee device that should be passed through |
|
||||
| env.DECONZ_VNC_MODE | int | `1` | |
|
||||
| env.DECONZ_VNC_PORT | int | `5900` | |
|
||||
| env.DECONZ_WEB_PORT | int | `80` | |
|
||||
| env.DECONZ_WS_PORT | int | `443` | |
|
||||
| env.TZ | string | `"UTC"` | |
|
||||
| image.pullPolicy | string | `"IfNotPresent"` | |
|
||||
| image.repository | string | `"marthoc/deconz"` | |
|
||||
| image.tag | string | `"amd64-2.10.03"` | |
|
||||
| ingress.enabled | bool | `false` | |
|
||||
| persistence.config.enabled | bool | `false` | |
|
||||
| persistence.config.mountPath | string | `"/root/.local/share/dresden-elektronik/deCONZ"` | |
|
||||
| service.additionalPorts[0].name | string | `"websocket"` | |
|
||||
| service.additionalPorts[0].port | int | `443` | |
|
||||
| service.additionalPorts[1].name | string | `"vnc"` | |
|
||||
| service.additionalPorts[1].port | int | `5900` | |
|
||||
| service.port.port | int | `80` | |
|
||||
| strategy.type | string | `"Recreate"` | |
|
||||
|
||||
## Changelog
|
||||
|
||||
@ -139,21 +100,21 @@ All notable changes to this application Helm chart will be documented in this fi
|
||||
|
||||
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||
|
||||
### [2.0.2]
|
||||
### [3.0.0]
|
||||
|
||||
#### Added
|
||||
#### Migration !breaking change!
|
||||
|
||||
- N/A
|
||||
This version migrates the chart to the common dependency. If you have used prior versions that had version labels
|
||||
attached to the volume template of the `StatefulSet`, you will need to remove the `StatefulSet` manually prior to update
|
||||
or the update will fail until it's removed.
|
||||
|
||||
If you used auto provisioning on the config volume, a new volume will be created upon update. It is recommended to **backup**
|
||||
the prior configuration using Phoscon App (deCONZ frontend) and restore it on a fresh installation (default password on fresh installation: `delight`).
|
||||
This will preserve all devices, settings and access tokens. The configuration can also be restored by copying files over from the old volume.
|
||||
|
||||
#### Changed
|
||||
|
||||
- move to helm-docs
|
||||
|
||||
#### Removed
|
||||
|
||||
- N/A
|
||||
|
||||
[2.0.2]: #2.0.2
|
||||
- Initial release using common chart
|
||||
|
||||
## Support
|
||||
|
||||
|
@ -9,19 +9,19 @@ All notable changes to this application Helm chart will be documented in this fi
|
||||
|
||||
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||
|
||||
### [2.0.2]
|
||||
### [3.0.0]
|
||||
|
||||
#### Added
|
||||
#### Migration !breaking change!
|
||||
|
||||
- N/A
|
||||
This version migrates the chart to the common dependency. If you have used prior versions that had version labels
|
||||
attached to the volume template of the `StatefulSet`, you will need to remove the `StatefulSet` manually prior to update
|
||||
or the update will fail until it's removed.
|
||||
|
||||
If you used auto provisioning on the config volume, a new volume will be created upon update. It is recommended to **backup**
|
||||
the prior configuration using Phoscon App (deCONZ frontend) and restore it on a fresh installation (default password on fresh installation: `delight`).
|
||||
This will preserve all devices, settings and access tokens. The configuration can also be restored by copying files over from the old volume.
|
||||
|
||||
#### Changed
|
||||
|
||||
- move to helm-docs
|
||||
|
||||
#### Removed
|
||||
|
||||
- N/A
|
||||
|
||||
[2.0.2]: #2.0.2
|
||||
- Initial release using common chart
|
||||
{{- end -}}
|
||||
|
@ -1,22 +1 @@
|
||||
{{- $svcPort := .Values.service.httpPort -}}
|
||||
1. Get the application URL by running these commands:
|
||||
{{- if .Values.ingress.enabled }}
|
||||
{{- range $host := .Values.ingress.hosts }}
|
||||
{{- range .paths }}
|
||||
http{{ if $.Values.ingress.tls }}s{{ end }}://{{ $host.host }}{{ . }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- else if contains "NodePort" .Values.service.type }}
|
||||
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "deconz.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 --namespace {{ .Release.Namespace }} svc -w {{ include "deconz.fullname" . }}'
|
||||
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "deconz.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
|
||||
echo http://$SERVICE_IP:{{ $svcPort }}
|
||||
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "deconz.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 --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:{{ $svcPort }}
|
||||
{{- end }}
|
||||
{{- include "common.notes.defaultNotes" . -}}
|
||||
|
@ -1,114 +0,0 @@
|
||||
{{/* vim: set filetype=mustache: */}}
|
||||
{{/*
|
||||
Expand the name of the chart.
|
||||
*/}}
|
||||
{{- define "deconz.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 "deconz.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 "deconz.chart" -}}
|
||||
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Common labels
|
||||
*/}}
|
||||
{{- define "deconz.labels" -}}
|
||||
helm.sh/chart: {{ include "deconz.chart" . }}
|
||||
{{ include "deconz.selectorLabels" . }}
|
||||
{{- if .Chart.AppVersion }}
|
||||
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||
{{- end }}
|
||||
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Selector labels
|
||||
*/}}
|
||||
{{- define "deconz.selectorLabels" -}}
|
||||
app.kubernetes.io/name: {{ include "deconz.name" . }}
|
||||
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Create the name of the service account to use
|
||||
*/}}
|
||||
{{- define "deconz.serviceAccountName" -}}
|
||||
{{- if .Values.serviceAccount.create }}
|
||||
{{- default (include "deconz.fullname" .) .Values.serviceAccount.name }}
|
||||
{{- else }}
|
||||
{{- default "default" .Values.serviceAccount.name }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Return true if a secret object should be created
|
||||
*/}}
|
||||
{{- define "deconz.createSecret" -}}
|
||||
{{- if .Values.vnc.existingSecret }}
|
||||
{{- else -}}
|
||||
{{- true -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Get the password secret.
|
||||
*/}}
|
||||
{{- define "deconz.secretName" -}}
|
||||
{{- if .Values.vnc.existingSecret }}
|
||||
{{- printf "%s" .Values.vnc.existingSecret -}}
|
||||
{{- else -}}
|
||||
{{- printf "%s" (include "deconz.fullname" .) -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Get the additional volumes
|
||||
*/}}
|
||||
{{- define "deconz.extraVolumes" -}}
|
||||
{{- if .Values.extraVolumes }}
|
||||
{{- $extraVolumes := .Values.extraVolumes -}}
|
||||
{{- range $extraVolumes }}
|
||||
{{- $_ := unset . "mountPath" }}
|
||||
{{- end }}
|
||||
{{- toYaml $extraVolumes }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Get the additional volumeMounts
|
||||
*/}}
|
||||
{{- define "deconz.extraVolumeMounts" -}}
|
||||
{{- if .Values.extraVolumes }}
|
||||
{{- $extraVolumeMounts := list -}}
|
||||
{{- range .Values.extraVolumes }}
|
||||
{{- if .mountPath }}
|
||||
{{- $extraVolumeMounts = dict "name" .name "mountPath" .mountPath | append $extraVolumeMounts -}}
|
||||
{{- else }}
|
||||
{{- $extraVolumeMounts = dict "name" .name "mountPath" (printf "/mnt/%s" .name) | append $extraVolumeMounts -}}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- toYaml $extraVolumeMounts }}
|
||||
{{- end }}
|
||||
{{- end }}
|
1
charts/stable/deconz/templates/common.yaml
Normal file
1
charts/stable/deconz/templates/common.yaml
Normal file
@ -0,0 +1 @@
|
||||
{{ include "common.all" . }}
|
@ -1,15 +0,0 @@
|
||||
{{- if .Values.autoscaling.enabled }}
|
||||
apiVersion: autoscaling/v2beta1
|
||||
kind: HorizontalPodAutoscaler
|
||||
metadata:
|
||||
name: {{ include "deconz.fullname" . }}
|
||||
labels:
|
||||
{{- include "deconz.labels" . | nindent 4 }}
|
||||
spec:
|
||||
scaleTargetRef:
|
||||
apiVersion: apps/v1
|
||||
kind: StatefulSet
|
||||
name: {{ include "deconz.fullname" . }}
|
||||
minReplicas: {{ .Values.autoscaling.minReplicas }}
|
||||
maxReplicas: {{ .Values.autoscaling.maxReplicas }}
|
||||
{{- end }}
|
@ -1,40 +0,0 @@
|
||||
{{- if .Values.ingress.enabled -}}
|
||||
{{- $fullName := include "deconz.fullname" . -}}
|
||||
{{- $ingressPath := .Values.ingress.path -}}
|
||||
{{- $svcPort := .Values.service.httpPort -}}
|
||||
{{- if semverCompare ">=1.14-0" .Capabilities.KubeVersion.GitVersion -}}
|
||||
apiVersion: networking.k8s.io/v1beta1
|
||||
{{- else -}}
|
||||
apiVersion: extensions/v1beta1
|
||||
{{- end }}
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: {{ $fullName }}
|
||||
labels:
|
||||
{{- include "deconz.labels" . | nindent 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: {{ .host | quote }}
|
||||
http:
|
||||
paths:
|
||||
- path: {{ $ingressPath }}
|
||||
backend:
|
||||
serviceName: {{ $fullName }}
|
||||
servicePort: {{ $svcPort }}
|
||||
{{- end }}
|
||||
{{- end }}
|
@ -1,11 +0,0 @@
|
||||
{{- if (include "deconz.createSecret" .) }}
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: {{ template "deconz.fullname" . }}
|
||||
labels:
|
||||
{{- include "deconz.labels" . | nindent 4 }}
|
||||
type: Opaque
|
||||
data:
|
||||
vnc-password: {{ required "You must specify a VNC password when not supplying an existing secret" .Values.vnc.password | b64enc | quote }}
|
||||
{{- end }}
|
@ -1,68 +0,0 @@
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: {{ include "deconz.fullname" . }}
|
||||
labels:
|
||||
{{- include "deconz.labels" . | nindent 4 }}
|
||||
{{- if .Values.service.labels }}
|
||||
{{ toYaml .Values.service.labels | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with .Values.service.annotations }}
|
||||
annotations:
|
||||
{{ toYaml . | nindent 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.externalTrafficPolicy }}
|
||||
externalTrafficPolicy: {{ .Values.service.externalTrafficPolicy }}
|
||||
{{- end }}
|
||||
{{- if .Values.service.loadBalancerSourceRanges }}
|
||||
loadBalancerSourceRanges:
|
||||
{{ toYaml .Values.service.loadBalancerSourceRanges | nindent 4 }}
|
||||
{{- end -}}
|
||||
{{- else }}
|
||||
type: {{ .Values.service.type }}
|
||||
{{- end }}
|
||||
{{- if .Values.service.sessionAffinity }}
|
||||
sessionAffinity: {{ .Values.service.sessionAffinity }}
|
||||
{{- if .Values.service.sessionAffinityConfig }}
|
||||
sessionAffinityConfig:
|
||||
{{ toYaml .Values.service.sessionAffinityConfig | nindent 4 }}
|
||||
{{- end -}}
|
||||
{{- end }}
|
||||
{{- with .Values.service.externalIPs }}
|
||||
externalIPs:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- if .Values.service.publishNotReadyAddresses }}
|
||||
publishNotReadyAddresses: {{ .Values.service.publishNotReadyAddresses }}
|
||||
{{- end }}
|
||||
ports:
|
||||
- port: {{ .Values.service.httpPort }}
|
||||
targetPort: http
|
||||
protocol: TCP
|
||||
name: http
|
||||
{{- if (and (eq .Values.service.type "NodePort") (not (empty .Values.service.nodePort))) }}
|
||||
nodePort: {{.Values.service.nodePort}}
|
||||
{{ end }}
|
||||
- port: {{ .Values.service.websocketPort }}
|
||||
targetPort: websocket
|
||||
protocol: TCP
|
||||
name: websocket
|
||||
{{- if .Values.vnc.enabled }}
|
||||
- port: {{ .Values.service.vncPort }}
|
||||
targetPort: vnc
|
||||
protocol: TCP
|
||||
name: vnc
|
||||
{{- end }}
|
||||
selector:
|
||||
{{- include "deconz.selectorLabels" . | nindent 4 }}
|
@ -1,12 +0,0 @@
|
||||
{{- if .Values.serviceAccount.create -}}
|
||||
apiVersion: v1
|
||||
kind: ServiceAccount
|
||||
metadata:
|
||||
name: {{ include "deconz.serviceAccountName" . }}
|
||||
labels:
|
||||
{{- include "deconz.labels" . | nindent 4 }}
|
||||
{{- with .Values.serviceAccount.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
@ -1,161 +0,0 @@
|
||||
apiVersion: apps/v1
|
||||
kind: StatefulSet
|
||||
metadata:
|
||||
name: {{ include "deconz.fullname" . }}
|
||||
labels:
|
||||
{{- include "deconz.labels" . | nindent 4 }}
|
||||
spec:
|
||||
{{- if not .Values.autoscaling.enabled }}
|
||||
replicas: {{ .Values.replicaCount }}
|
||||
{{- end }}
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "deconz.selectorLabels" . | nindent 6 }}
|
||||
serviceName: {{ include "deconz.name" . }}
|
||||
template:
|
||||
metadata:
|
||||
{{- with .Values.podAnnotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "deconz.selectorLabels" . | nindent 8 }}
|
||||
spec:
|
||||
{{- with .Values.imagePullSecrets }}
|
||||
imagePullSecrets:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
serviceAccountName: {{ include "deconz.serviceAccountName" . }}
|
||||
securityContext:
|
||||
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||
containers:
|
||||
- name: {{ .Chart.Name }}
|
||||
securityContext:
|
||||
{{- toYaml .Values.securityContext | nindent 12 }}
|
||||
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
ports:
|
||||
- name: http
|
||||
containerPort: {{ int .Values.service.httpPort }}
|
||||
protocol: TCP
|
||||
- name: websocket
|
||||
containerPort: {{ int .Values.service.websocketPort }}
|
||||
protocol: TCP
|
||||
{{- if .Values.vnc.enabled }}
|
||||
- name: vnc
|
||||
containerPort: {{ int .Values.service.vncPort }}
|
||||
protocol: TCP
|
||||
{{- end }}
|
||||
env:
|
||||
{{- if .Values.timezone }}
|
||||
- name: TZ
|
||||
value: "{{ .Values.timezone }}"
|
||||
{{- end }}
|
||||
- name: DECONZ_WEB_PORT
|
||||
value: "{{ .Values.service.httpPort }}"
|
||||
- name: DECONZ_WS_PORT
|
||||
value: "{{ .Values.service.websocketPort }}"
|
||||
{{- if .Values.zigbeeDevice.enabled }}
|
||||
- name: DECONZ_DEVICE
|
||||
value: "{{ .Values.zigbeeDevice.hostPath }}"
|
||||
{{- end }}
|
||||
{{- if .Values.vnc.enabled }}
|
||||
- name: DECONZ_VNC_MODE
|
||||
value: "1"
|
||||
- name: DECONZ_VNC_PORT
|
||||
value: "{{ .Values.service.vncPort }}"
|
||||
- name: DECONZ_VNC_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ template "deconz.secretName" . }}
|
||||
key: vnc-password
|
||||
{{- end }}
|
||||
volumeMounts:
|
||||
{{- if .Values.zigbeeDevice.enabled }}
|
||||
- name: zigbee-device
|
||||
mountPath: {{ .Values.zigbeeDevice.hostPath }}
|
||||
{{- end }}
|
||||
- name: config
|
||||
mountPath: /root/.local/share/dresden-elektronik/deCONZ
|
||||
{{- if .Values.persistence.subPath }}
|
||||
subPath: {{ .Values.persistence.subPath }}
|
||||
{{- end }}
|
||||
{{- include "deconz.extraVolumeMounts" . | nindent 12 }}
|
||||
{{- if .Values.probes.liveness.enabled }}
|
||||
livenessProbe:
|
||||
tcpSocket:
|
||||
port: http
|
||||
initialDelaySeconds: {{ .Values.probes.liveness.initialDelaySeconds }}
|
||||
failureThreshold: {{ .Values.probes.liveness.failureThreshold }}
|
||||
timeoutSeconds: {{ .Values.probes.liveness.timeoutSeconds }}
|
||||
{{- end }}
|
||||
{{- if .Values.probes.readiness.enabled }}
|
||||
readinessProbe:
|
||||
tcpSocket:
|
||||
port: http
|
||||
initialDelaySeconds: {{ .Values.probes.readiness.initialDelaySeconds }}
|
||||
failureThreshold: {{ .Values.probes.readiness.failureThreshold }}
|
||||
timeoutSeconds: {{ .Values.probes.readiness.timeoutSeconds }}
|
||||
{{- end }}
|
||||
{{- if .Values.probes.startup.enabled }}
|
||||
startupProbe:
|
||||
tcpSocket:
|
||||
port: http
|
||||
failureThreshold: {{ .Values.probes.startup.failureThreshold }}
|
||||
periodSeconds: {{ .Values.probes.startup.periodSeconds }}
|
||||
{{- end }}
|
||||
resources:
|
||||
{{- toYaml .Values.resources | nindent 12 }}
|
||||
{{- with .Values.nodeSelector }}
|
||||
nodeSelector:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.affinity }}
|
||||
affinity:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.tolerations }}
|
||||
tolerations:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
|
||||
volumes:
|
||||
{{- if .Values.zigbeeDevice.enabled }}
|
||||
- name: zigbee-device
|
||||
hostPath:
|
||||
path: {{ .Values.zigbeeDevice.hostPath }}
|
||||
{{- end }}
|
||||
{{- if not .Values.persistence.enabled }}
|
||||
- name: config
|
||||
emptyDir: {}
|
||||
{{- end }}
|
||||
{{- if and .Values.persistence.enabled .Values.persistence.existingClaim }}
|
||||
- name: config
|
||||
persistentVolumeClaim:
|
||||
claimName: {{ .Values.persistence.existingClaim }}
|
||||
{{- end }}
|
||||
{{- include "deconz.extraVolumes" . | nindent 8 }}
|
||||
|
||||
volumeClaimTemplates:
|
||||
{{- if and .Values.persistence.enabled ( not .Values.persistence.existingClaim ) }}
|
||||
- metadata:
|
||||
name: config
|
||||
labels:
|
||||
{{- include "deconz.labels" . | nindent 10 }}
|
||||
{{- if .Values.persistence.annotations }}
|
||||
annotations:
|
||||
{{- toYaml .Values.persistence.annotations | nindent 10 }}
|
||||
{{- end }}
|
||||
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 | quote }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
@ -1,205 +1,69 @@
|
||||
# Default values for deconz.
|
||||
# This is a YAML-formatted file.
|
||||
# Declare variables to be passed into your templates.
|
||||
|
||||
# -- Number of replicas to scale to
|
||||
replicaCount: 1
|
||||
|
||||
autoscaling:
|
||||
# -- Enables Pod auto-scaling
|
||||
enabled: false
|
||||
# -- Minimum number of replicas to auto-scale to
|
||||
minReplicas: 1
|
||||
# -- Maximum number of replicas to auto-scale to
|
||||
maxReplicas: 1
|
||||
#
|
||||
# IMPORTANT NOTE
|
||||
#
|
||||
# This chart inherits from our common library chart. You can check the default values/options here:
|
||||
# https://github.com/k8s-at-home/library-charts/tree/main/charts/stable/common/values.yaml
|
||||
#
|
||||
|
||||
image:
|
||||
# -- Image repository
|
||||
repository: marthoc/deconz
|
||||
# -- Image pull policy
|
||||
pullPolicy: IfNotPresent
|
||||
# -- Image tag. Possible values listed [here](https://hub.docker.com/r/marthoc/deconz/tags/).
|
||||
tag: "amd64-2.05.80"
|
||||
tag: amd64-2.10.03
|
||||
|
||||
imagePullSecrets: []
|
||||
strategy:
|
||||
type: Recreate
|
||||
|
||||
# -- Specifies the strategy used to replace old Pods by new ones
|
||||
strategyType: Recreate
|
||||
# See https://github.com/marthoc/docker-deconz/blob/master/README.md for more settings for e.g. debug.
|
||||
env:
|
||||
TZ: UTC
|
||||
## Path to mounted device inside the container.
|
||||
# DECONZ_DEVICE: /dev/conbee
|
||||
## Do not set the VNC password here directly - use a Secret, see envValueFrom below.
|
||||
# DECONZ_VNC_PASSWORD: changeme
|
||||
DECONZ_VNC_MODE: 1
|
||||
DECONZ_WEB_PORT: 80
|
||||
DECONZ_WS_PORT: 443
|
||||
DECONZ_VNC_PORT: 5900
|
||||
|
||||
nameOverride: ""
|
||||
fullnameOverride: ""
|
||||
## If VNC is enabled (DECONZ_VNC_MODE) you can change the default password "changeme" using a Secret.
|
||||
# envValueFrom:
|
||||
# DECONZ_VNC_PASSWORD:
|
||||
# secretKeyRef:
|
||||
# name: deconz-vnc-password
|
||||
# key: password
|
||||
|
||||
# -- Timezone the instance should run as, e.g. 'America/New_York'
|
||||
timezone: "UTC"
|
||||
## Privileged context is required to mount devices in container using volumes.
|
||||
# securityContext:
|
||||
# privileged: true
|
||||
|
||||
# Specify the Zigbee device that should be passed through to the deCONZ container
|
||||
zigbeeDevice:
|
||||
# -- Enables passing through a Zigbee device
|
||||
enabled: false
|
||||
# -- HostPath of the Zigbee device that should be passed through
|
||||
hostPath: /dev/ttyUSB1
|
||||
## Path to device on the host.
|
||||
# additionalVolumes:
|
||||
# - name: conbee
|
||||
# hostPath:
|
||||
# path: /dev/serial/by-id/usb-FTDI_FT230X_Basic_UART_00000000-if00-port0
|
||||
|
||||
vnc:
|
||||
# -- Enabled the built-in VNC server to access the application
|
||||
enabled: true
|
||||
## Path to mounted device inside the container.
|
||||
# additionalVolumeMounts:
|
||||
# - name: conbee
|
||||
# mountPath: /dev/conbee
|
||||
|
||||
# -- VNC server password
|
||||
password: changeme
|
||||
# -- Existing Kubernetes secret containing the VNC password
|
||||
existingSecret: ""
|
||||
|
||||
serviceAccount:
|
||||
# -- Specifies whether a service account should be created
|
||||
create: true
|
||||
# -- Annotations to add to the service account
|
||||
annotations: {}
|
||||
# -- The name of the service account to use.
|
||||
# @default: a name is generated using the fullname template
|
||||
name: ""
|
||||
|
||||
# -- Key-value pairs to add as pod annotations
|
||||
podAnnotations: {}
|
||||
|
||||
podSecurityContext: {}
|
||||
# fsGroup: 2000
|
||||
|
||||
securityContext:
|
||||
privileged: true
|
||||
# capabilities:
|
||||
# drop:
|
||||
# - ALL
|
||||
# readOnlyRootFilesystem: true
|
||||
# runAsNonRoot: true
|
||||
# runAsUser: 1000
|
||||
|
||||
persistence:
|
||||
# -- Use persistent volume to store configuration data
|
||||
enabled: false
|
||||
# -- Key-value pairs to add as persistent volume claim annotations
|
||||
annotations: {}
|
||||
## deconz 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)
|
||||
##
|
||||
# -- Type of persistent volume claim
|
||||
# storageClass: "-"
|
||||
|
||||
# -- Use an existing PVC to persist data
|
||||
# existingClaim: deconz-data
|
||||
|
||||
# -- Persistence access mode
|
||||
accessMode: ReadWriteOnce
|
||||
# -- Size of persistent volume claim
|
||||
size: 1Gi
|
||||
# -- Mount a sub dir of the persistent volume
|
||||
# subPath: /configs/deconz
|
||||
|
||||
# -- Optionally add additional Volumes
|
||||
# Volumes will be mounted to the folder specified under mountPath
|
||||
# If no mountPath is set it will be mounted to /mnt/<name>
|
||||
extraVolumes: []
|
||||
# - name: example-name
|
||||
# hostPath:
|
||||
# path: /path/on/host
|
||||
# type: DirectoryOrCreate
|
||||
# mountPath: "/mnt/test"
|
||||
## The node having the dongle attached should be labeled accordingly.
|
||||
# nodeSelector:
|
||||
# feature.node.kubernetes.io/custom-deconz: "true"
|
||||
|
||||
service:
|
||||
# -- Kubernetes service type for the GUI
|
||||
type: ClusterIP
|
||||
clusterIP: ""
|
||||
|
||||
# -- Kubernetes port where the GUI is exposed
|
||||
httpPort: 80
|
||||
# -- Kubernetes port where the websocket is exposed
|
||||
websocketPort: 443
|
||||
# -- Kubernetes port where the VNC server is exposed
|
||||
vncPort: 5900
|
||||
|
||||
# -- Service annotations for the GUI
|
||||
annotations: {}
|
||||
# -- Custom labels
|
||||
labels: {}
|
||||
## Specify the nodePort value for the LoadBalancer and NodePort service types.
|
||||
## ref: https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport
|
||||
# nodePort:
|
||||
# -- List of IP addresses at which the hass-configurator service is available
|
||||
## Ref: https://kubernetes.io/docs/user-guide/services/#external-ips
|
||||
externalIPs: []
|
||||
# -- Loadbalancer IP for the GUI
|
||||
loadBalancerIP: ""
|
||||
# -- List of IP CIDRs allowed access to load balancer (if supported)
|
||||
loadBalancerSourceRanges:
|
||||
# -- Set the externalTrafficPolicy in the Service to either Cluster or Local
|
||||
externalTrafficPolicy: Local
|
||||
port:
|
||||
port: 80
|
||||
additionalPorts:
|
||||
- name: websocket
|
||||
port: 443
|
||||
- name: vnc
|
||||
port: 5900
|
||||
|
||||
ingress:
|
||||
# -- Enables Ingress
|
||||
enabled: false
|
||||
# -- Ingress annotations
|
||||
annotations: {}
|
||||
# kubernetes.io/ingress.class: nginx
|
||||
# kubernetes.io/tls-acme: "true"
|
||||
# -- Custom labels
|
||||
labels: {}
|
||||
# -- Ingress path
|
||||
path: /
|
||||
# -- Ingress accepted hostnames
|
||||
hosts:
|
||||
- host: deconz.local
|
||||
# -- Ingress TLS configuration
|
||||
tls: []
|
||||
# - secretName: deconz-tls
|
||||
# hosts:
|
||||
# - deconz.local
|
||||
|
||||
# -- CPU/Memory resource requests/limits
|
||||
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
|
||||
|
||||
probes:
|
||||
liveness:
|
||||
# -- Enables liveness probe for the Pod
|
||||
enabled: true
|
||||
# -- Specify liveness `initialDelaySeconds` parameter for the Pod
|
||||
initialDelaySeconds: 30
|
||||
# -- Specify liveness `failureThreshold` parameter for the Pod
|
||||
failureThreshold: 5
|
||||
# -- Specify liveness `timeoutSeconds` parameter for the Pod
|
||||
timeoutSeconds: 10
|
||||
readiness:
|
||||
# -- Enables readiness probe for the Pod
|
||||
enabled: true
|
||||
# -- Specify readiness `initialDelaySeconds` parameter for the Pod
|
||||
initialDelaySeconds: 30
|
||||
# -- Specify readiness `failureThreshold` parameter for the Pod
|
||||
failureThreshold: 5
|
||||
# -- Specify readiness `timeoutSeconds` parameter for the Pod
|
||||
startup:
|
||||
# -- Enables startup probe for the Pod
|
||||
persistence:
|
||||
config:
|
||||
enabled: false
|
||||
# -- Specify startup `failureThreshold` parameter for the Pod
|
||||
failureThreshold: 30
|
||||
# -- Specify startup `periodSeconds` parameter for the Pod
|
||||
periodSeconds: 10
|
||||
|
||||
# -- Node labels for pod assignment
|
||||
nodeSelector: {}
|
||||
|
||||
# -- Toleration labels for pod assignment
|
||||
tolerations: []
|
||||
|
||||
# -- Affinity settings for pod assignment
|
||||
affinity: {}
|
||||
mountPath: /root/.local/share/dresden-elektronik/deCONZ
|
||||
|
Loading…
Reference in New Issue
Block a user