Skip to content

Instantly share code, notes, and snippets.

View VibroAxe's full-sized avatar

James Kinsman VibroAxe

View GitHub Profile
@VibroAxe
VibroAxe / Copy to USB Stick.ps1
Created June 4, 2024 21:59
Copy to USB Stick
#### Copies all files from current folder (exluding PS1 & BAT files) onto the next inserted USB Stick. Also clears existing files from stick
Register-WmiEvent -Class win32_VolumeChangeEvent -SourceIdentifier volumeChange
try {
write-host (get-date -format s) " Beginning USB Flash Script..."
write-host (get-date -format s) " "
write-host (get-date -format s) " #############################################"
write-host (get-date -format s) " # WARNING #"

Usage

# Setup the service
curl -sSL https://gist.githubusercontent.com/VibroAxe/80d55cc32b5c3290d7ee8b44b9d9a8cd/raw/[email protected] | \
  sudo tee /etc/systemd/system/[email protected]

sudo useradd -g nogroup -s /bin/false -m autossh
sudo -u autossh mkdir -p /home/autossh/.ssh  # and copy your private key here
sudo -u autossh ssh-keygen -t ed25519 # Generate a new private key
@VibroAxe
VibroAxe / lancache.sh
Created February 7, 2019 17:19
Simple Lancache Get Go
#!/bin/bash
HOST_IP=`hostname -I`
docker run --restart unless-stopped --name steamcache-dns -p $HOST_IP:53:53/udp -e USE_GENERIC_CACHE=true -e LANCACHE_IP=$HOST_IP steamcache/steamcache-dns:latest
docker run --restart unless-stopped --name cache-mono -v /cache/data:/data/cache -v /cache/logs:/data/logs -p $HOST_IP:80:80 steamcache/monolithic:latest
docker run --name sniproxy -p 443:443 steamcache/sniproxy:latest
echo Please configure your dhcp server to serve dns as $HOST_IP

Keybase proof

I hereby claim:

  • I am vibroaxe on github.
  • I am vibroaxe (https://keybase.io/vibroaxe) on keybase.
  • I have a public key ASCNIxHCjEpTntgl5Z1HijEFFt9HPn3QSj-Aeo1fLao8UAo

To claim this, I am signing this object: