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 Build System

 
 
LinkBack Thread Tools
 
Old 10-16-2008, 07:08 PM
Paul B Schroeder
 
Default new pungi command line options

In my kickstart config, the %include files are all generated in %pre and don't exist at compose time, thus "--ignore-missing-includes". And I have no repo lines defined in my ks.cfg either, so the --repo-* options allow you to specify or add repo info from the command line.

--repo-baseurl=REPO BASEURL
repository name and base URL to use
--repo-mirrorlist=REPO MIRRORLIST
repository name and mirrorlist URL to use
--ignore-missing-includes
ignore missing %include files in the kickstart config

So you can do something like this:
pungi --name=fedora --ver=10 --flavor=beta --nodebuginfo --nosplitmedia --nosource -c ks.cfg --ignore-missing-includes --repo-mirrorlist=rawhide "http://mirrors.fedoraproject.org/mirrorlist?repo=rawhide&arch=x86_64"

Cheers...Paul...


diff --git a/src/bin/pungi.py b/src/bin/pungi.py
index fbec6fd..703fc0a 100755
--- a/src/bin/pungi.py
+++ b/src/bin/pungi.py
@@ -43,7 +43,7 @@ def main():
pass

# Set up the kickstart parser and pass in the kickstart file we were handed
- ksparser = pykickstart.parser.KickstartParser(pykickstart.ver sion.makeVersion())
+ ksparser = pykickstart.parser.KickstartParser(pykickstart.ver sion.makeVersion(), missingIncludeIsFatal=opts.ignore_missing_includes )
ksparser.readKickstart(opts.config)

if opts.sourceisos:
@@ -78,6 +78,15 @@ def main():
if opts.nodebuginfo:
config.set('default', 'debuginfo', "False")

+ if opts.repo_baseurl:
+ for repo in opts.repo_baseurl:
+ rd = ksparser.handler.RepoData(name=repo[0], baseurl=repo[1])
+ ksparser.handler.repo.add(rd)
+ if opts.repo_mirrorlist:
+ for repo in opts.repo_mirrorlist:
+ rd = ksparser.handler.RepoData(name=repo[0], mirrorlist=repo[1])
+ ksparser.handler.repo.add(rd)
+
# Actually do work.
mypungi = pypungi.Pungi(config, ksparser)

@@ -166,6 +175,12 @@ if __name__ == '__main__':

parser.add_option("-c", "--config", dest="config",
help='Path to kickstart config file')
+ parser.add_option("--repo-baseurl", action="append", dest="repo_baseurl", type="string", nargs=2,
+ metavar="REPO BASEURL", help='repository name and base URL to use')
+ parser.add_option("--repo-mirrorlist", action="append", dest="repo_mirrorlist", type="string", nargs=2,
+ metavar="REPO MIRRORLIST", help='repository name and mirrorlist URL to use')
+ parser.add_option("--ignore-missing-includes", action="store_false", default=True, dest="ignore_missing_includes",
+ help="ignore missing %include files in the kickstart config")
parser.add_option("--all-stages", action="store_true", default=True, dest="do_all",
help="Enable ALL stages")
parser.add_option("-G", action="store_true", default=False, dest="do_gather",

--
Fedora-buildsys-list mailing list
Fedora-buildsys-list@redhat.com
https://www.redhat.com/mailman/listinfo/fedora-buildsys-list
 
Old 10-16-2008, 07:15 PM
Jesse Keating
 
Default new pungi command line options

On Thu, 2008-10-16 at 14:08 -0500, Paul B Schroeder wrote:
> In my kickstart config, the %include files are all generated in %pre
> and don't exist at compose time, thus "--ignore-missing-includes".
> And I have no repo lines defined in my ks.cfg either, so the --repo-*
> options allow you to specify or add repo info from the command line.
>
> --repo-baseurl=REPO BASEURL
> repository name and base URL to use
> --repo-mirrorlist=REPO MIRRORLIST
> repository name and mirrorlist URL to use
> --ignore-missing-includes
> ignore missing %include files in the kickstart
> config

Rather than throw more command line options at the problems, I wonder if
it would make more sense to make the kickstart parsing gracefully handle
and warn about missing includes. I also really don't like doing repo
declaration via the command line arguments, but I'll think on this one a
bit more.

--
Jesse Keating
Fedora -- Freedom˛ is a feature!
identi.ca: http://identi.ca/jkeating
--
Fedora-buildsys-list mailing list
Fedora-buildsys-list@redhat.com
https://www.redhat.com/mailman/listinfo/fedora-buildsys-list
 

Thread Tools




All times are GMT. The time now is 10:06 PM.

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