summaryrefslogtreecommitdiffstats
path: root/network.py
diff options
context:
space:
mode:
authorChris Lumens <clumens@redhat.com>2008-10-01 14:13:37 -0400
committerChris Lumens <clumens@redhat.com>2008-10-01 14:13:37 -0400
commit1ab6131582e64628681388a88beb058c82705891 (patch)
tree596efd4cbfbb668bfececadbed13b56d40b29d66 /network.py
parent8753ff3fe2989aae5e13a9dd93892b36d42dec0a (diff)
downloadanaconda-1ab6131582e64628681388a88beb058c82705891.tar.gz
anaconda-1ab6131582e64628681388a88beb058c82705891.tar.xz
anaconda-1ab6131582e64628681388a88beb058c82705891.zip
If there aren't any usable NICs, don't write out a config (#465127).
Diffstat (limited to 'network.py')
-rw-r--r--network.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/network.py b/network.py
index 126c5a5cf..af314aba5 100644
--- a/network.py
+++ b/network.py
@@ -447,6 +447,9 @@ class Network:
if not os.path.isdir("%s/etc/sysconfig/network-scripts" %(instPath,)):
iutil.mkdirChain("%s/etc/sysconfig/network-scripts" %(instPath,))
+ if len(self.netdevices.values()) == 0:
+ return
+
# /etc/sysconfig/network-scripts/ifcfg-*
for dev in self.netdevices.values():
device = dev.get('DEVICE')