Bridging This Blog into the Fediverse with Bridgy Fed
I have been using the Fediverse more and more and decided I would like to make this blog part of it. Why? Well, if I am honest it is “because I can” so I went down the rabbit hole of how to make that happen.
It turns out that what I actually wanted was for this site to be a fediverse account in its own right. It would be something people on Mastodon can follow, reply to and boost directly, with the real post living here the whole time. That is a different problem to solve, and the tool for it is Bridgy Fed.
openGym on Kubernetes
For a while I have been looking for a good self-hosted solution for recording my gym sessions. I have a good solution for tracking my cardio sessions (cycling and running mainly) in Endurain, but never for strength training. I have tried a few:
- wger - a good solution, but the UI is a bit dated and it is also geared towards managing a gym rather than a single user.
- Wingfit - also good, but I just did not click with it. Shame, because the developer is from Brittany, which is my adopted home.
- A multitude of different open source Android apps. These all had UX issues and no syncing, so kind of sucked for me.
As a result, I stayed on Strong for much longer than I would have liked.
Opencode and Visual Analysis
I have been using Opencode to work on a couple of ESP32 projects that are of a more “Maker” nature. At some point I realised that I also needed a case and decided to set Opencode loose on it too.
The workflow for this is simple, but awful:
- describe the case in words
- Opencode (using Big Pickle because FREE) creates an OpenSCAD model
- Render the OpenSCAD model
- Wonder what the hell Opencode was thinking
- GOTO 10 and the cycle continues ad nauseam
What you need is some way for Opencode to verify what it has done and iterate.
I use Opencode with oh-my-openagent which, amongst other things, gives you sub-agents. One of those sub-agents is the “multimodal-looker” which can look at images and provide feedback. I thought I could use this to create a feedback loop for Opencode to verify its own work.
The idea is simple:
- I describe the case in words
- Opencode creates an OpenSCAD model and renders it
- The multimodal-looker “looks” at the rendered image and provides feedback.
- Opencode uses the feedback to iterate on the design
This is great in theory, but falls apart in practice because Big Pickle does not support visual analysis. So, I needed to do two things:
- route visual analysis to another model
- decide which model to use
I decided to use gemma4:e4b because it has the feature I need and is not only free, but I can run it on my own hardware with reasonable performance.
The performance isn’t interactive-speed, but it is good enough that I can set the agent working while I go away and have a meal or chat with my wife for a bit.
Running Hugging Face models on Ollama
As part of my continuing experiments with AI, I regularly use models from Hugging Face. Ollama makes it really easy to run models locally from their own repo, but sometimes they do not have exactly the model one wants.
Why Use Hugging Face
While Ollama has its own curated repository of models you can use, Hugging Face has kind of become the community default. The choice is much larger and opens up possibilities that are not available if you just stick with Ollama’s own repository. For mainstream models, there maybe quantization that are not available in Ollama’s own repo. There are plenty of fine-tunes of more mainstream models that are only on Hugging Face.
N8n with Ollama on Kubernetes
Once again I have a new tool I have been playing with, once again AI related. One of the tools I have been using is n8n which is a workflow automation platform. It enables us to integrate multiple applications and services through a visual interface. While it is very much an enterprise solution, it is FLOSS and we can deploy it at home, albeit with some caveats and/or workarounds.
One of the really powerful parts of N8n is that we can integrate with various AI platforms, including all the usual suspects: Claude, ChatGPT, etc. Of course I want to keep things local, which N8n caters for with Ollama.
My initial plan is to do react to an alert from Prometheus and give myself some advise about what to do. The plan is pretty simple and adds to my existing Alerts through Telegram:
Alertmanager
├─► Telegram (existing)
└─► n8n webhook
└─ Python Code (build prompt)
└─ HTTP Request → Ollama
└─ Telegram (post analysis)
- Alertmanager fires a webhook to n8n alongside the existing Telegram notification
- n8n builds a prompt from the alert payload and sends it to Ollama
- Ollama analyses the alert and suggests a fix
- n8n posts the analysis back to Telegram
So let’s start by getting it installed
Installing n8n on Kubernetes
There is no official Helm chart, but the community-maintained chart is excellent and well maintained. To get started we need:
- Redis which we will install with Helm
- PostgreSQL for which we will use Cloudnative-PG
- Some storage (I will use Longhorn as usual)
- n8n itself
Dependencies first
Before we can do anything else, let’s get Redis and PostgreSQL setup. The simplest is Redis using the Cloud Pirates Helm Chart:
helm --namespace n8n install n8n-redis \
oci://registry-1.docker.io/cloudpirates/redis \
-f redis-values.yaml
The contents of redis-values.yaml is very simple:
architecture: standalone
master:
persistence:
enabled: true
auth:
enabled: true
That will create a secret (n8n-redis) to we use later.
Alertmanager Telegram integration in Kubernetes
Some more Prometheus content now, this time I will share how I do my alerting. I want to to receive alerts from my homelab, but I do not care about them too much. If something goes wrong at 2am, I really could not careless. In fact, there is no reason why I would want to be disturbed by them under any circumstances.
To that end, the whole point of my homelab is that I can use the same techniques I would use in production. To that end, I do want to set up alerts, I just want to keep them as non-intrusive as possible. A good solution for my alerts then is Telegram, as I can have them sent to a channel that I mute. Now I can see them, but I am never actually disturbed by them.
Local Thanos on Kubernetes
I run Kubernetes in my homelab and use the (now classic) Prometheus/Grafana stack for monitoring everything. In my experience, the thing that Prometheus does not do well is long-term storage. Prometheus’ own database is fine for a few days storage, but performance and reliability quickly degrade. There are quite a few solutions to this problem, but I choose to use Thanos, partly because Kube Prometheus Stack has very good support for it.
OpenClaw: My first experience with a self-hosted AI Assistant
Recently, I decided to jump on the latest AI bandwagon. While cloud-based large language models are powerful and convenient, I wanted complete control over my data, plus the satisfaction of running everything on my own infrastructure. Enter OpenClaw — a personal AI assistant that runs locally and integrates with messaging platforms you already use.
Cheap Yellow Display and Home Assistant
As I have mentioned previously I have been been gradually Home Assistant-ifying my home. Of course, part of that means having a some control panels around. I have tried an old tablet, but was not really happy with the results. At some point I leaned about the so-called “Cheap Yellow Display” (CYD). This is a small TFT display bolted directly to an ESP32 microcontroller.
There are a few things that make this interesting:
- ESPHome support: This means it is very easy to integrate into Home Assistant.
- LVLGL support: This is a powerful graphics library that allows for complex user interfaces.
- Cheap: You can get one for about 10-15 euros.
I ordered one from AliExpress without really knowing much about it and decided I would just roll with any problems that came up. As is often the case with AliExpress, the first problem was identifying exactly what arrived. I ordered a “Freenove Bitcoin Miner NMMiner NerdMinder … something something CYD ESP32 Something”. What I got was a small yellow PCB with a ILI9341 TN TFT display on one side, and an ESP32 on the other with a bunch of other stuff:
- A microSD card slot
- A battery connector
- A couple of buttons
- A few headers for GPIO access
After some searching I found out that this was indeed a CYD board, specifically this one. So now I had it, I need to figure out what to use it for to start with. Anything for my office has a much standard of Wife Acceptance Factor, so I decided to start with a control panel for my office temperature. This is already controlled using Home Assistant using a few things:
- Target temperature is variable based on presence and time of day/week
- Current temperature is from a Dallas temperature sensor (DS18B20) that sits on my desk - still in a breadboard naturally.
Including Bible Passages in Hugo
I have a few posts in my mind that will need me to include bible passages in the pages. I could just quote them, but that is no fun and I am happy make a lot of effort to be lazy.
I am using Hugo to power this site, so I decided I would add a shortcode that would allow me to do it via an API. There are a few decisions to be made first.