FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Fedora SELinux Support

 
 
LinkBack Thread Tools
 
Old 03-06-2012, 02:55 PM
David Lehman
 
Default Enable auto-detection of optical install media if no method/repo given.

Also, fix a stupid typo in forming the file:// URL that would prevent any
repos of a type other than http or ftp from working.
---
pyanaconda/packaging/yumpayload.py | 25 +++++++++++++------------
1 files changed, 13 insertions(+), 12 deletions(-)

diff --git a/pyanaconda/packaging/yumpayload.py b/pyanaconda/packaging/yumpayload.py
index bf4db18..350a5e4 100644
--- a/pyanaconda/packaging/yumpayload.py
+++ b/pyanaconda/packaging/yumpayload.py
@@ -194,14 +194,9 @@ reposdir=/etc/yum.repos.d,/etc/anaconda.repos.d,/tmp/updates/anaconda.repos.d,/t
method = self.data.method
sslverify = True
url = None
+ proxy = None

- if method.method == "cdrom":
- devices = opticalInstallMedia(storage.devicetree)
- if devices:
- self._setupDevice(devices[0], mountpoint=INSTALL_TREE)
- self.install_device = devices[0]
- url = "file://" + INSTALL_TREE
- elif method.method == "harddrive":
+ if method.method == "harddrive":
if method.biospart:
log.warning("biospart support is not implemented")
devspec = method.biospart
@@ -263,6 +258,13 @@ reposdir=/etc/yum.repos.d,/etc/anaconda.repos.d,/tmp/updates/anaconda.repos.d,/t
url = method.url
sslverify = not (method.noverifyssl or flags.noverifyssl)
proxy = method.proxy or self.proxy
+ elif method.method == "cdrom" or not method.method:
+ device = opticalInstallMedia(storage.devicetree)
+ if device:
+ self.install_device = device
+ url = "file://" + INSTALL_TREE
+ if not method.method:
+ method.method = "cdrom"

self._yum.preconf.releasever = self._getReleaseVersion(url)

@@ -281,10 +283,9 @@ reposdir=/etc/yum.repos.d,/etc/anaconda.repos.d,/tmp/updates/anaconda.repos.d,/t
self._setupNFS(INSTALL_TREE, server, path, opts)
else:
# check for media, fall back to default repo
- devices = opticalInstallMedia(storage.devicetree)
- if devices:
- self._setupDevice(devices[0], mountpoint=INSTALL_TREE)
- self.install_device = devices[0]
+ device = opticalInstallMedia(storage.devicetree)
+ if device:
+ self.install_device = device

if self._repoNeedsNetwork(repo) and not hasActiveNetDev():
raise NoNetworkError
@@ -331,7 +332,7 @@ reposdir=/etc/yum.repos.d,/etc/anaconda.repos.d,/tmp/updates/anaconda.repos.d,/t
if baseurl and
not baseurl.startswith("http:") and
not baseurl.startswith("ftp:"):
- baseurl = "file:/" + INSTALL_TREE
+ baseurl = "file://" + INSTALL_TREE

log.debug("adding yum repo %s with baseurl %s and mirrorlist %s"
% (name, baseurl, mirrorlist))
--
1.7.9.1

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list
 
Old 03-06-2012, 03:07 PM
Chris Lumens
 
Default Enable auto-detection of optical install media if no method/repo given.

> Also, fix a stupid typo in forming the file:// URL that would prevent any
> repos of a type other than http or ftp from working.

I've been using this one, and it works well.

- Chris

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

Thread Tools




All times are GMT. The time now is 07:31 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org