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 / import-letsencrypt-java.sh
Created February 17, 2023 17:02 — forked from galan/import-letsencrypt-java.sh
Imports the letsencrypt certificates into the java keystore
#!/bin/bash -e
# JAVA_HOME can be passed as argument if not set
if [ ! -d $JAVA_HOME ]; then
JAVA_HOME=${1}
fi
KEYSTORE=$JAVA_HOME/jre/lib/security/cacerts
if [ ! -f "$KEYSTORE" ]; then
echo "Keystore not found in '$KEYSTORE'"
exit 1
@bretton
bretton / vm-backup.sh
Created March 5, 2018 14:17 — forked from ooZberg/vm-backup.sh
I use this script to backup my QEMU/KVM/libVirt virtual machines. The script requires KVM 2.1+ since it uses the live blockcommit mode. This means the data in the snapshot disk is rolled back into the original instead of the other way around. Script does NOT handle spaces in paths.
#!/bin/bash
#
BACKUPDEST="$1"
DOMAIN="$2"
MAXBACKUPS="$3"
if [ -z "$BACKUPDEST" -o -z "$DOMAIN" ]; then
echo "Usage: ./vm-backup <backup-folder> <domain> [max-backups]"
exit 1
@bretton
bretton / README.md
Last active July 5, 2023 01:16 — forked from tyzbit/README.md
The Lightning Network (Testnet)

Forked from vasturiano, with dataset and minor other changes.

Forked from tyzbit, with new dataset from four hosts, initial jq combine command added

Latest

The Lightning Network as seen from my three nodes, with tyzbit node, at about 22:00 UTC on Feb 20 2018. This data is updated manually when I feel like it.

view