diff options
author | Michael DeHaan <mdehaan@redhat.com> | 2006-04-06 16:23:51 -0400 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2006-04-06 16:23:51 -0400 |
commit | ecdf6cbd431de42756f3928b883854d36367b634 (patch) | |
tree | 0544161b2c9591fea668f0b65ee383d36e99a0b2 /util.py | |
parent | 5b0f54d5674a1b47c112342994b6f0bae6172809 (diff) | |
download | third_party-cobbler-ecdf6cbd431de42756f3928b883854d36367b634.tar.gz third_party-cobbler-ecdf6cbd431de42756f3928b883854d36367b634.tar.xz third_party-cobbler-ecdf6cbd431de42756f3928b883854d36367b634.zip |
Intermediate checkin. Working on various TODO features including inheritable kernel options, moving kickstarts to URLs, improved listing, etc. This commit breaks some things that will be fixed shortly...
Diffstat (limited to 'util.py')
-rw-r--r-- | util.py | 17 |
1 files changed, 6 insertions, 11 deletions
@@ -129,17 +129,12 @@ class BootUtil: return None """ - Similar to find_kernel and find_initrd, see if a path or filename - references a kickstart... + Check if a kickstart url looks like an http, ftp, or nfs url. """ - def find_kickstart(self,path): - # Kickstarts must be explicit. - # FUTURE: Look in configured kickstart path and don't require full paths to kickstart - # FUTURE: Open kickstart file and validate that it's real - if os.path.isfile(path): - return path - joined = os.path.join(self.config.kickstart_root, path) - if os.path.isfile(joined): - return joined + def find_kickstart(self,url): + x = url.lower() + for y in ["http://","nfs://","ftp://"]: + if x.startswith(y): + return url return None |