Skip to content

Instantly share code, notes, and snippets.

@hdoverobinson
hdoverobinson / backup.sh
Last active June 8, 2019 02:30
Multithreaded tar.gz backups with multiple checksum verifications
#!/bin/bash
###AUTHOR###
#Harry Dove-Robinson 2019-06-07
#harry@doverobinson.me
#https://gist.github.com/hdoverobinson
#https://github.com/hdoverobinson
###NOTES###
#Packages required: cmp, pigz, md5sum (Mac users should also install findutils and gnu-tar via Brew)
#This script will do the following:
@hdoverobinson
hdoverobinson / init.safer-things-client.sh
Last active August 28, 2019 22:33
Compiles OpenVPN with mbedTLS on Debian/Ubuntu for use with safer-things-server: https://github.com/hdoverobinson/safer-things-server
#!/bin/bash
MBEDVERSION="2.16.2"
OVPNVERSION="2.4.7"
COREPACKAGES="openvpn"
BUILDPACKAGES="cmake net-tools python wget"
MBEDURL="https://tls.mbed.org/download/mbedtls-${MBEDVERSION}-apache.tgz"
OVPNURL="https://swupdate.openvpn.org/community/releases/openvpn-${OVPNVERSION}.tar.gz"
@hdoverobinson
hdoverobinson / init.rtklib.sh
Last active October 21, 2018 17:58
Installs RTKLIB on Debian/Ubuntu without prompt for deleting /usr/src/rtklib and ignores exit status
#!/bin/bash
RTKPACKAGES="automake build-essential checkinstall git libblas3 libblas-common libgfortran3 liblapack3"
RTKURL="https://github.com/tomojitakasu/RTKLIB.git -b rtklib_2.4.3"
###INSTALL RTKLIB PACKAGES###
apt-get update &&
apt-get install -y $RTKPACKAGES &&
###PREPARE RTKLIB SOURCE###
@hdoverobinson
hdoverobinson / init.ntp.sh
Last active October 21, 2018 17:59
Installs NTP on Debian/Ubuntu without prompt for deletion of /usr/src/ntp
#!/bin/bash
###Installs a minimal NTP on Debian/Ubuntu with ACTS, PPS, and NMEA clock drivers and disables timesync.d###
###Installs useful packages for working with PPS and i2c clocks###
NTPVERSION_MAJOR="4.2"
NTPVERSION_MINOR="8p12"
ADDPACKAGES="adjtimex i2c-tools pps-tools"
COREPACKAGES="ntp"
NTPURL="https://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/ntp-4.2.8p12.tar.gz"
@hdoverobinson
hdoverobinson / init.goestools-noprompt.sh
Last active January 16, 2022 14:59
Installs goestools from source on Debian/Ubuntu without any prompt for deleting /usr/src/goestools
#!/bin/bash
GOESTOOLS_DIR="/usr/src/goestools"
GOESTOOLS_REPO="https://github.com/pietern/goestools.git"
BUILD_PACKAGES="apt-utils build-essential ca-certificates cmake git libairspy-dev libopencv* librtlsdr-dev pkg-config"
if [ "$EUID" -ne 0 ]
then echo "This script must be run as root!"
exit 1
fi &&
@hdoverobinson
hdoverobinson / luttest.sh
Created January 12, 2018 02:13
Quickly compile goesdump with a new false color LUT
#!/bin/bash
LUT="$1"
cp "$LUT" /root/osp-build/build/goesdump/XRIT/LUT/falsecolor.png &&
cd /root/osp-build/build/goesdump/ &&
rm -rf goesdump/bin/* &&
msbuild /p:Configuration=Release goesdump.sln &&
cd goesdump/bin/Release &&
mkbundle --simple *.exe XRIT.dll -o goesdump &&
#!/bin/bash
###AUTHOR###
#Harry Dove-Robinson 2018-02-04
#harry@doverobinson.me
#https://gist.github.com/hdoverobinson
#https://github.com/hdoverobinson
###CONTENTS OF TARGET_DIR WILL BE CLEARED AT EACH RUN###
DOCKER="$1"
TARGET_DIR="/root/osp-build"
@hdoverobinson
hdoverobinson / osp-handler.sh
Last active February 9, 2018 04:16
Start, stop, and back up Open Satellite Project goesdump and xritdemod
#!/bin/bash
###AUTHOR###
#Harry Dove-Robinson 2018-02-08
#harry@doverobinson.me
#https://gist.github.com/hdoverobinson
#https://github.com/hdoverobinson
###NOTES###
#Used by wx-star.com for 24/7 operation of Open Satellite Project software for HRIT/EMWIN direct readout
#Manages OSP processes inside GNU Screen sessions, performs daily backups and rotation of OSP output data
@hdoverobinson
hdoverobinson / dtmf-oobm.sh
Created July 27, 2017 05:42
Out-of-band management with DTMF tones on SIMCom cellular modem
#!/bin/bash
###AUTHOR###
#Harry Dove-Robinson 7/27/2017
#harry@doverobinson.me
#https://gist.github.com/hdoverobinson
#https://github.com/hdoverobinson
###USAGE###
#This is a script used for out-of-band management by way of DTMF tones over voice calls to a SIMCom cellular modem.
@hdoverobinson
hdoverobinson / osp-build.sh
Last active March 23, 2022 05:43
Builds Open Satellite Project xritdemod and goesdump from source
#!/bin/bash
###AUTHOR###
#Harry Dove-Robinson 12/14/2017
#harry@doverobinson.me
#https://gist.github.com/hdoverobinson
#https://github.com/hdoverobinson
###CONTENTS OF TARGET_DIR WILL BE CLEARED AT EACH RUN###
TARGET_DIR="/root/osp-build"