4. Updates¶
4.1 The box software¶
A box installs new versions by itself: with a library from the library, without one from GitHub. A new version starts the next time the box is switched on, on probation. If it does not work – it does not start, or it fails its first seconds – the box starts the version before after a few seconds by itself. A version stays on probation until a tag was placed and an album played because of it.
- Without a library the box looks once a day for a new release and installs it after a waiting time of three days; a correction in that time replaces it before any box got it.
- With a library a box gets a new version at once. In the tab "Versions" of the library every version has a state:
use(boxes install it by themselves),manual(by hand only),dontuse(every box leaves it at once). - The update mode of a box – "automatic", "by hand only" ("ask" without a library) or "off" – is set on its page, tab "System", section "Version" (manual, section 13.4).
On the box the same is a command. It runs as the user of the box, never with sudo:
tinyjukebox-slot status # the versions on the box, the one that runs, the mode, the last switches
tinyjukebox-slot check # what the library offers - without a library: GitHub
tinyjukebox-slot update --now # the newest permitted version, at once
tinyjukebox-slot update 0.45.0 # exactly this version
tinyjukebox-slot mode manual # automatic, manual or off
Every call: library.md, section 6.8.
4.2 Going back to the version before¶
A step back takes effect at once, also while something is playing. No box installs the version that was left by itself any more.
| Way | For |
|---|---|
| page of the box, tab "System", "Back to the previous version" | this box |
tinyjukebox-slot revert on the box |
this box |
an empty file tinyjukebox-revert on the boot partition of the SD card (bootfs on the PC) |
this box, without network: the next start goes back and writes tinyjukebox-ergebnis.txt in its place |
page of the library, tab "Versions": the version to dontuse |
all boxes |
revert switches to the other slot, whatever it holds. After a failed probation that may be the version that failed:
look first with tinyjukebox-slot status. If no version starts any more, the box is in emergency mode
(manual, section 13.4;
library.md, section 6.10).
4.3 The library¶
The library never updates itself.
- On the NAS: install the newer package the same way, Package Center, "Manual Install" – without the dialog; the
data stays. From a clone of the repository on the PC,
./update_library.sh <nas>does it: it fetches the package of the newest release and asks for user and password of DSM, which it does not store – or takes NAS, user and password from the vault of the playbook (library.md, section 3.7). - In Docker: its page shows that a newer version exists. Pull the newer image and start the container again;
with compose
docker compose pull, thendocker compose up -d. - On a PC:
pip install --upgrade tinyjukebox, then start the library again.
A library that is older than the version of a box makes the box stop: the LED changes between red, white, magenta and yellow, and the box plays nothing. Then update the library first.
4.4 The operating system of the box¶
The box never updates its operating system by itself. By hand, now and then:
sudo apt update && sudo apt full-upgrade
After an upgrade of Python, ALSA or BlueZ, run the installer line again (section 2.3) – on a box of the playbook
./update_box.sh – and check sound, buttons and headset. A version that needs a newer setup of the system says so on
the page of the box: then the installer has to run again as well.