Commit 6f465ddc authored by Michael Prokop's avatar Michael Prokop Committed by Evgeni Golov

Support dns bootoption.

Usage examples: dns=8.8.8.8 / dns=8.8.8.8,1.2.3.4
parent da50dd40
......@@ -17,7 +17,12 @@ Cmdline_old ()
BOOTIF=*)
BOOTIF="${_PARAMETER#BOOTIF=}"
;;
dns=*)
DNS=${_PARAMETER#dns=}
DNSSERVERS=$(echo ${DNS} | sed 's/,/ /g')
export DNSSERVERS
unset DNS
;;
dhcp)
# Force dhcp even while netbooting
# Use for debugging in case somebody works on fixing dhclient
......
......@@ -151,7 +151,7 @@ do_netsetup ()
echo "search ${DNSDOMAIN}" >> /etc/resolv.conf
fi
for i in ${IPV4DNS0} ${IPV4DNS1} ${IPV4DNS1}
for i in ${IPV4DNS0} ${IPV4DNS1} ${IPV4DNS1} ${DNSSERVERS}
do
if [ -n "$i" ] && [ "$i" != 0.0.0.0 ]
then
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment