Skip to content

Instantly share code, notes, and snippets.

@ctrlaltdev
Last active July 17, 2022 00:40
Show Gist options
  • Save ctrlaltdev/7407424fe11e094fa85c8246d49bec53 to your computer and use it in GitHub Desktop.
Save ctrlaltdev/7407424fe11e094fa85c8246d49bec53 to your computer and use it in GitHub Desktop.
#!/bin/sh
version=v2.1.0
os=$1
arch=$2
if [ -z "$os" ] || [ -z "$arch" ]; then
echo -n "What is your OS? [darwin/linux] "
read os < /dev/tty
echo -n "What is your ARCH? [amd64/arm64/armv7/armv6/armv5] "
read arch < /dev/tty
fi
curl -o DIYDDNS-$os-$arch.tar.gz -sL https://github.com/ctrlaltdev/DIYDDNS/releases/download/$version/DIYDDNS-$os-$arch.tar.gz
curl -o DIYDDNS-$os-$arch.tar.gz.sha256 -sL https://github.com/ctrlaltdev/DIYDDNS/releases/download/$version/DIYDDNS-$os-$arch.tar.gz.sha256
sha256sum -c DIYDDNS-$os-$arch.tar.gz.sha256
tar xzf DIYDDNS-$os-$arch.tar.gz
rm DIYDDNS-$os-$arch.tar.gz*
sudo mv DIYDDNS /usr/local/bin/
echo "\nDIYDDNS INSTALLED\n"
DIYDDNS -h
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment