Skip to content

Instantly share code, notes, and snippets.

View paulreece42's full-sized avatar
🤠

Paul Reece paulreece42

🤠
View GitHub Profile
@paulreece42
paulreece42 / encode_hls.sh
Created March 21, 2023 22:54
ffmpeg transcode to HLS resolution
#!/bin/bash
# usage: ./encode_hls.sh video.mp4 480
#
# Transcode to HLS @ XXXXp
#
# Simple little script I made, requires jq and ffmpeg
# I just use the ffmpeg from https://johnvansickle.com/ffmpeg/
#
export INPUTFILE=$1
@paulreece42
paulreece42 / san cert with ca
Created July 20, 2017 19:54
SAN Certificate self-signed by own CA, good (in theory, but untested) for k8s etc
## BEGIN san.cnf ##
[ req ]
default_bits = 2048
distinguished_name = req_distinguished_name
req_extensions = v3_req
prompt = no
[ req_distinguished_name ]
commonName = foo.bar
[ v3_req ]
subjectAltName = @alt_names
@paulreece42
paulreece42 / gist:9002883
Last active May 25, 2021 09:10
pmacct with origin ASN without BGP
#
# Background: this was done on a CentOS 6.5 ESXi VM running pmacct 1.5.0rc2 and PostgreSQL 9.3 from PGDG repo with
# the following config line for pmacct:
#
# ./configure --enable-pgsql --enable-geoip --enable-ipv6 --with-pgsql-libs=/usr/pgsql-9.3/lib --with-pgsql-includes=/usr/pgsql-9.3/include
#
#
# I also customized the table they used in postgres to add vertical partitioning, but that's another gist :)
#