Skip to content

Instantly share code, notes, and snippets.

View someburner's full-sized avatar

Jeff Hufford someburner

View GitHub Profile

Problem

In Arch Linux mkinitcpio -p linux

shows

Possibly missing firmware for module: aic94xx
 Possibly missing firmware for module: wd719x

Let's Encrypt for Nginx on Ubuntu 22.04 with wildcards

Guide info:

  • we're setting up mydomain.com, *.mydomain.com
  • HTML is served from /var/www/mydomain
  • Challenges are served from /var/www/letsencrypt.
  • As of this writing, SSL Labs gives it an A+
  • Took info from here and here on wilcard certs.

Auto-renewal

# Connectiong by SSH from Android Termux to Desktop and vice-versa.md
# Copyright (c) 2019 Evandro Coan
# 
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
@someburner
someburner / PyQt6.sh
Created April 13, 2023 07:29 — forked from jinwoo1225/PyQt6.sh
Install PyQt6 on macOS for M1 (Apple Silicon) Devices
#!/bin/bash
# Assumes brew and python are installed
brew install qt@6 llvm cmake ninja git
# Setup environment
mkdir -p ~/.pyqt6; cd ~/.pyqt6
curl https://files.pythonhosted.org/packages/a0/07/0ae4f67768c1150af851572fae287aeaf956ed91b3b650b888a856274ae4/PyQt6-6.1.1.tar.gz --output PyQt6-6.1.1.tar.gz
curl https://files.pythonhosted.org/packages/50/24/743c4dd6a93d25570186a7940c4f072db1cf3fa919169b0ba598fcfc820a/PyQt6_sip-13.1.0.tar.gz --output PyQt6_sip-13.1.0.tar.gz
curl https://files.pythonhosted.org/packages/ea/5e/4c954451984d00dfc051eab5c4b40453923a85f5a0dfa9678511d06eec5e/PyQt6_3D-6.1.1.tar.gz --output PyQt6_3D-6.1.1.tar.gz
curl https://files.pythonhosted.org/packages/b9/ac/9c545186f3125b0fb02359938bddde0167344f3d4e14aee17fa122b5287a/PyQt6_Charts-6.1.1.tar.gz --output PyQt6_Charts-6.1.1.tar.gz
@someburner
someburner / replace.sh
Last active March 5, 2020 04:56 — forked from hlissner/replace.sh
Bulk search & replace with ag (the_silver_searcher)
# agr <search> <replace>
# place in .bashrc
function agr { ag -0 -l "$1" | AGR_FROM="$1" AGR_TO="$2" xargs -r0 perl -pi -e 's/$ENV{AGR_FROM}/$ENV{AGR_TO}/g'; }
export -f agr
# ORIGINAL
# ag <https://github.com/ggreer/the_silver_searcher>
# usage: ag-replace.sh [search] [replace]
# caveats: will choke if either arguments contain a forward slash
@someburner
someburner / mosquitto-v1.5.sh
Last active May 19, 2020 22:47
Install Mosquitto 1.5
#!/bin/bash
# remove mosquitto
sudo apt-get purge *mosquitto*
# hold mosquitto packages
sudo apt-mark hold mosquitto libmosquitto1 mosquitto-clients
# required build dependency
sudo apt-get install uuid-dev
# needed for mosquitto_passwd
sudo apt-get install libssl-dev
@someburner
someburner / install-mmc.sh
Created June 23, 2018 22:17
Tomatoware upgrade
#!/bin/bash
############ SETTINGS ############
pfx="mmc"
backup_prefix="/mnt/sda2"
#DISTNAME="arm-soft-$pfx-master"
DISTNAME="arm-soft-$pfx-mini"
##################################
if ! [[ -f $backup_prefix/dist/$DISTNAME.tgz ]]; then
@someburner
someburner / build_go.sh
Last active April 20, 2022 21:07
Bootstrap go
#!/bin/bash
############ SETTINGS ############
PREFIX=/usr
_GOVERS="1.18.1"
PATCH_CERTS=0
##################################
set -e
set -x
@someburner
someburner / le2018.md
Last active September 19, 2023 09:02 — forked from cecilemuller/letsencrypt_2020.md
Let's Encrypt + wildcards for Nginx (Ubuntu 17.10, IPv6, HTTP/2, Proxy-Pass, SLL Rating=A)

Let's Encrypt for Nginx on Ubuntu 17.10, 18.04 with wildcards

Guide info:

  • we're setting up mydomain.com, *.mydomain.com
  • HTML is served from /var/www/mydomain
  • Challenges are served from /var/www/letsencrypt.
  • As of this writing, SSL Labs gives it an A+
  • Took info from here and here on wilcard certs.

Auto-renewal

@someburner
someburner / bashlib.mini.sh
Created March 20, 2018 02:53
bashlib - mini
#################################################################################
# MINI VERSION #
#################################################################################
_pmod=0;
paint() { local c=1; case "$1" in "nrm") c=0;; "gry") c=30;; "red") c=31;; "grn") c=32;; "ylw") c=33;; "blu") c=34;; "pur") c=35;; "aqu") c=36;; "wht") c=1;; esac; printf "\\033[$_pmod;$c""m$2""\033[m"; };
lpaint() { local c=1; case "$1" in "nrm") c=0;; "gry") c=90;; "red") c=91;; "grn") c=92;; "ylw") c=93;; "blu") c=94;; "pur") c=95;; "aqua") c=96;; "wht") c=97;; *);; esac; printf "\\033[$_pmod;$c""m$2""\033[m"; };
paintln() { paint "$1" "$2\n"; }; lpaintln() { lpaint "$1" "$2\n"; };
painthi() { _pmod=7; paint "$1" "$2"; }; painthiln() { _pmod=7; paintln "$1" "$2"; };
lpainthi() { _pmod=7; lpaint "$1" "$2"; }; lpainthiln() { _pmod=7; lpaintln "$1" "$2"; };
do_warn() { paint 'ylw' '[WARN]'; printf ' %s\n' "$1"; }; do_error() { lpaint 'red' '[ERROR]'; printf '