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/bash | |
if [[ -z $1 ]]; then | |
errcode="0" | |
else | |
errcode=$1 | |
fi; | |
# use case statement to make decision for errcode | |
case $errcode in |
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 | |
# Automated updating of containers via cron | |
# Leverages watchtower for auto image cleanup and robustness. | |
if [ -t 1 ] ; then | |
echo "Running in an interactive shell" | |
else | |
exec 1>/dev/null | |
exec 2>/dev/null |
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/bash | |
# Credit for original script: | |
# https://pubs.vmware.com/vsphere-6-5/topic/com.vmware.vsphere.vcsapg-rest.doc/GUID-222400F3-678E-4028-874F-1F83036D2E85.html | |
# Enhanced to add error checking, status display etc - Jeremy Sherriff 2018 | |
# Depends on jq (jq-linux64) from https://stedolan.github.io/jq | |
# TO-DO: Move to PowerCli/Powershell version. | |
# See https://blogs.vmware.com/PowerCLI/2018/07/automate-file-based-backup-of-vcsa.html |
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
# References: | |
# https://support.plex.tv/articles/201638786-plex-media-server-url-commands/ | |
# https://support.plex.tv/articles/204059436-finding-an-authentication-token-x-plex-token/ | |
# Sections | |
# 1 = Movies | |
# 2 = TV | |
# 4 = Home Movies | |
# Linux: |
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://community.sophos.com/products/unified-threat-management/astaroorg/f/utm-9-3-beta/65895/9-302-2-bug-adapter-e1000e-hangs-reset | |
#ethtool -K eth0 gso off <- Can't automate this! | |
#ethtool -K eth0 gro off | |
#ethtool -K eth0 tso off | |
SUBSYSTEM=="net", ACTION=="add", ATTRS{vendor}=="0x8086", ATTRS{device}=="0x1502", RUN+="/lib/udev/nic-disable-tso" | |
SUBSYSTEM=="net", ACTION=="add", ATTRS{vendor}=="0x8086", ATTRS{device}=="0x1502", RUN+="/lib/udev/nic-disable-gro" |
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/bash | |
THISUSER=$(whoami) | |
if [ $THISUSER != 'root' ] | |
then | |
echo 'You must use sudo to run this script, sorry!' | |
exit 1 | |
fi | |
echo "Jackett:" | |
echo "Grabbing current running state.." |
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/bash | |
# Get ssl-cert-check from https://github.com/Matty9191/ssl-cert-check | |
# Check that the below script lines use the right cert locations | |
# and email parameters | |
RENEWAL_DAYS=14 | |
TMPFILE=`mktemp -t email.XXXXXXXXXX` | |
ISEXPIRING=false | |
for CERT in $(ls -1R /etc/letsencrypt/live/*/cert.pem) |
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
import requests | |
import json | |
ssl = False | |
ip = "192.168.0.32" | |
port = "3579" | |
usernm = "foo" | |
passwd = "bar" | |
WEBURL = "http" + ("s" if ssl else "") + "://"+ip+":"+port |