Is it possible to update environment variables via the SDK without the containers restarting? I am using one to keep track of some variables on the device itself and store them in case of restarts.
Hi Will, this is not possible with env vars however you might be able to achieve something similar using tags? The documentation for tags can be found here: https://www.balena.io/docs/learn/manage/filters-tags/#device-tags
Hey there! Did tags work for you? What is the use case otherwise? We can probably help more if we know what you’re trying to accomplish!
Hi, yes tags will work for my use case. I am just testing, having updated the code.
I have tried using them and there seems to be some odd behaviour. Currently I have seen a tag value updated from one device update another device. Are these tags unique per device? I.e. if I have MY_TAG 1 on one device, can I have MY_TAG 2 on another? I am using Python resin-sdk 4.7.0. Are there known issues with that version?
The method I am calling is resin.models.tag.device.set
Updating to the latest SDK seems to have fixed that problem (7.1.0), so all working now, thanks.