From 93538e432d51b30ec77851c145f8387dc0707726 Mon Sep 17 00:00:00 2001 From: sHa Date: Sat, 18 Apr 2026 19:54:58 +0300 Subject: [PATCH] chore: Bump version to 0.1.37-dev for home-assistant-dev and 0.1.23 for home-assistant; update db_url encoding in deployment script --- home-assistant-dev/Chart.yaml | 2 +- home-assistant/Chart.yaml | 2 +- home-assistant/templates/deployment.yaml | 13 ++++++++++++- 3 files changed, 14 insertions(+), 3 deletions(-) diff --git a/home-assistant-dev/Chart.yaml b/home-assistant-dev/Chart.yaml index 16565a8..3fc37b9 100644 --- a/home-assistant-dev/Chart.yaml +++ b/home-assistant-dev/Chart.yaml @@ -4,7 +4,7 @@ description: Home Assistant development build - wraps home-assistant chart with type: application annotations: version-source: dockerhub-dev:homeassistant/home-assistant:^[0-9]+\.[0-9]+\.[0-9]+\.dev[0-9]+$ -version: 0.1.36-dev +version: 0.1.37-dev appVersion: "2026.5.0.dev202604180313" dependencies: - name: home-assistant diff --git a/home-assistant/Chart.yaml b/home-assistant/Chart.yaml index 22f5a35..3c07a37 100644 --- a/home-assistant/Chart.yaml +++ b/home-assistant/Chart.yaml @@ -5,5 +5,5 @@ type: application annotations: version-source: github-release:home-assistant/core version-pattern: "s|^v||" -version: 0.1.22 +version: 0.1.23 appVersion: "2026.4.3" diff --git a/home-assistant/templates/deployment.yaml b/home-assistant/templates/deployment.yaml index 8a4f2b3..9265e6a 100644 --- a/home-assistant/templates/deployment.yaml +++ b/home-assistant/templates/deployment.yaml @@ -109,9 +109,20 @@ spec: - /bin/sh - -c - | + # URL-encode password so special chars (/, @, :, #, ?, %, &, +) don't break the db_url + ENCODED_PW=$(printf '%s' "$HA_POSTGRESQL_PASSWORD" | sed \ + -e 's|%|%25|g' \ + -e 's|/|%2F|g' \ + -e 's|@|%40|g' \ + -e 's|:|%3A|g' \ + -e 's|#|%23|g' \ + -e 's|?|%3F|g' \ + -e 's|&|%26|g' \ + -e 's|+|%2B|g' \ + -e 's| |%20|g') # Build recorder.yaml with postgres connection string printf '%s\n' \ - "db_url: \"postgresql://{{ .Values.postgres.user }}:${HA_POSTGRESQL_PASSWORD}@{{ .Values.postgres.host }}:{{ .Values.postgres.port }}/{{ .Values.postgres.db }}\"" \ + "db_url: \"postgresql://{{ .Values.postgres.user }}:${ENCODED_PW}@{{ .Values.postgres.host }}:{{ .Values.postgres.port }}/{{ .Values.postgres.db }}\"" \ "db_retry_wait: 15" \ "auto_purge: true" \ "purge_keep_days: {{ .Values.postgres.purgeKeepDays | default 30 }}" \