Compare commits

..

No commits in common. "master" and "the_failing_social_media_ban" have entirely different histories.

4 changed files with 5 additions and 212 deletions

@ -18,7 +18,7 @@ jobs:
- name: Create Kubeconfig - name: Create Kubeconfig
run: | run: |
mkdir $HOME/.kube mkdir $HOME/.kube
echo "${{ secrets.KUBEC_CONFIG_BUILDX_NEW }}" > $HOME/.kube/config echo "${{ secrets.KUBEC_CONFIG_BUILDX }}" > $HOME/.kube/config
- name: Set up Docker Buildx - name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3 uses: docker/setup-buildx-action@v3

@ -1,114 +0,0 @@
Title: Intergrating Ollama and Matrix with Baibot
Date: 2025-06-25 20:00
Modified: 2025-06-30 08:00
Category: AI, Data, Matrix
Tags: ai, kubernetes, matrix
Slug: ollama-matrix-integration
Authors: Andrew Ridgway
Summary: Integrating a Local LLM to a personal matrix server all the fun AND data sovereignty
### _Human Introduction_
I've been experimenting with AI and integrations I'm particuarly excited by the idea of using LLM's to integrate between different systems (Stay tuned for a blog [MCP](https://modelcontextprotocol.io/introduction) at some point in the future!)
Below I've thrown together some notes and had AI build a very quick how to on a cool little project that took next to no time to put together that I thought might be interesting for the group.. Enjoy!
# Matrix AI Integrations with baibot: A Fun Journey into Home Automation and LLMs
Alright, so Ive been messing around with this cool project called **baibot**, which is a locally deployable bot for integrating Large Language Models (LLMs) into Matrix chatrooms. If youre anything like me, you run your own Matrix server to keep things private and under control—whether its for family communication or interacting with the tech community. But one day, I thought, “Why not have my LLMs right where Im already managing everything else?” Enter baibot.
**Setting Up My Own Matrix Server with baibot**
First off, Ive got a home Matrix server running Element. Integrating baibot into this environment makes sense because it allows me to connect directly via the same platform. The key was getting the configuration right using examples from [baibots GitHub](https://github.com/etkecc/baibot/blob/main/docs/sample-provider-configs/ollama.yml). For instance, connecting to an Ollama gemma3 model with a specific prompt ensures its lighthearted yet responsive:
```yaml
base_url: http://<my_ollama_ip>:11434/v1
text_generation:
model_id: gemma3:latest
prompt: 'You are a lighthearted bot...'
temperature: 0.9
max_response_tokens: 4096
max_context_tokens: 128000
```
This gives me precise control over the bots behavior, ensuring each instance in Matrix rooms behaves exactly as intended.
**Deploying to Kubernetes**
To ensure reliability, I used Kubernetes. Here's a breakdown of the key files:
* **Deployment.yaml**: Manages pod replicas, security contexts, and volume mounts for persistence.
```yaml
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: ridgway-bot
name: ridgway-bot
spec:
replicas: 1
strategy:
type: Recreate
template:
spec:
containers:
- image: ghcr.io/etkecc/baibot:v1.7.4
name: baibot
volumeMounts:
- name: ridgway-bot-cm
mountPath: /app/config.yml
- name: ridgway-bot-pv
mountPath: /data
volumes:
- name: ridgway-bot-cm
configMap:
name: ridgway-bot
- name: ridgway-bot-pv
persistentVolumeClaim:
claimName: ridgway-bot-storage
```
* **Persistent Volume Claim (PVC)** ensures data storage for baibot.
```yaml
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: ridgway-bot-storage
spec:
accessModes:
- ReadWriteMany
resources:
requests:
storage: 500Mi
```
The deployment script handles namespace creation, config maps, PVCs, and waits for the pod to be ready before copying data.
**Integrating with OpenWebUI for RAG**
Another cool aspect is integrating baibot with **OpenWebUI**, which acts as an OpenAI-compatible API. This allows me to leverage models Ive created in OpenWebUI that include knowledge bases (RAG). The config here uses OpenWebUIs endpoints:
```yaml
base_url: 'https://<my-openwebui-endpoint>/api/'
api_key: <my-openwebui-api-key>
text_generation:
model_id: andrew-knowledge-base
prompt: 'Your name is Rodergast...'
```
This setup lets me access RAG capabilities directly within Matrix chats, all without writing a single line of code. Its like having my very own AI research assistant right there in the chatroom.
**Future Steps and Challenges**
Now that baibot is up and running, Im already thinking about expanding its use cases. The next step might be integrating it with **Home Assistant** for alarm notifications or other automation tasks. However, my current setup uses an older gaming PC, which struggles with computational demands. This could lead to a rearchitecting effort—perhaps moving to a dedicated server or optimizing the hardware.
**Conclusion**
Baibot has been a fantastic tool for experimenting with AI integrations in Matrix. By leveraging existing infrastructure and OpenWebUIs capabilities, Ive achieved full control over data privacy and customization. The next frontier is expanding these integrations into more practical applications like home automation. Stay tuned for updates!
**Final Thoughts**
Its incredibly rewarding to see how open-source projects like baibot democratize AI access. Whether youre a hobbyist or a pro, having tools that let you run LLMs locally without vendor lock-in is game-changing. If youre interested in diving deeper, check out the [baibot GitHub](https://github.com/etkecc/baibot) and explore its documentation. Happy coding!

@ -1,93 +0,0 @@
Title: Recovering Archlinux Qemu VM in Proxmox
Date: 2025-07-01 20:00
Modified: 2025-07-01 20:00
Category: SysAdmin
Tags: System Admin, Proxmox, Qemu, Arch, Kubernetes
Slug: recovering-arch-vm-proxmox
Authors: Andrew Ridgway
Summary: An absolute nightmare of a day trying to recover my kube cluster from a silly update error
### Human Edit
This is probably the most amazing run of the blog creator, I've started using the new gemma3n and also upgrade the box ollama runs on so it can run slightly bigger models. Using phi4 and gemma:27b has produced some amazing results see below
I *did* need to update some of the pacman stuff as it conflated to seperate issues so bear in mind I have made some little edits in that place but otherwise... this is straight from the mouth of the llm. Enjoy!
# Recovering an Archlinux QEMU VM in Proxmox: A Day in Hell and Back Again
Well that was a morning. Today I wanted to try and fix my Longhorn installation in Kube... (again 😥). It turns out, things didn't go as planned.
## The Unexpected Downfall
I went to perform my usual update and reboot... except today for whatever reason, the upgrade decided to fail to install the kernel and left me with an unbootable system.
### Dropping into Grub Rescue
At this point I dropped back down to grub rescue mode (which is always fun). Honestly? I hate that environment! And then it hit me: these systems are just QEMU disks, right? Surely I can mount them, chroot in, and fix the install.
## The Quest for Recovery
It took 2 hours of frantic Googling through Proxmox and Arch forums until I stumbled upon something... almost magical.
### Mounting QEMU Disks Made Easy
I found an amazing suite of tools to make mounting these qemu disks a breeze. Check out this [guide](https://www.howtogeek.com/devops/how-to-mount-a-qemu-virtual-disk-image/) for all the details on libguestfs-tools and guestmount.
#### Mounting in Action
```bash
sudo apt install libguestfs-tools
sudo guestmount --add /var/lib/pve/local-btrfs/images/100/vm-100-disk-0/disk.raw --mount /dev/sda3 /tmp/kube_disk/
```
### Enter Chroot Land
Now that I've got my disk mounted, it's time to chroot in. But hold up! I need it as root this time.
#### Setting Up Arch-Chroot
```bash
sudo apt install arch-installation-scripts
arch-chroot /tmp/kube_disk/
```
### Pacman: The Hero We Deserve (But Need Permission)
Oh boy, pacman threw 23 million permission errors my way. Last year they changed it to work rootless by default… but I found out you can turn off the `DefaultUser` flag in `/etc/pacman.conf`. Here's how:
```bash
# Disable DefaultUser temporarily for this session (or remove if permanent)
pacman -Syu
```
I did have a couple issues installing the kernel (which is what got borked in the update)
```bash
# Sometimes some files got written so use overwrite to get rid of them
# be warned this *could* be destructive
pacman -S linux --overwrite "*"
```
### Clean Up and Exit
Once we're done, we need to exit the chroot. Remember that crucial step: umounting correctly.
```bash
exit
sudo umount /tmp/kube_disk/
```
## The Reboot Saga (And How Not To Do It)
Reboot was supposed to be a smooth sail… but I made one fatal mistake.
### Corruption Nightmare
I didn't unmount before starting the VM. This led me down an unfortunate path of corrupting my btrfs partition beyond recognition and having to rebuild not just my master node, but *entire* cluster! Backups saved the day... barely!
#### Lessons Learned
* **Never** reboot without first properly umounting.
* Seriously need more backups for those images. 🚀
## Conclusion: A Cluster-Fucked Day Turned Into a Learning Experience
All in all it was chaos, but hey learning happens at 2 AM after midnight reboots and frantic Googling. Hope this helps anyone else stuck with Proxmox woes! 🚀

@ -9,15 +9,15 @@ Summary: The Social Media ban is an abject failure of policy. Education and the
## 🎯 The Goal: A Legal Framework to Protect Kids ## 🎯 The Goal: A Legal Framework to Protect Kids
The Australian governments or should I say Julie Inman's plan to ban social media for teens has sparked on going debate. While the intention is noble—protecting minors from online risks—its clear the technical and legal hurdles are massive. This government concept of relying on “facial aging” or “Proof of Age” APIs are prone to privacy violations and data breaches. Parents already have tools that let them make decisions about their childrens tech use without needing to hand over photos of their ID. The governments current approach is mired in bureaucracy and the tech world does not thrive in that environment. Instead of trying to outsource the problem to consultants, the government should **educate parents on the tools already available**. The Australian governments or should I say Julie Inman's plan to ban social media for teens has sparked on going debate. While the intention is noble—protecting minors from online risks—its clear the technical and legal hurdles are massive. This government concept of relying on “facial aging” or “Proof of Age” APIs are prone to privacy violations and data breaches, the government should focus on **legal accountability**. Parents already have tools that let them make decisions about their childrens tech use without needing to hand over photos of their ID. The governments current approach is mired in bureaucracy and the tech world does not thrive in that environment. Instead of trying to outsource the problem to consultants, the government should **educate parents on the tools already available**.
## 🧩 The Problem: Tech Giants Wont Do It ## 🧩 The Problem: Tech Giants Wont Do It
The governments plan to enable Inman's vision is to use facial recognition or “age-based” filters. This was flawed from the start. These systems are expensive, unreliable, and not designed for the scale of a national rollout. Even if a company like Meta or Google could do it, theyd **never** do it for the same reason: **There is no money in the equation**. The only alternative is to outsource to consultants, but those consultants are not equipped to handle the complexity. The governments plan is a joke, no one is going to build a system thats 100% accurate, secure, and compliant with privacy laws and those that, maybe, could have no insentive to. No amount of chest thumping by The E-Safety Commissioner will change this fact and throwing frankly meaningless pieces of paper from our legislative assembly will do little more than make them laugh The governments plan to enable Inman's vision is to use facial recognition or “age-based” filters. This was flawed from the start. These systems are expensive, unreliable, and not designed for the scale of a national rollout. Even if a company like Meta or Google could do it, theyd **never** do it for the same reason: ** There is no money in the equation**. The only alternative is to outsource to consultants, but those consultants are not equipped to handle the complexity. The governments plan is a joke, no one is going to build a system thats 100% accurate, secure, and compliant with privacy laws and those that *maybe* could have no insentive to. No amount of chest thumping by The E-Safety Commissioner will change this fact and throwing frankly meaningless pieces of paper from our legislative assembly will do little more than make them laugh
## 🛠️ The Tools Parents Already Have ## 🛠️ The Tools Parents Already Have
Parents ([Is it parents? is it in fact fiefdom creation on behalf of Julie Inman?](https://minister.infrastructure.gov.au/rowland/media-release/record-investment-improve-safety-australians-online)) must give up on the idea of the government fixing this. , parents should be using the **tools already in their homes**. These tools are **free, secure, and effective**. Some examples include (and I use in my own home): Parents (Is it parents? is it in fact fiefdom creation on behlaf of Julie Inman?) must give up on the idea of the government fixing this. , parents should be using the **tools already in their homes**. These tools are **free, secure, and effective**. Some examples include (and I use in my own home):
* **Fritz Box Parental Controls** (https://en.fritz.com/service/knowledge-base/dok/FRITZ-Box-7530/8_Restricting-internet-use-with-the-FRITZ-Box-parental-controls/) - Allows blocking of websites and apps, setting time limits, and creating user profiles. * **Fritz Box Parental Controls** (https://en.fritz.com/service/knowledge-base/dok/FRITZ-Box-7530/8_Restricting-internet-use-with-the-FRITZ-Box-parental-controls/) - Allows blocking of websites and apps, setting time limits, and creating user profiles.
* **Microsoft Family Safety** (https://www.microsoft.com/en-au/microsoft-365/family-safety) - Provides screen time limits, content filters, and activity reporting. * **Microsoft Family Safety** (https://www.microsoft.com/en-au/microsoft-365/family-safety) - Provides screen time limits, content filters, and activity reporting.
@ -50,4 +50,4 @@ The governments plan is a dead monkey. Instead of trying to build a system th
## 🧩 Final Thoughts ## 🧩 Final Thoughts
The Government's plan, at the behest of Julie Inman, is a **disaster**. Its not about fixing the problem with social media, its about creating the perception they are solving a problem that is already solved. [The E-Safety Commissioner has made clear her plans are to take control out of our hands when it comes to what we can do online](https://www.esafety.gov.au/newsroom/media-releases/online-industry-asked-address-esafetys-concerns-draft-codes-0#:~:text=Online%20industry%20asked%20to%20address%20eSafety%27s%20concerns%20with%20draft%20codes,-Share&text=Australia%27s%20eSafety%20Commissioner%20has%20asked,safeguards%20for%20users%20in%20Australia.) Parents should be using the **tools already in their homes**. The real solution is not to expect a government to fix this, but to **educate themselves on the tools that already exist**. Until we accept that this is our responsbility the problem will continue propogate because the only place it can be fixed is in the home and not my Julie Inam. The Government's plan, at the behest of Julie Inman, is a **disaster**. Its not about fixing the problem with social media, its about creating the perception they are solving a problem that is already solved. Parents should be using the **tools already in their homes**. The real solution is not to expect a government to fix this, but to **educate themselves on the tools that already exist**. Until we accept that this is our responsbility the problem will continue propogate because the only place it can be fixed is in the home.