0b726419d4
**Description** Part 1 of the migration to new common on the stable train. This basically breaks most/all charts requiring a reinstall on SCALE as well. Helm users shouldn't need a reinstall but could migrate their values.yaml modification manually besides backing-up and porting the databases. There be Dragons basically, as we obviously cannot 100% go over each-and-every single app in the stable train like we did in the enterprise train. **⚙️ Type of change** - [x] ⚙️ Feature/App addition - [x] 🪛 Bugfix - [x] ⚠️ Breaking change (fix or feature that would cause existing functionality to not work as expected) - [x] 🔃 Refactor of current code **🧪 How Has This Been Tested?** Via CI and manually validation in a lot of cases where the CI did not correctly check things. Additional catalog item creation tooling for local testing has been added as well. **📃 Notes:** There will be issues in the future but we should get as much working well as we can. **✔️ Checklist:** - [x] ⚖️ My code follows the style guidelines of this project - [x] 👀 I have performed a self-review of my own code - [x] #️⃣ I have commented my code, particularly in hard-to-understand areas - [x] 📄 I have made corresponding changes to the documentation - [x] ⚠️ My changes generate no new warnings - [x] 🧪 I have added tests to this description that prove my fix is effective or that my feature works - [x] ⬆️ I increased versions for any altered app according to semantic versioning **➕ App addition** If this PR is an app addition please make sure you have done the following. - [ ] 🪞 I have opened a PR on [truecharts/containers](https://github.com/truecharts/containers) adding the container to TrueCharts mirror repo. - [ ] 🖼️ I have added an icon in the Chart's root directory called `icon.png` --- _Please don't blindly check all the boxes. Read them and only check those that apply. Those checkboxes are there for the reviewer to see what is this all about and the status of this PR with a quick glance._
98 lines
5.0 KiB
YAML
98 lines
5.0 KiB
YAML
image:
|
|
repository: tccr.io/truecharts/zigbee2mqtt
|
|
tag: 1.30.1@sha256:173e86807c6fe7ceef3c0716a539dee66d87bbf84303105d860a15a46b5df94f
|
|
pullPolicy: IfNotPresent
|
|
service:
|
|
main:
|
|
ports:
|
|
main:
|
|
port: 10103
|
|
persistence:
|
|
data:
|
|
enabled: true
|
|
mountPath: "/data"
|
|
targetSelectAll: true
|
|
|
|
portal:
|
|
open:
|
|
enabled: true
|
|
securityContext:
|
|
container:
|
|
runAsNonRoot: false
|
|
readOnlyRootFilesystem: false
|
|
runAsUser: 0
|
|
runAsGroup: 0
|
|
workload:
|
|
main:
|
|
podSpec:
|
|
initContainers:
|
|
init-config:
|
|
enabled: true
|
|
imageSelector: image
|
|
type: init
|
|
env:
|
|
ZIGBEE2MQTT_CONFIG_FRONTEND_PORT: "{{ .Values.service.main.ports.main.port }}"
|
|
ZIGBEE2MQTT_CONFIG_EXPIRIMENTAL_NEW_API: "{{ .Values.workload.main.podSpec.containers.main.env.ZIGBEE2MQTT_CONFIG_EXPIRIMENTAL_NEW_API }}"
|
|
ZIGBEE2MQTT_CONFIG_PERMIT_JOIN: "{{ .Values.workload.main.podSpec.containers.main.env.ZIGBEE2MQTT_CONFIG_PERMIT_JOIN }}"
|
|
ZIGBEE2MQTT_CONFIG_MQTT_SERVER: "{{ .Values.workload.main.podSpec.containers.main.env.ZIGBEE2MQTT_CONFIG_MQTT_SERVER }}"
|
|
ZIGBEE2MQTT_CONFIG_MQTT_USER: "{{ .Values.secret.ZIGBEE2MQTT_CONFIG_MQTT_USER }}"
|
|
ZIGBEE2MQTT_CONFIG_MQTT_PASSWORD: "{{ .Values.secret.ZIGBEE2MQTT_CONFIG_MQTT_PASSWORD }}"
|
|
ZIGBEE2MQTT_CONFIG_MQTT_BASE_TOPIC: "{{ .Values.workload.main.podSpec.containers.main.env.ZIGBEE2MQTT_CONFIG_MQTT_BASE_TOPIC }}"
|
|
ZIGBEE2MQTT_CONFIG_SERIAL_PORT: "{{ .Values.workload.main.podSpec.containers.main.env.ZIGBEE2MQTT_CONFIG_SERIAL_PORT }}"
|
|
ZIGBEE2MQTT_CONFIG_SERIAL_ADAPTER: "{{ .Values.workload.main.podSpec.containers.main.env.ZIGBEE2MQTT_CONFIG_SERIAL_ADAPTER }}"
|
|
USE_CUSTOM_CONFIG_FILE: "{{ .Values.workload.main.podSpec.containers.main.env.USE_CUSTOM_CONFIG_FILE }}"
|
|
command: ["/bin/sh", "-c"]
|
|
args:
|
|
- >
|
|
if [ -f /data/configuration.yaml ] || [ ${USE_CUSTOM_CONFIG_FILE} == true ]; then
|
|
|
|
echo "Initial configuration exists or User selected to use custom configuration file. Skipping...";
|
|
else
|
|
|
|
echo "Creating initial configuration";
|
|
touch /data/configuration.yaml;
|
|
echo "# Configuration bellow will be always be overridden" >> /data/configuration.yaml;
|
|
echo "# from environment settings on the Scale Apps UI." >> /data/configuration.yaml;
|
|
echo "# You however will not see this values change in the file." >> /data/configuration.yaml;
|
|
echo "# It's a generated file based on the values provided on initial install." >> /data/configuration.yaml;
|
|
echo "##########################################################" >> /data/configuration.yaml;
|
|
echo "experimental:" >> /data/configuration.yaml;
|
|
echo " new_api: $ZIGBEE2MQTT_CONFIG_EXPIRIMENTAL_NEW_API" >> /data/configuration.yaml;
|
|
echo "frontend:" >> /data/configuration.yaml;
|
|
echo " port: $ZIGBEE2MQTT_CONFIG_FRONTEND_PORT" >> /data/configuration.yaml;
|
|
echo "permit_join: $ZIGBEE2MQTT_CONFIG_PERMIT_JOIN" >> /data/configuration.yaml;
|
|
echo "mqtt:" >> /data/configuration.yaml;
|
|
echo " server: $ZIGBEE2MQTT_CONFIG_MQTT_SERVER" >> /data/configuration.yaml;
|
|
echo " base_topic: $ZIGBEE2MQTT_CONFIG_MQTT_BASE_TOPIC" >> /data/configuration.yaml;
|
|
if [ ! -z "$ZIGBEE2MQTT_CONFIG_MQTT_USER" ];
|
|
then
|
|
echo " user: $ZIGBEE2MQTT_CONFIG_MQTT_USER" >> /data/configuration.yaml;
|
|
fi;
|
|
if [ ! -z "$ZIGBEE2MQTT_CONFIG_MQTT_PASSWORD" ];
|
|
then
|
|
echo " password: $ZIGBEE2MQTT_CONFIG_MQTT_PASSWORD" >> /data/configuration.yaml;
|
|
fi;
|
|
echo "serial:" >> /data/configuration.yaml;
|
|
echo " port: $ZIGBEE2MQTT_CONFIG_SERIAL_PORT" >> /data/configuration.yaml;
|
|
echo " adapter: $ZIGBEE2MQTT_CONFIG_SERIAL_ADAPTER" >> /data/configuration.yaml;
|
|
echo "##########################################################" >> /data/configuration.yaml;
|
|
echo 'Initial configuration file created at "/data/configuration.yaml"';
|
|
fi;
|
|
containers:
|
|
main:
|
|
env:
|
|
ZIGBEE2MQTT_DATA: "/data"
|
|
ZIGBEE2MQTT_CONFIG_FRONTEND_PORT: "{{ .Values.service.main.ports.main.port }}"
|
|
# User defined
|
|
USE_CUSTOM_CONFIG_FILE: false
|
|
# This values are required for the autogenerated file to work.
|
|
# ZIGBEE2MQTT_CONFIG_EXPIRIMENTAL_NEW_API: true
|
|
# ZIGBEE2MQTT_CONFIG_PERMIT_JOIN: true
|
|
# ZIGBEE2MQTT_CONFIG_MQTT_SERVER: "mqtt://localhost"
|
|
# ZIGBEE2MQTT_CONFIG_MQTT_BASE_TOPIC: "zigbee2mqtt"
|
|
# ZIGBEE2MQTT_CONFIG_SERIAL_PORT: "/dev/ttyUSB0"
|
|
# ZIGBEE2MQTT_CONFIG_SERIAL_ADAPTER: "auto"
|
|
|
|
ZIGBEE2MQTT_CONFIG_MQTT_USER: ""
|
|
ZIGBEE2MQTT_CONFIG_MQTT_PASSWORD: ""
|