Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Debian User (http://www.linux-archive.org/debian-user/)
-   -   Honor kickstart noipv6 option for media installs (#677653) (http://www.linux-archive.org/debian-user/506972-honor-kickstart-noipv6-option-media-installs-677653-a.html)

Radek Vykydal 03-29-2011 11:29 AM

Honor kickstart noipv6 option for media installs (#677653)
 
In the media install case, /tmp/netinfo is not written, so
we need to initialize useIPv6 property of device in stage 2
kickstart network command handling.

Resolves: rhbz#677653

The patch is teted.

---
installclass.py | 7 ++++++-
kickstart.py | 3 ++-
2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/installclass.py b/installclass.py
index 36665cf..46abf2f 100644
--- a/installclass.py
+++ b/installclass.py
@@ -256,7 +256,9 @@ class BaseInstallClass:
def setAuthentication(self, id, authStr):
id.auth = authStr

- def setNetwork(self, id, bootProto, ip, netmask, ethtool, device = None, onboot = 1, dhcpclass = None, essid = None, wepkey = None):
+ def setNetwork(self, id, bootProto, ip, netmask, ethtool, device = None,
+ onboot = 1, dhcpclass = None, essid = None, wepkey = None,
+ ipv4=True, ipv6=True):
if bootProto:
devices = id.network.netdevices
firstdev = id.network.getFirstDeviceName()
@@ -293,6 +295,9 @@ class BaseInstallClass:
if wepkey:
dev.set(("wepkey", wepkey))

+ dev.set(("useIPv4", ipv4))
+ dev.set(("useIPv6", ipv6))
+
def setLanguageDefault(self, id, default):
id.instLanguage.setDefault(default)

diff --git a/kickstart.py b/kickstart.py
index 5f40e61..415ddf1 100644
--- a/kickstart.py
+++ b/kickstart.py
@@ -364,7 +364,8 @@ class AnacondaKSHandlers(KickstartHandlers):
try:
self.id.instClass.setNetwork(self.id, nd.bootProto, nd.ip, nd.netmask,
nd.ethtool, nd.device, nd.onboot,
- nd.dhcpclass, nd.essid, nd.wepkey)
+ nd.dhcpclass, nd.essid, nd.wepkey,
+ nd.ipv4, nd.ipv6)
except KeyError:
raise KickstartValueError, formatErrorMsg(self.lineno, msg="The provided network interface %s does not exist" % nd.device)

--
1.7.4

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


All times are GMT. The time now is 12:56 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.