| 8 Jan 2025 |
laurynasp | what is your setup for managing / flashing the devices?
do you flash from nix develop? | 01:52:26 |
@hexa:lossy.network | that error is printed by pathlib | 01:52:55 |
@hexa:lossy.network | I have a devshell, yeah | 01:53:07 |
@hexa:lossy.network | and when I feel like it (mostly on updates) I run the dashboard and let it update everything | 01:53:23 |
laurynasp | Do you mean, this stems from the ESPhome python code opinion symlinks vs regular files | 01:53:31 |
@hexa:lossy.network | please don't use threads for everything I say | 01:54:57 |
@hexa:lossy.network | nobody else is here, so we can just talk here | 01:55:10 |
@hexa:lossy.network | the context is super clear 😄 | 01:55:20 |
@hexa:lossy.network | esphome somewhere uses path.relative_to("/var/lib/private/esphome") | 01:55:39 |
laurynasp | Yeah, I was thinking that if I was to go forward with ESPHome dashboard (services.esphome), then I guess my best option would be PR to add an option for systemd services pre-Exec, where I could cp a file across. Would feel hacky.
However, my ultimate goal is to automate managament of esp32 devices, so if there is better way, then i would go with that | 01:55:42 |
@hexa:lossy.network | and path is not inside that directory | 01:55:46 |
@hexa:lossy.network | https://github.com/search?q=repo%3Aesphome%2Fesphome%20relative_to&type=code | 01:58:06 |
@hexa:lossy.network | probably in dashboard_settings.py | 01:58:15 |
@hexa:lossy.network |
Raises ValueError if not relative to ESPHome config folder
| 01:58:23 |
@hexa:lossy.network | the esphome service to me feels like a stateful way of dealing with configs | 01:59:04 |
@hexa:lossy.network | you can certainly instruct your secrets management to install the files into /var/lib/private/esphome though | 01:59:26 |
@hexa:lossy.network | just a symlink won't do | 01:59:31 |
laurynasp | just doing a test run to check that ESPhome is happy with secrets.yaml being outside the config dir | 02:16:33 |
@hexa:lossy.network | good luck 😄 | 02:18:18 |
@hexa:lossy.network | if not you could probably file an issue upstream or submit a patch | 02:18:31 |
laurynasp | Did you say you run dashboard from dev shell? is you config for that public?
P.s. I ended up using esphome service, because it worked, and I was not able to find any easy / detailed tutorial on how to flash esp32 devices.
The simplest alternative i found (but haven't tested) on https://nixos.wiki/wiki/ESP-IDF is
nix --experimental-features 'nix-command flakes' develop github:mirrexagon/nixpkgs-esp-dev#esp32-idf
Is your set up similar?
| 02:21:42 |
laurynasp | * Did you say you run dashboard from dev shell? is your config for that public?
P.s. I ended up using esphome service, because it worked, and I was not able to find any other easy / detailed tutorial on how to flash esp32 devices on nixos / nix.
The simplest alternative i found (but haven't tested) on https://nixos.wiki/wiki/ESP-IDF is
nix --experimental-features 'nix-command flakes' develop github:mirrexagon/nixpkgs-esp-dev#esp32-idf
Is your set up similar?
| 02:22:57 |
@hexa:lossy.network | no, there is plain secrets in there ;D | 02:23:23 |
@hexa:lossy.network | * no, there is plain secrets in there 😄 | 02:23:24 |
@hexa:lossy.network | although only for my iot wlan | 02:23:37 |
@hexa:lossy.network | which probably isn't much use | 02:23:42 |
@hexa:lossy.network | esphome is the most declarative and simple way to maintain a bunch of esp8266/32 devices | 02:24:25 |
@hexa:lossy.network | ESP-IDF is the framework by espressif | 02:24:40 |
@hexa:lossy.network | you'll need to be somewhat fluent in C with that | 02:25:09 |
laurynasp | I am glad you saved me from a rabbit hole! | 02:25:15 |