Schedule Nightly Reboots

Hi! I’m using Balena Cloud to manage a deployment of RPi 3s across three locations running Screenly OSE. At one location, I’ll randomly have a device go offline on my dashboard. Our IT manager can see in the network logs that the device is on the network, and the display is still running its playlist, but I can no longer remotely access it. The solution is a manual reboot, but these things are mounted in a tricky spot, making this a bit inconvenient for the staff on site.

Is there a way to schedule nightly reboots within Balena Cloud? Not only would this correct such an issue, but it would also help with general stability for all the displays we run. Also, Linux is not my first language, so go gentle on me. :wink:

Thanks!

Hello AJ,

You could use the supervisor API to reboot the device:
https://www.balena.io/docs/reference/supervisor/supervisor-api/#post-v1-reboot

You could make this call within your device from a different container (if your app’s type is Microservices or Starter) or from a different process in the same container. Or it’s certainly possible to make this API call from a separate machine.

Having said these, let us know if you need our help troubleshooting the root problem that requires such nightly reboot. From your description, it sounds like that device loses connection to balencaCloud’s VPN for some reason. You need VPN connection for remote access.

Cheers…

For devices that need a hard power cycle to start working again. We use wifi plugs. Super hack.
https://www.kasasmart.com/us/products/smart-plugs/kasa-smart-wifi-plug-lite-hs103p2