diff --git a/lib.sh b/lib.sh index 27905d4c..497c776c 100644 --- a/lib.sh +++ b/lib.sh @@ -45,7 +45,6 @@ SYSVENDOR=$(cat /sys/devices/virtual/dmi/id/sys_vendor) # Network IFACE=$(ip r | grep "default via" | awk '{print $5}') IFACE2=$(ip -o link show | awk '{print $2,$9}' | grep 'UP' | cut -d ':' -f 1) -REPO=$(grep "^deb " /etc/apt/sources.list | grep http | awk '{print $2}' | head -1) ADDRESS=$(hostname -I | cut -d ' ' -f 1) WANIP4=$(curl -s -k -m 5 -4 https://api64.ipify.org) INTERFACES="/etc/netplan/nextcloud.yaml" diff --git a/menu/startup_configuration.sh b/menu/startup_configuration.sh index 9a6fff2a..6d2dbda1 100644 --- a/menu/startup_configuration.sh +++ b/menu/startup_configuration.sh @@ -37,6 +37,7 @@ else fi # Get the correct apt-mirror +REPO=$(grep "URIs:" $(find /etc/apt/ -type f -name "*sources*") | grep http | awk '{print $2}' | head -1) if [ "$REPO" = 'http://archive.ubuntu.com/ubuntu' ] then MIRROR_SWITCH="ON"