Skip to content

Instantly share code, notes, and snippets.

View bretton's full-sized avatar

bretton bretton

  • Cape Town, South Africa
View GitHub Profile
@bretton
bretton / open-webui-freebsd-14.1.md
Last active November 10, 2024 10:08
Why won't open-webui install on FreeBSD 14.1?

Why won't open-webui install on FreeBSD 14.1?

If you try install open-webui in FreeBSD 14.1 you'll run into troubles.

1. Pip method

If using pip install --user open-webui it will crash with the following error

ERROR: Could not find a version that satisfies the requirement onnxruntime>=1.14.1 (from chromadb) (from versions: none)
@bretton
bretton / ibm-mq-podman-compose-ubuntu2404.md
Last active October 10, 2024 16:18
IBM-MQ with Podman, podman-compose and Ubuntu 24.04

IBM-MQ with Podman, podman-compose and Ubuntu 24.04

The following guide will help you get a containerised instance of IBM-MQ running on Ubuntu 24.04 with podman-compose and apparmour support.

Make sure you have the required software installed

sudo apt-get update
sudo apt-get -y install podman podman-compose podman-docker
@bretton
bretton / receive-btc-cash-out-uk.md
Last active September 1, 2024 14:59
Receive bitcoin over lightning network and cash out to UK bank account

Receive bitcoin over lightning network and cash out to UK bank account

Project Outline

The providers listed below appear to be present in the UK.

Evaluate the services for receiving payment over lightning network, and cashing out to a UK bank account.

Document the steps and pitfalls.

@bretton
bretton / why-envoy-broken-freebsd.md
Last active August 11, 2024 15:20
Why is Envoy Proxy broken on FreeBSD?

Why is Envoy broken on FreeBSD?

Docker-style containers are live on FreeBSD via FreeBSD Container Images by Doug Rabson, also available at container registry quay.io/dougrabson

If you want to see how several containers work together, get started with the micropod-sampler playbook to setup a small consul, nomad, traefik, minio and nginx environment using FreeBSD containers on FreeBSD

When you see it working, it makes sense to expand the micropod-sampler environment to include Envoy Proxy.

There is a tutorial Envoy Consul Service Discovery Service which covers the basic concept using consul and nomad and envoy. You can also review the Hashicorp tutorial [Understanding Consul Connect](https://www.youtube.com

@bretton
bretton / repair-dude.md
Last active April 26, 2024 14:49
Repair Mikrotik Dude database

If you run a Mikrotik Dude instance on CHR, have a lot of devices and years of activity, problems start to arise with errors like:

server status: db failure: disk image is malformed. stop
server status: db failure: database disk image is malformed. stop

The problem might temporarily be resolved by running

#!/bin/bash
@bretton
bretton / self-hosted-ai.md
Last active January 5, 2024 11:05
Self-hosted AI toolsets

Self-hosted AI toolsets

TabbyML is a self-hosted AI coding assistant, offering an open-source and on-premises alternative to GitHub Copilot.

jan.ai is a self-hosted tool to run different LLMs. github releases

Apple's mlx is an array framework for machine learning on Apple silicon

AUTOMATIC1111's Stable Diffusion web UI is a browser interface for Stable Diffusion.

@bretton
bretton / haproxy-sni.md
Last active December 6, 2023 20:39
haproxy SNI configuration with SSL pass through

This comes from this forum post and adapted with info from this gist

A sample HAproxy configuration using SNI. Using SNI has the advantage that you don't have to mess with the certificates on the HAproxy server itself. Useful with many servers and / or many fast-expiring certificates (letsencrypt).

global
        maxconn         5000
        ulimit-n        16384
        log             127.0.0.1 local0
        uid             99
@bretton
bretton / apple-m2-qemu-libvirt.md
Last active September 10, 2023 21:50
Virtual machines on Apple M2 chips, with Ventura

Virtual machines on Apple M2 chips, with Ventura

Version

This is version 0.1

Requirements

I want to run VMs with custom networking over a bridge.

@bretton
bretton / unix-disk-usage-tools.md
Last active September 3, 2023 17:33
Unix Disk Usage Tools
@bretton
bretton / monthly-income-statement-gnucash.md
Created May 7, 2023 20:44
Create a month-by-month income statement in GnuCash

Create a month-by-month income statement in GnuCash

This works for Gnucash 4.12 on a Mac.

Reports > Multicolumn > Custom Multicolumn Report

Click the Options icon.

Set 12 columns.