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
Show hidden characters
[ | |
{ | |
"keys": ["ctrl+t"], "command": "toggle_terminus_panel", | |
"args": { | |
"config_name": "Default", | |
"panel_name": "output", | |
} | |
}, | |
{ | |
"keys": ["ctrl+w"], "command": "terminus_close", "context": [{ "key": "terminus_view"}] |
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
# Tutorial: https://blog.creekorful.com/2020/01/how-to-expose-traefik-2-dashboard-securely-docker-swarm/ | |
version: '3' | |
services: | |
reverse-proxy: | |
image: traefik:2.3 | |
command: | |
# - '--log.level=DEBUG' | |
- '--api=true' | |
- '--api.dashboard=true' |
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
# https://www.zeolearn.com/magazine/setting-caching-headers-for-a-spa-in-nginx-cache | |
server { | |
listen 80; | |
server_name localhost; | |
root /usr/share/nginx/html; | |
# X-Frame-Options is to prevent from clickJacking attack | |
add_header X-Frame-Options SAMEORIGIN; | |
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
# docker-compose-home-assistant.yml or docker-compose.yml | |
# Before running 'docker-compose up -d', ensure that all directories exist and bash variables are set | |
# Here is an example of how you could create the dirs and set the vars needed in this file: | |
# Resource: https://zwave-js.github.io/zwavejs2mqtt/#/getting-started/docker?id=installation | |
# BOOTSTRAP_Z_STICK_USB_ID="$(l /dev/serial/by-id/ | head -c -2)" | |
# BOOTSTRAP_ZWAVEJS_SESSION_SECRET="$(cat /dev/urandom | env LC_ALL=C tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)" | |
# echo "export BOOTSTRAP_Z_STICK=$BOOTSTRAP_Z_STICK" >> $HOME/.bashrc | |
# echo "export BOOTSTRAP_ZWAVEJS_SESSION_SECRET=$BOOTSTRAP_ZWAVEJS_SESSION_SECRET" >> $HOME/.bashrc |
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
# docker-compose-plex.yml or docker-compose.yml | |
# https://github.com/linuxserver/docker-plex | |
# Before running 'docker-compose up -d', ensure that all directories exist and bash variables are set | |
# Here is an example of how you could create the dirs and set the vars needed in this file: | |
# BOOTSTRAP_PLEX_CLAIM= # Fill this with the code found here: https://www.plex.tv/claim/ | |
# BOOTSTRAP_PLEX_TV= | |
# BOOTSTRAP_PLEX_MOVIES= | |
# BOOTSTRAP_PLEX_MUSIC= |
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
# 1. One liner, append to a file | |
echo "A new line at the end of the file" >> file.txt | |
# 2. One liner, append to a file including newlines | |
echo -e "\n\nA new line at the end of the file that is preceeded by some new lines" >> file.txt | |
# 3. One liner, append to a file the requires sudo | |
echo "A new line at the end of the file that requires sudo" | sudo tee -a /etc/fstab | |
--- |
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
# Make a directory to mount the drive to | |
sudo mkdir /mnt/drive1 | |
# First step of getting the UUID of the drive is to get the device path (ex: /dev/sdb2) | |
lsblk -e7 -e11 # e7 to hide loop devices and e11 to hide cdrom drives | |
# This is the way to mount in a non-permanent way (goes away after reboot) | |
# sudo mount /dev/sdb2 /mnt/drive1 | |
# Get the UUID of the drive to mount |
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
dig @resolver4.opendns.com myip.opendns.com +short | |
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
# Do a speed test | |
curl -s https://raw.githubusercontent.com/sivel/speedtest-cli/master/speedtest.py | python3 - | |
# Add speedtest alias to your Z Profile | |
echo 'alias speedtest="curl -s https://raw.githubusercontent.com/sivel/speedtest-cli/master/speedtest.py | python3 -"' >> ~/.zshrc | |
# Add speedtest alias to your Bash Profile | |
echo 'alias speedtest="curl -s https://raw.githubusercontent.com/sivel/speedtest-cli/master/speedtest.py | python3 -"' >> ~/.bashrc |
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
Host github.com | |
Hostname github.com | |
User coltenkrauter | |
Port 22 | |
IdentityFile /users/coltenkrauter/.ssh/id_ed25519_github | |
# ssh-add --apple-use-keychain ~/.ssh/id_ed25519_github |