Fix ota password#34
Merged
Merged
Conversation
10 tasks
Tycorc
added a commit
to Tycorc/AIR-1
that referenced
this pull request
May 18, 2026
Promote the hardcoded `password: "apolloautomation"` literal to a
`${ota_password}` substitution in `Core.yaml`, defaulting to the same value
so existing consumers see no behavior change. Consumers who want a
per-device password can override via `substitutions:` in their device YAML
and stop sharing a fleet-wide credential.
Why
----
Every AIR-1 worldwide currently boots with the same OTA password (introduced
in ApolloAutomation#34, "Fix ota password", to make OTA upgrades work after the prior
no-password attempts in ApolloAutomation#20 / ApolloAutomation#27). Consumers who include this file via
`packages:` cannot override from their device YAML because ESPHome packages
extend list-valued keys (a second `ota: - platform: esphome` block produces
a duplicate-platform validation error) and `ota: !remove` cannot be paired
with a top-level redeclaration in the same YAML doc. Newer Apollo product
configs (MSR-2, MTR-1, PWR-1, TEMP-1, PLT-1, BTN-1, RLY-1, H-1, H-2, PUMP-1)
already avoid the literal — this brings AIR-1 in line.
Backwards compat
----------------
100% — devices that don't set `ota_password` get `apolloautomation` exactly
as today. CI / firmware builds unchanged.
Override example (in a consumer device YAML):
substitutions:
ota_password: !secret living_room_air_1_ota_password
packages:
ApolloAutomation.AIR-1: github://ApolloAutomation/AIR-1/Integrations/ESPHome/AIR-1.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Version:
Adds:
Fixes:
Breaks:
Checks: