Skip to content

Instantly share code, notes, and snippets.

@ArrEssJay
ArrEssJay / gps.sh
Last active August 7, 2022 13:47
Parse gpsd JSON messges with telegraf
View gps.sh
#!/bin/bash
gpspipe -w | jq -c -M '. | select( (.class == "SKY" and has("satellites") == true) or .class == "TPV")' | while IFS= read obj
do
echo $obj
done
@nstanke
nstanke / enable_ws.sh
Last active July 13, 2023 17:02
Synology Bitwarden_rs Websocket setup without SSH
View enable_ws.sh
#!/bin/bash
LOC_DIR="/etc/nginx"
if [ ! -f $LOC_DIR/ws.locations ]; then
echo """
location /notifications/hub {
proxy_pass http://localhost:$3;
proxy_set_header Upgrade \$http_upgrade;
proxy_set_header Connection "upgrade";