NebraLtd / hm-pyhelper

A helper module used across various Nebra repos to reduce redundant features.
https://nebra.io/hmpyhelper
MIT License
8 stars 16 forks source link

feat: allow override of key location and remove old version support #227

Closed shawaj closed 1 year ago

shawaj commented 1 year ago

Issue

How

This is a quick and hacky fix to the issue described here https://github.com/NebraLtd/helium-syncrobit/issues/2#issuecomment-1464944930

The idea is to allow a device level environment variable SWARM_KEY_URI_OVERRIDE in balenaCloud to override the key location in the assigned variant without needing to define a new variant. This is useful for testing new devices or in instances like this Syncrobit one to provide a quick fix until we have implemented a "proper" fix to this issue.

This additionally changes the following:

Screenshots

References

Relates-to: https://github.com/NebraLtd/helium-syncrobit/issues/2 Relates-to: #221 Relates-to: #222

Checklist

sonarcloud[bot] commented 1 year ago

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

vstrong-info commented 1 year ago

Thank you @shawaj Is it as easy as to add this variable to a specific miner in Balena Cloud? What Service does it need to be added to? In this example, I put value of 1 but it may be 0, 1, 2, 3 or 4 - the slot number - and then see which one brings miner online?

image

Thank you in advance.

shawaj commented 1 year ago

Thank you @shawaj Is it as easy as to add this variable to a specific miner in Balena Cloud? What Service does it need to be added to? In this example, I put value of 1 but it may be 0, 1, 2, 3 or 4 - the slot number - and then see which one brings miner online? image Thank you in advance.

No it's not that simple. Also the update hasn't made it into production yet we are still testing it. Once it's there we will document it :-)

vstrong-info commented 1 year ago

@shawaj There are two devices with this issue in my fleet that I shared with you, if you want to test the patch on them. UUID - fc777aa2ee7382a8e13784746e703b6f UUID - 7710b75d7364a77375ec9d6f541ab6a2 Thank you.