- Download Desktop Video (driver) & Desktop Video SDK from https://www.blackmagicdesign.com/support/family/capture-and-playback
- Install Desktop Video (driver)
tar -xf Blackmagic_Desktop_Video_Linux_*.tar cd Blackmagic_Desktop_Video_Linux_*/deb/x86_64/ sudo dpkg -i desktopvideo_*.deb sudo apt-get install -f BlackmagicFirmwareUpdater status # if prompted to update, perform an update:
- create bridges for use by mikrotik CHR
- create VM without any media
wget https://download.mikrotik.com/routeros/7.14/chr-7.14.img.zip
apt update
apt install unzip
unzip chr-7.14.img.zip
qemu-img resize -f raw chr-7.14.img 256M
qm disk import 100 chr-7.14.img local-lvm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/sh -x | |
# The reason to copy rsync binaries into Git for Windows is because | |
# VS Code has built in support for Git Bash shell in its Terminal. | |
# steps: | |
# 1. install Git for Windows from https://gitforwindows.org/ | |
# 2. install MSYS2 from https://www.msys2.org/ | |
# 3. Run as administrator: MSYS2 MSYS | |
# 4. execute the commands below in MSYS2 MSYS from step 3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
base { | |
// debug: connection progress & client list on SIGUSR1 | |
log_debug = on; | |
// info: start and end of client session | |
log_info = on; | |
/* possible `log' values are: | |
* stderr | |
* file:/path/to/file |
- Check status
vgdisplay lvdisplay
- Extend Logical Volume
lvextend -l +100%FREE /dev/VG_NAME/LV_NAME
- Resize Filesystem
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt install curl gnupg2 ca-certificates lsb-release | |
echo "deb http://nginx.org/packages/ubuntu `lsb_release -cs` nginx" | sudo tee /etc/apt/sources.list.d/nginx.list | |
curl -fsSL https://nginx.org/keys/nginx_signing.key | sudo apt-key add - | |
sudo apt update | |
NGINX_VERSION=$(apt show nginx | grep "^Version" | cut -d " " -f 2 | cut -d "-" -f 1) | |
# take note of the nginx version in the "stable" release. e.g. 1.14.2 | |
echo NGINX version $NGINX_VERSION | |
wget https://hg.nginx.org/pkg-oss/raw-file/default/build_module.sh | |
chmod a+x build_module.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
domnt() { | |
local lbl="$1" mnt="$2" | |
if ! mount | grep -qF " $mnt " ; then | |
mkdir -p "$mnt" | |
if mount "LABEL=$lbl" "$mnt" ; then | |
echo "'LABEL=$lbl' has been mounted at '$mnt'" | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"fmt" | |
"runtime" | |
"strings" | |
"sync" | |
) | |
// Goid gets goroutine ID. Only used for debugging purpose. |
On local machine
$ brew install gnupg pinentry-mac # macOS
$ echo 'export GPG_TTY=$(tty)' >> ~/.bashrc
$ echo 'export GPG_TTY=$(tty)' >> ~/.zshrc
$ echo "pinentry-program $(command -v pinentry-mac)" > ~/.gnupg/gpg-agent.conf # macOS
$ defaults write org.gpgtools.common UseKeychain NO # macOS
$ gpgconf --kill gpg-agent
$ gpg-connect-agent /bye
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/sh | |
# Ref: https://stackoverflow.com/a/62650346/109747 | |
# macOS/BSD find requires root path | |
root=${1:-.} | |
# TODO: handle if git-shallow.sh exits with non-zero code | |
find $root -type d -name '.git' -exec sh -c 'pushd "${0%/*}" && ( git-shallow.sh ) && popd' {} \; |
NewerOlder