Files
shaandClaude Sonnet 5 c4ae24dd02 Add eWeLink CUBE OS chart
Bridges eWeLink Wi-Fi and Zigbee devices into Matter (HomeKit,
Google Home, Alexa, Home Assistant). Uses a Multus macvlan interface
instead of hostNetwork, since CUBE OS hardcodes host port 80/1883
which would otherwise collide with Traefik on the same node.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BU7b2w8XZPbD7uXRfjKwcm
2026-09-07 01:06:06 +03:00

83 lines
2.6 KiB
YAML

apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ .Release.Name }}
labels:
app.kubernetes.io/name: {{ .Chart.Name }}
app.kubernetes.io/instance: {{ .Release.Name }}
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
spec:
replicas: 1
strategy:
type: Recreate
selector:
matchLabels:
app: {{ .Release.Name }}
template:
metadata:
labels:
app: {{ .Release.Name }}
{{- if .Values.macvlan.enabled }}
annotations:
k8s.v1.cni.cncf.io/networks: '[{"name":"{{ .Values.macvlan.networkName }}","ips":["{{ required "macvlan.ip is required" .Values.macvlan.ip }}/{{ .Values.macvlan.prefixLength }}"]}]'
{{- end }}
spec:
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.affinity }}
affinity:
{{- toYaml . | nindent 8 }}
{{- end }}
containers:
- name: {{ .Chart.Name }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
securityContext:
privileged: {{ .Values.security.privileged }}
env:
- name: TZ
value: {{ .Values.timezone | quote }}
ports:
- name: http
containerPort: 80
protocol: TCP
- name: mqtt
containerPort: 1883
protocol: TCP
resources:
{{- toYaml .Values.resources | nindent 12 }}
volumeMounts:
- name: data
mountPath: /data
{{- if .Values.dbus.enabled }}
- name: dbus
mountPath: /host_dbus/system_bus_socket
readOnly: true
{{- end }}
{{- if .Values.zigbee.enabled }}
- name: zigbee-dongle
mountPath: {{ .Values.zigbee.devicePath }}
{{- end }}
volumes:
- name: data
persistentVolumeClaim:
claimName: {{ .Values.persistence.existingClaim | default (printf "%s-data" .Release.Name) }}
{{- if .Values.dbus.enabled }}
- name: dbus
hostPath:
path: /run/dbus/system_bus_socket
type: Socket
{{- end }}
{{- if .Values.zigbee.enabled }}
- name: zigbee-dongle
hostPath:
path: {{ .Values.zigbee.devicePath }}
type: CharDevice
{{- end }}