Alerts feature request

Not sure where to put this, but I was thinking an alerts feature within balena cloud would be VERY useful.

Here’s my immediate reason. When deploying slower devices like a Pi Zero it can take a long while for the device to boot and connect for the first time. It would be really nice to have an alert that I could set to email me when the device is finally online rather than waiting & staring at a blank device list within the UI.

Also could be useful to know when a device goes offline.

I’m certain this could be done with the API, but it would be nice to have an out of the box alerting feature.

1 Like

Hi there – thanks very much for getting in touch with us. We’ve added this feature request to our internal tracking, and will be considering the best way to add it to the product. Please let us know if there’s anything else you’d like to see as well!

All the best,
Hugh

1 Like

I would also like this as was searching for it after creating a log filter. being able to send an alert/webhook would open up some interesting possibilities. My use case is an alert causing a smart plug to switch on a AMP my RPI is connected to for balenasound

  • Interesting - do you mean you would like to set some filter to the logs, and whenever there’s a new entry to that filter you want an alert over a webhook. Did I get that right?
  • There’s a feature request for something similar to this, and I’ve added your interest to it as well. We’ll update this thread if and when we have something like this implemented.

yes basically yes. (allows alerts ala New Relic Synthetics, or Sumo/Splunk) to some endpoint so an action can be performed

After some investigation into how to grab logs from the HostOS I think I can add a bash/python script of some kind to pipe the output of this:

journalctl -f --all --no-pager

looking for ‘playing’ log output from spotify/airplay/bluetooth/upnp

and hit IFTTT API or similar to trigger my action (tell Alexa to power up my smart plug)

interesting

C

The other thing that you can do is use the supervisor API to stream the logs from the application containers - see more about it here : https://www.balena.io/docs/reference/supervisor/supervisor-api/#stream-local-mode-application-logs-from-device

3 Likes

Thanks for the tip @anujdeshpande that stream could be very useful.

I think there is another feature request somewhere for a state change webhook, as well.

We are tracking some internal issues that will offer webhooks for various events such as config changes, device state and update status/info. No clear timeline on it right now.

2 Likes

did anything ever come of this?

Hi,

We are also interested in this feature. We would like to run a webhook when a device CPU exceeds a certain threshold, or the disk is full. Are you able to implement that? Another option would be to have support for more monitoring tools (besides Datalog), like New Relic.

Thanks,
Tiago

2 Likes

Hello @tiagoinacio welcome to the balena community!

I think it’s a possibility to build a balena Block that is sending HTTP requests to the supervisor to ask if everything is working well.

Would you like to try it?