final fixes for the day

This commit is contained in:
kat witch 2021-08-12 06:12:55 +01:00
parent 59f9bafd30
commit b0b2ed8fb0
No known key found for this signature in database
GPG key ID: 1B477797DCA5EC72
4 changed files with 8 additions and 20 deletions

View file

@ -80,7 +80,7 @@ let
kat-splash = self.callPackage ./kat-splash { };
kat-glauca-dns = self.callPackage ./kat-glauca-dns { };
kat-website = self.callPackage ./kat-website { };
kat-gpg-status = self.callPackage ./kat-gpg-status { };

View file

@ -1,14 +0,0 @@
{ pkgs, curl, coreutils, writeShellScriptBin }:
writeShellScriptBin "kat-glauca-dns" ''
#!/usr/bin/env bash
set -eu
ip4=$(${curl}/bin/curl -s --ipv4 https://dns.glauca.digital/checkip)
ip6=$(${curl}/bin/curl -s --ipv6 https://dns.glauca.digital/checkip)
source $passFile
echo "$ip4, $ip6"
${curl}/bin/curl -u ''${user}:''${pass} --data-urlencode "hostname=''${hostname}" --data-urlencode "myip=''${ip4}" "https://dns.glauca.digital/nic/update"
echo ""
${curl}/bin/curl -u ''${user}:''${pass} --data-urlencode "hostname=''${hostname}" --data-urlencode "myip=''${ip6}" "https://dns.glauca.digital/nic/update"
''