Skip to content

Instantly share code, notes, and snippets.

View midwire's full-sized avatar
🏠
Working from home

Chris Blackburn midwire

🏠
Working from home
View GitHub Profile
@midwire
midwire / pg18-cluster-architecture.md
Created March 27, 2026 00:09
GOAT Leads — PG18 Cluster Architecture & Backup Strategy

GOAT Leads — PostgreSQL 18 Cluster Architecture

---
title: GOAT Leads — PostgreSQL 18 Cluster Architecture
---
flowchart TB
    subgraph APP["🌐 Application Layer"]
        RAILS["Rails App Servers<br/>(Capistrano deploys)"]
    end
@midwire
midwire / pr-3259-risk-analysis.md
Last active March 20, 2026 19:06
PR #3259 UX V2 Risk Analysis
@midwire
midwire / sidekiq-upgrade-analysis.md
Created February 24, 2026 23:39
Sidekiq Pro & Enterprise Upgrade Analysis

Sidekiq Pro & Enterprise Upgrade Analysis

Current Setup

  • Sidekiq OSS 7.3.10
  • 36 jobs across 5 queues (critical, default, low, mailer, maintenance)
  • sidekiq-unique-jobs (8.0.13) — 23 jobs use lock: :until_executed
  • sidekiq-failures (1.1.0) — failure monitoring
  • Production concurrency: 20 threads
  • Custom middleware: error logging + Elasticsearch context tagging
# frozen_string_literal: true
module GhlFieldConstants
FIELDS = [
{
'name' => 'Phone Type',
'dataType' => 'TEXT',
'model' => 'contact',
'fieldKey' => 'phone_type',
'map_object' => 'contact',
@midwire
midwire / go.md
Created August 29, 2023 14:40
[UDM with Pi-hole]

Configure UDM

  • Firewall & Security (side menu) - turn off Ad blocking. This is very important. If you don't do this you will get recursive DNS calls from the UDM router to your pi-hole
  • Internet (side menu) - click primary/default WAN interface. Set "Advanced" to Manual and configure primary DNS server with the static IP of your pi-hole
  • Networks (side menu) - for each network, drill down to DHCP settings under "Advanced". For DHCP Service Management click "Show Options". Turn off "Auto" for DHCP DNS Server and enter the IP of your Pi-hole. Do these steps for each network.

Configure Pi-hole

  • Configure according to your needs. The documentation is good
@midwire
midwire / sudo.sh
Last active July 13, 2023 15:07
[Make Sudo Recognize Aliases] #linux
alias sudo='sudo '
@midwire
midwire / appimage.desktop
Last active February 14, 2024 16:16
[Linux Desktop File] #appimage #linux
# Desktop files are located in ~/.local/share/applications
# Icons must be located in ~/.icons - and only use the base filename
# Command-line arguments can be used like this:
# Exec=sh -c "gourmet --gourmet-directory $HOME/my/custom/path/ %F"
[Desktop Entry]
Name=Lepton
GenericName=Gist Editor
Comment=Lepton Gist GUI
Exec=sh -c "$HOME/AppImage/Lepton-1.10.0.AppImage --in-process-gpu"
@midwire
midwire / wg.sh
Created March 29, 2023 16:53
[Autostart Wireguard VPN] #wireguard
sudo systemctl enable wg-quick@[WG_CONFIG_NAME].service
sudo systemctl daemon-reload
sudo systemctl start wg-quick@[WG_CONFIG_NAME]
systemctl status wg-quick@[WG_CONFIG_NAME]
# To Remove
sudo systemctl stop wg-quick@[WG_CONFIG_NAME]
sudo systemctl disable wg-quick@[WG_CONFIG_NAME].service
sudo rm -i /etc/systemd/system/wg-quick@[WG_CONFIG_NAME]
sudo systemctl daemon-reload
@midwire
midwire / asdf.sh
Created January 24, 2023 18:34
[List Actual DNS Servers in use] #linux
resolvectl status
# OR
systemd-resolve --status
@midwire
midwire / jquery.js
Created November 23, 2022 19:23
[Determine jQuery version in the browser]
// Paste this into the console
if (typeof jQuery != 'undefined') {
// jQuery is loaded => print the version
alert(jQuery.fn.jquery);
}