X-Git-Url: http://git.grml.org/?a=blobdiff_plain;ds=sidebyside;f=debian%2Fpatches%2F26_support_dns_bootoption.patch;h=1e17c3e72637ac8920f67451f850b67b55e9f7b6;hb=4ab3bcb19af44f09ab482a00993bea892ef70230;hp=ce1fc471abdaf80730bf7d37800379278f09aa47;hpb=7f62705bb65c0217c4b9af29420cc11e885c41f0;p=live-boot-grml.git diff --git a/debian/patches/26_support_dns_bootoption.patch b/debian/patches/26_support_dns_bootoption.patch index ce1fc47..1e17c3e 100644 --- a/debian/patches/26_support_dns_bootoption.patch +++ b/debian/patches/26_support_dns_bootoption.patch @@ -5,30 +5,24 @@ ## DP: Support dns bootoption. Usage examples: dns=8.8.8.8 / dns=8.8.8.8,1.2.3.4 @DPATCH@ ---- a/scripts/live -+++ b/scripts/live -@@ -77,6 +77,18 @@ - BOOTIF="${x#BOOTIF=}" - ;; +Index: live-boot-grml/components/9990-networking.sh +=================================================================== +--- live-boot-grml.orig/components/9990-networking.sh 2014-03-08 13:33:11.615385566 +0100 ++++ live-boot-grml/components/9990-networking.sh 2014-03-08 13:33:11.611386038 +0100 +@@ -151,7 +151,7 @@ + echo "search ${DNSDOMAIN}" >> /etc/resolv.conf + fi -+ dns=*) -+ DNSSERVER="${ARGUMENT#*=}" -+ if echo "${DNSSERVER}" | grep -q , ; then -+ DNSSERVER1="${DNSSERVER%,*}" -+ DNSSERVER2="${DNSSERVER#*,}" -+ export DNSSERVER1 DNSSERVER2 -+ else -+ DNSSERVER1="$DNSSERVER" -+ export DNSSERVER1 -+ fi -+ unset DNSSERVER -+ ;; - debug) - DEBUG="Yes" - export DEBUG ---- a/scripts/live-bottom/23networking_grml -+++ b/scripts/live-bottom/23networking_grml -@@ -44,7 +44,12 @@ +- for i in ${IPV4DNS0} ${IPV4DNS1} ${IPV4DNS1} ++ for i in ${IPV4DNS0} ${IPV4DNS1} ${IPV4DNS1} ${DNSSERVER1} ${DNSSERVER2} + do + if [ -n "$i" ] && [ "$i" != 0.0.0.0 ] + then +Index: live-boot-grml/components/9990-grml-networking.sh +=================================================================== +--- live-boot-grml.orig/components/9990-grml-networking.sh 2014-03-08 13:33:11.615385566 +0100 ++++ live-boot-grml/components/9990-grml-networking.sh 2014-03-08 13:33:11.611386038 +0100 +@@ -28,7 +28,12 @@ # prepare a new /etc/network/interfaces file (and, possibly, a new /etc/resolv.conf) IFFILE="/root/etc/network/interfaces" @@ -42,11 +36,10 @@ # config for loopback networking cat > $IFFILE << EOF -@@ -105,3 +110,17 @@ - +@@ -90,4 +95,18 @@ echo>> $IFFILE done -+ + +# dns bootoption +if [ -n "$DNSSERVER1" ] +then @@ -60,3 +53,29 @@ + echo "nameserver $i" >> $RESOLVCONF + done +fi ++ + } +Index: live-boot-grml/components/9990-cmdline-old +=================================================================== +--- live-boot-grml.orig/components/9990-cmdline-old 2014-03-08 13:33:11.615385566 +0100 ++++ live-boot-grml/components/9990-cmdline-old 2014-03-08 13:33:11.611386038 +0100 +@@ -18,6 +18,19 @@ + BOOTIF="${_PARAMETER#BOOTIF=}" + ;; + ++ dns=*) ++ DNSSERVER="${_PARAMETER#*=}" ++ if echo "${DNSSERVER}" | grep -q , ; then ++ DNSSERVER1="${DNSSERVER%,*}" ++ DNSSERVER2="${DNSSERVER#*,}" ++ export DNSSERVER1 DNSSERVER2 ++ else ++ DNSSERVER1="$DNSSERVER" ++ export DNSSERVER1 ++ fi ++ unset DNSSERVER ++ ;; ++ + bootid=*) + BOOTID="${_PARAMETER#bootid=}" + export BOOTID