So you have the following options for running balenaOS;
- use balenaOS standalone, without associating it to a balenaCloud application
- use balenaOS in tandem with a balenaCloud application
If you use it as a standalone, then you can change the values in config.txt
and they should persist.
If you use it in tandem with a balenaCloud application then the supervisor will ensure that the device configuration state matches whatever is held in the cloud. So if you change the config.txt
file then the supervisor will overwrite those changes.
If you would like to keep your configuration in your code repo, then you could add a container to your compose file which has access to the API and sets the device_config_variables
for the specific device it is running on. Details on accessing the API can be found here:
- label to expose API key: https://www.balena.io/docs/learn/develop/multicontainer/#labels
- calling the API: https://www.balena.io/docs/reference/api/overview/
- config related resource: https://www.balena.io/docs/reference/api/resources/device_config_variable/
I hope you find this useful.