Add DISCOVERY_DIAGNOSTIC environment variable - #34
Open
jcsanyi wants to merge 1 commit into
Open
Conversation
Theengs Gateway can mark battery, voltage and RSSI entities with Home Assistant's diagnostic entity category, but start.sh regenerates theengsgw.conf from a fixed set of keys on every start, so the option was unreachable from Docker except through the PARAMS passthrough. Validated like the other boolean variables and defaulting to false, matching the gateway's own default. The key is ignored by gateway versions that don't know it, so this is inert until the pinned version supports the option.
3 tasks
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.
DISCOVERY_DIAGNOSTICenvironment variable tostart.sh, validated like the other booleansexamples/docker-compose.ymlThis sets
discovery_diagnostic, the option added in theengs/gateway#325, which marks battery, voltage and RSSI entities with Home Assistant's diagnostic entity category so they group separately from a device's main readings. Without this there's no way to reach it from Docker except the undocumentedPARAMSpassthrough.It defaults to
false, matching the gateway's own default for minimal disruption to existing installations. The documented examples set it totrueon purpose, to encourage usage of the option on new installs.Nothing breaks if this is released early, but it does document an option that won't actually exist until a gateway version that supports
discovery_diagnosticis released. Should be merged around the same time that theTheengsGateway==1.7.5pin is bumped to a version with this support.[tested on amd64 against a build of theengs/gateway#325 with start.sh pulled in from this branch: works as expected with the variable unset, set to an invalid value, and correctly set to true/false]