summaryrefslogtreecommitdiffstats
path: root/urlinstall.py
diff options
context:
space:
mode:
authorChris Lumens <clumens@redhat.com>2007-06-12 18:45:38 +0000
committerChris Lumens <clumens@redhat.com>2007-06-12 18:45:38 +0000
commit5cbccd4ae90400dc290b64fff53df25237310b40 (patch)
treeaf4a1b303ead347a6b8a0ab2213054afcd3fd9ff /urlinstall.py
parentc156000c17380f3c24dd97fccab6c78d6da9fcfa (diff)
downloadanaconda-5cbccd4ae90400dc290b64fff53df25237310b40.tar.gz
anaconda-5cbccd4ae90400dc290b64fff53df25237310b40.tar.xz
anaconda-5cbccd4ae90400dc290b64fff53df25237310b40.zip
Split loopback ISO method is no longer supported. Good riddance.
Diffstat (limited to 'urlinstall.py')
-rw-r--r--urlinstall.py59
1 files changed, 2 insertions, 57 deletions
diff --git a/urlinstall.py b/urlinstall.py
index 67e37ef7a..6619818ce 100644
--- a/urlinstall.py
+++ b/urlinstall.py
@@ -3,7 +3,7 @@
#
# Erik Troan <ewt@redhat.com>
#
-# Copyright 1999-2006 Red Hat, Inc.
+# Copyright 1999-2007 Red Hat, Inc.
#
# This software may be freely redistributed under the terms of the GNU
# library public license.
@@ -15,7 +15,6 @@
from installmethod import InstallMethod, FileCopyException
import os
-import re
import time
import shutil
import string
@@ -128,7 +127,7 @@ class UrlInstallMethod(InstallMethod):
tmppath = destdir
base = self.pkgUrl
-
+
fullPath = base + "/" + filename
file = tmppath + "/" + os.path.basename(fullPath)
@@ -193,10 +192,6 @@ class UrlInstallMethod(InstallMethod):
def getMethodUri(self):
return self.baseUrl
- def switchMedia(self, mediano, filename=""):
- if self.splitmethod:
- self.baseUrl = self.baseUrls[mediano - 1]
-
def unmountCD(self):
if not self.tree:
return
@@ -231,56 +226,6 @@ class UrlInstallMethod(InstallMethod):
except SystemError:
pass
- def __checkUrlForIsoMounts(self):
- # account for multiple mounted ISOs on loopback...bleh
- # assumes ISOs are mounted as AAAAN where AAAA is some alpha text
- # and N is an integer. so users could have these paths:
- # CD1, CD2, CD3
- # disc1, disc2, disc3
- # qux1, qux2, qux3
- # as long as the alpha text is consistent and the ints increment
- #
- # NOTE: this code is basically a guess. we don't really know if
- # they are doing a loopback ISO install, but make a guess and
- # shove all that at yum and hope for the best --dcantrell
-
- discdir = os.path.basename(self.pkgUrl)
- alpharm = re.compile("^[^0-9]+")
- discnum = alpharm.sub("", discdir)
-
- try:
- discnum = int(discnum)
-
- stripnum = re.compile("%s$" % (discnum,))
- basepath = stripnum.sub("", self.pkgUrl)
-
- # add all possible baseurls
- discnum = 1
- baseurls = [] # self.pkgUrl
- while True:
- dirpath = "%s%s" % (basepath, discnum)
-
- try:
- filename = self.__copyFileToTemp(dirpath, ".discinfo")
- self.unlinkFilename(filename)
- except:
- break
-
- log.debug("Adding baseurl: %s" % (dirpath,))
- baseurls.append("%s" % (dirpath,))
- try:
- self.unlinkFilename(filename)
- except:
- pass
- discnum += 1
-
- if len(baseurls) > 1:
- self.baseUrls = tuple(baseurls)
- self.splitmethod = True
- except ValueError:
- # we didn't figure out the user's dir naming scheme
- pass
-
def __init__(self, url, rootPath, intf):
InstallMethod.__init__(self, url, rootPath, intf)