diff --git a/addinternal.sh b/addinternal.sh index c7c8657..3a5da15 100644 --- a/addinternal.sh +++ b/addinternal.sh @@ -1,8 +1,6 @@ #!/bin/bash -asn="4242422341" -nick="zotan" -ip4="172.20.177.33" -ip6="fdff:b02d:2ef7::2" + +source vars.sh read -p "Interface > " iface read -p "Local WG ListenPort > " port @@ -12,7 +10,7 @@ read -p "Peer DN42 IPv4 > " tun4 read -p "Peer DN42 IPv6 > " tun6 read -p "Peer node hostname > " host -node="AS${asn}_${nick}_${host}" +node="AS${asn}_${mynick}_${host}" sudo tee -a /etc/systemd/network/$iface.netdev << END [NetDev] @@ -35,7 +33,7 @@ sudo tee -a /etc/systemd/network/$iface.network << END Name = $iface [Address] -Address = $ip6/128 +Address = $int6/128 Peer = $tun6/128 [Address] diff --git a/addpeer.sh b/addpeer.sh index 3bbc046..e3a0086 100644 --- a/addpeer.sh +++ b/addpeer.sh @@ -1,6 +1,6 @@ #!/bin/bash -ip4="172.20.177.33" -ip6="fe80::2342" + +source vars.sh read -p "Interface > " iface read -p "Local WG ListenPort > " port