dotfiles/.bin/selfhost-update.sh
2024-12-12 18:56:36 +01:00

14 lines
374 B
Bash
Executable File

#!/bin/sh
# Selfhost DynDns Update
# Usage:
# IPv4 Update: selfhost-update.sh
# IPv6 Update: selfhost-update.sh -6
# Note, min 30 seconds between calls! (rate limit)
ID=$(pass Internet/selfhost.de | grep DynDnsUser | cut -d" " -f2)
PW=$(pass Internet/selfhost.de | grep DynDnsPass | cut -d" " -f2)
set -x
curl $1 "https://$ID:$PW@carol.selfhost.de/nic/update?textmodi=1"