Skip to content

Instantly share code, notes, and snippets.

@imagesafari
imagesafari / myweechat.md
Created March 6, 2023 17:58 — forked from pascalpoitras/config.md
My always up-to-date WeeChat configuration (weechat-dev)

WeeChat Screenshot

You need at least WeeChat 3.8-dev

Enable mouse

/mouse enable

Secured data

@imagesafari
imagesafari / LXCBindMount.md
Created March 10, 2022 17:19 — forked from ajmassi/LXCBindMount.md
Create a bind mount from a Proxmox host on an unprivileged lxc container

Proxmox Assign Bind Mount To Unprivileged Container

In order for the LXC container to have full access the proxmox host directory, a subgid is set as owner of a host directory, and an ACL is used to ensure permissions.

Bind Mount dataset to LXC

Add the following line to /etc/pve/lxc/<CT_ID>.conf

mp0:/mount/point/on/host,mp=/mount/point/on/lxc

Create group on host

In the default Proxmox configuration, unpriviliged container subgids will have the prefix "10" followed by the expected 4-digit gid.

@imagesafari
imagesafari / create-cloud-template.sh
Created February 17, 2022 03:31 — forked from chriswayg/create-cloud-template.sh
This script will download a cloud image of many Linux distros and create a Proxmox 6 KVM template from it.
#!/bin/bash
set -o errexit
clear
printf "\n*** This script will download a cloud image and create a Proxmox VM template from it. ***\n\n"
### HOW TO USE
### Pre-req:
### - run on a Proxmox 6 server
### - a dhcp server should be active on vmbr1
R:171018/1645Z 13281@KQ0I.#EIA.IA.USA.NOAM BPQ6.0.14
R:171018/1645Z 22014@W9ABA.#WCWI.WI.USA.NOAM BPQ6.0.14
R:171018/1645Z 29237@N9PMO.#SEWI.WI.USA.NA BPQ6.0.14
R:171018/1645Z @:N6RME.#NCA.CA.USA.NOAM #:461 [El Dorado] $:IARF1OYP_02Z
R:171018/1644Z @:CX2SA.SAL.URY.SOAM #:23434 [Salto] FBB7.00e $:IARF1OYP_02Z
R:171018/1644z @:IW8PGT.ICAL.ITA.EU $:IARF1OYP_02Z
R:171018/1644z @:IR2UBX.ILOM.ITA.EU $:IARF1OYP_02Z
R:171018/1644z @:F1OYP.FAQI.FRA.EU [Saint-Astier - JN05FD] OBcm1.07b11
boost::filesystem::create_directories(path_stream.str());
sprintf(filename, "%s/9999%ld-%ld_%g.wav", path_stream.str().c_str(), talkgroup, start_time, curr_freq);
sprintf(status_filename, "%s/9999%ld-%ld_%g.json", path_stream.str().c_str(), talkgroup, start_time, curr_freq);
sprintf(converted_filename, "%s/9999%ld-%ld.m4a", path_stream.str().c_str(), talkgroup, start_time);
{
"sources": [{
"center": 423500000.0,
"rate": 960000.0,
@imagesafari
imagesafari / make_playlist.pl
Last active June 9, 2018 00:37
Generate sdrtrunk aliases from RR talkgroup csv
#!/usr/bin/perl
#
# Convert RadioReference.com talkgroup csv download into xml to insert into sdrtrunk playlist.xml
#
# Usage: perl make_playlist.pl <csv filename> > <aliasfile.xml>
#
# Jon Anhold (jon@anhold.com) N8USK - 2016-08-19
use Data::Dumper;
my ($FILE) = @ARGV;

Keybase proof

I hereby claim:

  • I am imagesafari on github.
  • I am jonanhold (https://keybase.io/jonanhold) on keybase.
  • I have a public key whose fingerprint is E50B 4E7A 2F56 C91E 2392 C055 B0C6 B934 F133 3404

To claim this, I am signing this object: