Skip to content

Commit

Permalink
move wpa_suppliant things into the conditional block
Browse files Browse the repository at this point in the history
  • Loading branch information
jxmx authored and guysoft committed Dec 10, 2024
1 parent e29a331 commit 637bcf5
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/modules/network/start_chroot_script
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,12 @@ if [ "${NETWORK_WPA_SUPPLICANT}" == "yes" ]; then

# create symlink
ln -s "${DIST_NETWORK_FILE}" /etc/wpa_supplicant/wpa_supplicant.conf

# copy /etc/wpa_supplicant/ifupdown.sh to /etc/ifplugd/action.d/ifupdown - for wlan auto reconnect
[ -f /etc/ifplugd/action.d/ifupdown ] && mv /etc/ifplugd/action.d/ifupdown /etc/ifplugd/action.d/ifupdown.original
[ -f /etc/wpa_supplicant/ifupdown.sh ] && ln -s /etc/wpa_supplicant/ifupdown.sh /etc/ifplugd/action.d/ifupdown


fi

if [ "${NETWORK_NETWORK_MANAGER}" == "yes" ]; then
Expand All @@ -45,10 +51,6 @@ if [ "${BASE_DISTRO}" == "raspbian" ]; then
rm /var/lib/systemd/rfkill/*
fi

# copy /etc/wpa_supplicant/ifupdown.sh to /etc/ifplugd/action.d/ifupdown - for wlan auto reconnect
[ -f /etc/ifplugd/action.d/ifupdown ] && mv /etc/ifplugd/action.d/ifupdown /etc/ifplugd/action.d/ifupdown.original
[ -f /etc/wpa_supplicant/ifupdown.sh ] && ln -s /etc/wpa_supplicant/ifupdown.sh /etc/ifplugd/action.d/ifupdown

if [ ! -f "/etc/rc.local" ];then
echo 'exit 0' >> /etc/rc.local
fi
Expand Down

0 comments on commit 637bcf5

Please sign in to comment.