diff options
author | Jeremy Katz <katzj@redhat.com> | 2002-06-09 02:03:40 +0000 |
---|---|---|
committer | Jeremy Katz <katzj@redhat.com> | 2002-06-09 02:03:40 +0000 |
commit | ab12ab6cfde4c19414d11cd45cf09e68ed4b8d88 (patch) | |
tree | 2c564affedcc5023f65f80a098994c107c0c802f | |
parent | 15d4de1f2d6f3f45b96cc640daf478751f83a8b4 (diff) | |
download | anaconda-ab12ab6cfde4c19414d11cd45cf09e68ed4b8d88.tar.gz anaconda-ab12ab6cfde4c19414d11cd45cf09e68ed4b8d88.tar.xz anaconda-ab12ab6cfde4c19414d11cd45cf09e68ed4b8d88.zip |
you can specify lv percentage in kickstart
-rw-r--r-- | kickstart.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/kickstart.py b/kickstart.py index 7e93dcda9..89b00ed30 100644 --- a/kickstart.py +++ b/kickstart.py @@ -668,13 +668,15 @@ class KickstartBase(BaseInstallClass): (args, extra) = isys.getopt(args, '', [ 'vgname=', 'size=', 'name=', - 'fstype=' ]) + 'fstype=', + 'percent=']) mountpoint = None vgname = None size = None name = None fstype = None + percent = None format = 1 for n in args: @@ -687,6 +689,8 @@ class KickstartBase(BaseInstallClass): name = arg elif str == '--fstype': fstype = arg + elif str == '--percent': + percent = int(arg) else: print str, " ", arg @@ -703,7 +707,7 @@ class KickstartBase(BaseInstallClass): if not vgname: raise RuntimeError, "Must specify the volume group for the logical volume to be in" - if not size: + if not size and not percent: raise RuntimeError, "Must specify the size of a logical volume" if not name: raise RuntimeError, "Must specify a logical volume name" @@ -716,6 +720,7 @@ class KickstartBase(BaseInstallClass): format = format, mountpoint = mountpoint, size = size, + percent = percent, volgroup = vgid, lvname = name) id.partitions.autoPartitionRequests.append(request) |