I'd like to be able to trigger a script when a Raspberry Pi receives a push notification, like a poor mans CI/CD pipeline can it be done?
My goal is to automatically pull code from a git repo whenever a push notification is received, but the pi will be on a typical home network. I was thinking of setting a webhook from a git server to trigger a push notification.
I would like to take advantage of the convenience of a push notifications:
- no port forwarding of dyn-DNS to configure (would be needed if using webhook directly)
- Can have device offline a few days and still get the notification
- No webserver to configure to receive the webhook (aside from whatever push service would be needed)
I am also assuming that listening for a push notification is more efficient than constantly polling a server. Should I be looking at a different publisher-subscriber system?
It seems like there are no push providers for Linux.