Distribution updates - malvira/bramble GitHub Wiki
Bramble can manage automatic distribution updates through Lowpan.com for the BR12 distribution.
This feature is enabled if Bramble detects that it is running on a BR12 and Arch through some TDB mechanism.
If this is the case, then release conf files exist which describe where to check for automatic updates.
The release conf file is a JSON such as:
{
"release": {
"distro": "br12",
"release": "r0",
"url": "distro.lowpan.com"
}
}
Bramble will check for updates at http://{{release.url}}/{{release.distro}}/{{release.release}}/updates.json For the example release conf above, the URL would be:
http://distro.lowpan.com/br12/r0/updates.json
updates.json
contains instructions about how to perform the update. These details are release specific.
Performing the update
If an update is available, then the "Apply Updates" button is activated. Pressing this button indicates to the server side of bramble to perform the update by posting updates.json
to settings/distro/update
.
{
"name": "br12",
"release": "next",
"script": "http://distro.lowpan.com/distro/br12/next/update.py"
}
Bramble tries to GET the update script indicated in updates.json
(in this example http://distro.lowpan.com/distro/br12/next/update.py). If it gets the script is stores it as /var/cache/bradmin/distro-update-script
and runs it. Bramble then updates the release config with the new name and release.