Update update-dns.sh

This commit is contained in:
2025-02-22 13:51:40 -06:00
parent 6774871164
commit 42ac2c5435

View File

@@ -9,23 +9,22 @@ else
fi
if [ -f /etc/netplan/eth0.yaml ]; then
cat /etc/netplan/eth0.yaml
netfile=/etc/netplan/eth0.yaml
elif [ -f /etc/netplan/network.yaml ]; then
cat /etc/netplan/network.yaml
netfile=/etc/netplan/network.yaml
elif [ -f /etc/network/interfaces ]; then
cat /etc/network/interfaces
netfile=/etc/network/interfaces
else
echo -e "No network configs found\n"
exit 1
fi
echo
# cat ${netfile}
# echo
chmod 0600 ${netfile}
read -e -p "Do you wish to continue changing the DNS? (Y/n) " choice
read -p "Do you wish to continue changing the DNS? (Y/n) " choice
case "$choice" in
[Nn])
echo -e "${Green}The DNS servers have NOT been updated${Color_Off}"