Skip to content

Instantly share code, notes, and snippets.

View slmingol's full-sized avatar
:octocat:
codz

Sam Mingo slmingol

:octocat:
codz
View GitHub Profile
@Nezteb
Nezteb / bw-ssh-import.sh
Last active August 1, 2026 22:51
Import existing SSH keys into Bitwarden via the CLI. Related to: https://github.com/bitwarden/clients/issues/18833
#!/bin/bash
# Usage: ./bw-ssh-import.sh "My SSH Key Name" ~/.ssh/id_ed25519 ~/.ssh/id_ed25519.pub
# Requires `bw` and `jq`.
NAME=$1
PRIVATE_KEY_PATH=$2
PUBLIC_KEY_PATH=$3
if [[ -z "$NAME" || -z "$PRIVATE_KEY_PATH" || -z "$PUBLIC_KEY_PATH" ]]; then
@slmingol
slmingol / pihole-v6-letsencrypt-cloudflare.md
Created March 30, 2025 03:54 — forked from kaczmar2/pihole-v6-letsencrypt-cloudflare.md
Automating SSL Certificate Renewal for Pi-hole v6 (acme.sh + Cloudflare)

Pi-hole v6: Automating Let's Encrypt SSL Renewal with Cloudflare DNS

See my other guides for SSL certificates on Pi-hole v6:

Overview

Pi-hole v6 introduces changes to its web server:

  • Embedded Web Server – Pi-hole no longer relies on lighttpd.
@slmingol
slmingol / inspect_https-tls-ssl_certs.md
Created March 25, 2025 18:53 — forked from stonehippo/inspect_https-tls-ssl_certs.md
A couple of ways to look at web server HTTPS/TLS/SSL certificate data via the command line

Inspecting HTTPS (TLS, SSL) certificates from the command line

I needed to inspect an HTTPS site's current certs and wanted to do it from the command line. Here are a couple of commands that I used that worked quite well.

With nmap

nmap -p 443 --script ssl-cert [hostname]
@kaczmar2
kaczmar2 / pihole-v6-letsencrypt-cloudflare.md
Last active May 25, 2026 03:59
Automating SSL Certificate Renewal for Pi-hole v6 (acme.sh + Cloudflare)

Pi-hole v6: Automating Let's Encrypt SSL Renewal with Cloudflare DNS

See my other guides for SSL certificates on Pi-hole v6:

Overview

Pi-hole v6 introduces changes to its web server:

  • Embedded Web Server – Pi-hole no longer relies on lighttpd.
# Applied to namespace "unifi" with kustomize
apiVersion: v1
kind: ServiceAccount
metadata:
name: secret-creator
---
apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
name: secret-creator-role-binding
# Applied to namespace "unifi" with kustomize
apiVersion: v1
kind: ServiceAccount
metadata:
name: secret-creator
---
apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
name: secret-creator-role-binding
@slmingol
slmingol / pihole-timeout.sh
Created January 21, 2025 02:52 — forked from y8s/pihole-timeout.sh
pihole-timeout.sh
#!/bin/bash
# Simple script to change admin login timeout in pihole version 5.17 and up.
# Note that some versions of pihole used 'loginpage.php' instead of 'login.php'
# make the script executeable by typing:
# chmod +x pihole-timeout.sh
# run it by typing:
# sudo ./pihole-timeout.sh
# Check if user is using sudo or is root:
if [[ $(/usr/bin/id -u) -ne 0 ]]; then
@slmingol
slmingol / repair-dualboot-bootloader.sh
Created April 14, 2024 22:47 — forked from tobikris/repair-dualboot-bootloader.sh
Setting up chroot from a live image in Fedora. Regenerate grub2 for Fedora.
$ # Use Live CD to boot
$ sudo su # Switch to root
$ fdisk -l # Get names of root, boot & EFI partition names. you can also use blkid
$ # http://dadadom.de/2020/04/11/fix-fedora-uefi-boot-with-encrypted-partitions/
$ udiskctl unlock -b /dev/nvme0n1p6 # unlock root luks partition
$ mount /dev/mapper/fedora_fedora-root /mnt # mount root partition
$ mount /dev/mapper/fedora_fedora-var /mnt/var
$ mount /dev/nvme0n1p5 /mnt/boot # mount boot partition
@brooksvb
brooksvb / Uptime-Kuma-Status-Page-Dark-Mode-High-Density-Tweaks.css
Last active July 23, 2026 20:37
These CSS tweaks are for higher density display for Uptime Kuma status pages in dark mode.
:root {
--min-item-width: 28ch;
--max-item-width: .5fr;
--grid-spacing: .25rem;
--item-padding: .25rem;
}
/* Let items expand on small screens */
@media (max-width: 600px) {
:root {