Skip to content

Instantly share code, notes, and snippets.

@kobuki
kobuki / pmxcfs_extract.py
Last active April 25, 2026 09:27
Create file hierarchy from a Proxmox pmxcfs/pve-cluster SQLite config database
#!/usr/bin/env python3
# Simple Python 3 script to create a browsable file tree from a Proxmox pmxcfs config.db.
# Can be used for restore tasks or other investigation purposes.
import sqlite3
import os
import argparse
def create_hierarchy(db_file, output_dir):
@kobuki
kobuki / certbot2acmesh.sh
Last active December 3, 2025 00:24
Migrate certbot configurations and certs to acme.sh
#/bin/bash
ACME_SH_ROOT=/etc/.acme.sh
WEBCONF_ROOT=/etc/apache2/sites-available.acmesh
WEBROOT=/var/www/html
RELOADCMD='systemctl reload apache2.service'
dom=()
altdoms=()
expiry=()
@kobuki
kobuki / wbx.py
Created October 14, 2023 09:24
MikroTik WinBox WBX dump script
#!/usr/bin/python
# wbx.py - dump MikroTik winbox addresses.wbx file format
# Based on: https://github.com/simeonmiteff/junkbox/blob/master/wbx.py
# Fixed & amended for Python 3 and added JSON output.
import sys
import json
def munge_pair(pair):
""" Convert integer values to integers """