File tree Expand file tree Collapse file tree 3 files changed +3
-3
lines changed
Expand file tree Collapse file tree 3 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -76,7 +76,7 @@ if [ -z "$sys_ip_check" ]; then
7676
7777 # Adding Debian/Ubuntu startup script
7878 if [ -e " /etc/debian_version" ]; then
79- if [ -d " /etc/netplan " ] ; then
79+ if dpkg-query -W -f ' ${Status} ' " netplan* " 2> /dev/null | grep -q " ok installed " ; then
8080 if [ -f " /etc/netplan/60-hestia.yaml" ]; then
8181 sys_ip=" - $ip /$cidr "
8282 else
Original file line number Diff line number Diff line change @@ -63,7 +63,7 @@ if [ -d "/etc/sysconfig" ]; then
6363 fi
6464else
6565 /sbin/iptables-save > /etc/iptables.rules
66- if [ -d " /etc/netplan " ] ; then
66+ if dpkg-query -W -f ' ${Status} ' " netplan* " 2> /dev/null | grep -q " ok installed " ; then
6767 preup=" /usr/lib/networkd-dispatcher/routable.d/50-ifup-hooks"
6868 if [ ! -e " $preup " ]; then
6969 IFS=' %'
Original file line number Diff line number Diff line change @@ -164,7 +164,7 @@ if [ -d "/etc/sysconfig" ]; then
164164 fi
165165else
166166 /sbin/iptables-save > /etc/iptables.rules
167- if [ -d " /etc/netplan " ] ; then
167+ if dpkg-query -W -f ' ${Status} ' " netplan* " 2> /dev/null | grep -q " ok installed " ; then
168168 preup=" /usr/lib/networkd-dispatcher/routable.d/50-ifup-hooks"
169169 if [ ! -e " $preup " ]; then
170170 IFS=' %'
You can’t perform that action at this time.
0 commit comments