Looking into Progressive Web Apps
It turned out that running my own XMPP server was not the smoothest experience when it comes to getting push notifications on my phone.
On one hand, installing and configuring Prosody was actually a breath of fresh air compared to setting up a Matrix server. It was as easy as running sudo apt install prosody
and editing a few lines in the /etc/prosody/prosody.cfg.lua
file.
Seeing the Lua file reminded me to take a deeper look into Lua, something I’ve been curious about for quite a while. That led to another rabbit hole from which a new project spawned, but that’s a topic for another post.
On the other, dealing with the client applications for XMPP, missing notifications due to synchornization with the server, and in general not being able to do anything about the client was a bit frustrating.
Recently DHH and 37signals open‑sourced Campfire. It was on my list of things to try out and it coincided quite well with my need for a simple, self‑hosted chat application that can send me push notifications. The setup was easy, but the UI was a bit flaky, but that gave me an idea.
Campfire is a PWA, and the notifications, as far as I understand, are delivered through the Push API and the Notifications API. So instead of me trying to debug and modify Campfire, I will just look into making my own simple PWA to hook my weather bot into and see how it goes. This eliminates the need to run any native apps that I do not have control over and keeps things much simpler. It's also a fantastic opportunity for learning!