summaryrefslogtreecommitdiffstats
path: root/pyanaconda/packaging
diff options
context:
space:
mode:
authorJesse Keating <jkeating@redhat.com>2012-11-09 14:57:16 -0800
committerBrian C. Lane <bcl@redhat.com>2012-11-09 16:05:16 -0800
commitd8f8a41b14c2ccf0ec8f8c211c891892c4b1d5e0 (patch)
treef4b111d7381370a3f0a916102862749e62fa98b1 /pyanaconda/packaging
parentabd4bb5c07cabd747d815f7003a17511ce1b31e6 (diff)
downloadanaconda-d8f8a41b14c2ccf0ec8f8c211c891892c4b1d5e0.tar.gz
anaconda-d8f8a41b14c2ccf0ec8f8c211c891892c4b1d5e0.tar.xz
anaconda-d8f8a41b14c2ccf0ec8f8c211c891892c4b1d5e0.zip
Show NFS as the source if dracut left it for us (#875235)
Diffstat (limited to 'pyanaconda/packaging')
-rw-r--r--pyanaconda/packaging/yumpayload.py15
1 files changed, 13 insertions, 2 deletions
diff --git a/pyanaconda/packaging/yumpayload.py b/pyanaconda/packaging/yumpayload.py
index ac7568374..d12a00677 100644
--- a/pyanaconda/packaging/yumpayload.py
+++ b/pyanaconda/packaging/yumpayload.py
@@ -611,14 +611,25 @@ reposdir=%s
url = method.url
sslverify = not (method.noverifyssl or flags.noverifyssl)
elif method.method == "cdrom" or (checkmount and not method.method):
- # Did dracut leave the DVD mounted for us?
+ # Did dracut leave the DVD or NFS mounted for us?
device = get_mount_device("/run/install/repo")
# Only look at the dracut mount if we don't already have a cdrom
if device and not self.install_device:
self.install_device = storage.devicetree.getDeviceByPath(device)
url = "file:///run/install/repo"
if not method.method:
- method.method = "cdrom"
+ # See if this is a nfs mount
+ if ':' in device:
+ # prepend nfs: to the url as that's what the parser
+ # wants. Note we don't get options from this, but
+ # that's OK for the UI at least.
+ options, host, path = iutil.parseNfsUrl("nfs:%s" %
+ device)
+ method.method = "nfs"
+ method.server = host
+ method.dir = path
+ else:
+ method.method = "cdrom"
else:
# cdrom or no method specified -- check for media
if not self.install_device: