From 1b71a5e9023f4aafbb7c463c3defef945b1a9cbb Mon Sep 17 00:00:00 2001 From: mgale456 <55673155+mgale456@users.noreply.github.com> Date: Sun, 2 Mar 2025 20:54:10 +0000 Subject: [PATCH] fix(esphome): Update persistence for correct cache directories (#32763) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit **Description** I figured this out when looking for why my volsync backup was so large for what should be just a couple yaml files. This saves me 1.3GB of S3 storage, but that quantity will vary. Now we're mounting the cache directories that esphome is expecting. If they don't see these directories existing, then they change the location to be inside the config directory so that these things are cached. It looks like we used to have this working, but upstream probably changed the directories at some point. They don't seem to have clear documentation that I could find. I found these directories [in their github](https://github.com/esphome/esphome/blob/dev/docker/docker_entrypoint.sh). ⚒️ Fixes # N/A **⚙️ Type of change** - [ ] ⚙️ Feature/App addition - [x] 🪛 Bugfix - [ ] ⚠️ Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] 🔃 Refactor of current code - [ ] 📜 Documentation Changes **🧪 How Has This Been Tested?** Deployed locally and then updated my devices. It'll have to redownload the packages, but there's no breaking change from what I found. **📃 Notes:** **✔️ 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 - [ ] 📄 I have made changes to the documentation - [ ] 🧪 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 - [x] I made sure the title starts with `feat(chart-name):`, `fix(chart-name):`, `chore(chart-name):`, `docs(chart-name):` or `fix(docs):` _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._ --------- Signed-off-by: mgale456 <55673155+mgale456@users.noreply.github.com> --- charts/stable/esphome/Chart.yaml | 2 +- charts/stable/esphome/values.yaml | 9 +++++++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/charts/stable/esphome/Chart.yaml b/charts/stable/esphome/Chart.yaml index fa6f4d2d33d..fb5dc054de2 100644 --- a/charts/stable/esphome/Chart.yaml +++ b/charts/stable/esphome/Chart.yaml @@ -32,4 +32,4 @@ sources: - https://github.com/truecharts/charts/tree/master/charts/stable/esphome - https://hub.docker.com/r/esphome/esphome type: application -version: 22.0.1 +version: 22.0.2 diff --git a/charts/stable/esphome/values.yaml b/charts/stable/esphome/values.yaml index 2982b36ea3c..440556fbae3 100644 --- a/charts/stable/esphome/values.yaml +++ b/charts/stable/esphome/values.yaml @@ -43,9 +43,14 @@ persistence: config: enabled: true mountPath: /config - platformio: + # caches platformio packages to prevent excess downloads + cache: enabled: true - mountPath: /.platformio + mountPath: /cache + # caches compiled code to not require rebuilds + build: + enabled: true + mountPath: /build portal: open: enabled: true