I love the balenaSound project, but have a question about shutdown. I believe a useful feature would be the ability to shut the device down by itself, either after not playing audio for a preset time (configurable in the device variables section), or at a certain time of the day, like 4.00 am or something - again, configurable.
My Pi 3 has been through a few SD Cards where there has been a power failure, and this seems to have taken the card down - at least I assume that’s what’s going on. Shutting down this way will switch the device off gracefully, and save energy as well.
If you have a multi docker environment, and define it via a docker-compose yaml file, you should be able interact with the supervisor via the host APIvia the local docker network.
See https://www.balena.io/docs/learn/develop/runtime/ for the environment variables you can use ( BALENA_SUPERVISOR_ADDRESS seems convenient). Be sure to also set the label io.balena.features.supervisor-api: '1' on the container where you want to implement the shutdown timer.