From ff4f2f34dbc96bd1cdda969f3fd4cfec2e1347c5 Mon Sep 17 00:00:00 2001 From: spiritlhl <103393591+spiritLHLS@users.noreply.github.com> Date: Sat, 3 Jun 2023 14:28:59 +0800 Subject: [PATCH] Update build_nat_network.sh --- scripts/build_nat_network.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/build_nat_network.sh b/scripts/build_nat_network.sh index b43f437..6023878 100644 --- a/scripts/build_nat_network.sh +++ b/scripts/build_nat_network.sh @@ -31,6 +31,7 @@ fi IPV4=$(ip -4 addr show | grep global | awk '{print $2}' | cut -d '/' -f1 | head -n 1) # 查询信息 +apt-get install lshw -y interface=$(lshw -C network | awk '/logical name:/{print $3}' | head -1) if [ -z "$interface" ]; then interface="eth0"