Skip to content

Instantly share code, notes, and snippets.

View hardenedpenguin's full-sized avatar

Jory A. Pratt hardenedpenguin

  • 02:51 (UTC -05:00)
View GitHub Profile
@hardenedpenguin
hardenedpenguin / modules.conf
Created October 1, 2025 16:42
modules.conf
;
; Asterisk module loading configuration file
;
;
; You can enable or disable any of the asterisk modules
;
; To enable a module, use : load = module_name.so
; To disable a module, use : noload = module_name.so
;
@hardenedpenguin
hardenedpenguin / supermon-ng.conf
Created September 18, 2025 19:58
supermon-ng.conf
# Supermon-NG Apache Configuration Template
# Copy this configuration to your Apache sites-available directory
# Generated with detected IP addresses as ServerAlias entries
<VirtualHost *:80>
ServerName localhost
ServerAlias 10.0.0.4
ServerAlias 2601:2c1:37f:58f0:1831:5fba:91c:a77a
ServerAlias 2601:2c1:37f:58f0::3365
DocumentRoot /var/www/html
@hardenedpenguin
hardenedpenguin / gist:5262e949b43ec368bcecc700452df4fc
Created September 18, 2025 19:51
supermon-ng-v4.0.6 install log
anarchy@crazytrain:~/supermon-ng $ sudo ./install.sh
🚀 Installing Supermon-NG on ASL3+ Server...
📦 Installing system dependencies...
Hit:1 http://deb.debian.org/debian bookworm InRelease
Get:2 http://deb.debian.org/debian-security bookworm-security InRelease [48.0 kB]
Get:3 http://deb.debian.org/debian bookworm-updates InRelease [55.4 kB]
Get:4 http://archive.raspberrypi.com/debian bookworm InRelease [55.0 kB]
Get:5 https://repo.allstarlink.org/public bookworm InRelease [30.6 kB]
Get:6 http://deb.debian.org/debian-security bookworm-security/main armhf Packages [259 kB]
Get:7 http://archive.raspberrypi.com/debian bookworm/main armhf Packages [557 kB]
@hardenedpenguin
hardenedpenguin / custom.css
Created August 11, 2025 01:46
custom.css
/* Custom Vibrant Deep Neon Purple Theme for Supermon-ng */
/* This file overrides the default dark theme with vibrant deep neon purple accents */
/* Preserves original black background and table layout */
:root {
/* Vibrant Deep Neon Purple Theme Colors */
--primary-color: #8B5CF6; /* Vibrant deep neon purple */
--background-color: #121212; /* Keep original black background */
--container-bg: #1A1A1A; /* Slightly lighter dark container */
--menu-background: #1C1C1C; /* Dark menu background */
[Unit]
Description=Robust WiFi Connection Monitor and Restarter
# This ensures the network is already up before our service starts.
After=network.target
[Service]
# IMPORTANT: Use the full, absolute path to your script here.
ExecStart=/usr/local/sbin/wifi_monitor.pl
# The service must run as root to have permission to restart NetworkManager.
@hardenedpenguin
hardenedpenguin / wifi_monitor.pl
Created August 9, 2025 23:45
wifi_monitor.pl
#!/usr/bin/env perl
use strict;
use warnings;
use Net::Ping;
use POSIX qw(strftime);
# --- Configuration ---
# How many seconds to wait between checks.
@hardenedpenguin
hardenedpenguin / 0001-getEditableSettings-Helper-Function-The-logic-for-cr.patch
Created June 19, 2025 01:12
0001-getEditableSettings-Helper-Function-The-logic-for-cr.patch
From b4e56b57e5aca3694a32a23c3b43ac759e252472 Mon Sep 17 00:00:00 2001
From: Jory Pratt <anarchy@gentoo.org>
Date: Wed, 18 Jun 2025 20:11:04 -0500
Subject: [PATCH] getEditableSettings Helper Function: The logic for creating
the list of editable template fields was repeated for both activityHooks and
exportHooks. I've extracted this into a single, pure helper function
getEditableSettings defined outside the component. This reduces code
duplication and makes the main component cleaner.
Simplified isDefault Logic: In the OneExportSetting component, the logic to
#!/usr/bin/perl
# Copyright (c) 2025 Jory A. Pratt, W5GLE
#
# This script is designed to tune the dvswitch.sh application by extracting
# the port number from the /etc/asterisk/rpt.conf file based on the provided
# node number, constructing the ABINFO environment variable, and then
# executing dvswitch.sh with the provided talkgroup.
#
# This script must be run as astrisk if using a dialplan, if not using a dialplan
[W5GLE]
type = friend
context = iax-w5gle
auth = md5
secret = YOURPASSWD
host = dynamic
disallow = all
allow = ulaw
allow = adpcm
allow = gsm
[tgtune]
exten => _X.,1,Wait(3)
exten => _X.,n,Set(NODE=${EXTEN:0:6})
exten => _X.,n,Set(TG=${EXTEN:6})
exten => _X.,n,System(/usr/local/sbin/tune_dvswitch.pl "${NODE}" "${TG}")
exten => _X.,n,Hangup
[iax-w5gle]
exten => _XXXXX!,1,Ringing()
same => n,Wait(1)