Exemple #1
0
 def get_optparser(self):
     optparser = cmdln.CmdlnOptionParser(self)
     optparser.add_option('-d', '--debug', action='store_true', dest='debug', help=SUPPRESS_HELP)
     optparser.add_option('-v', '--verbose', action='store_true', dest='verbose', help=SUPPRESS_HELP)
     optparser.add_option('', '--logfile', type='string', dest='logfile', default=None, help='Path of logfile')
     optparser.add_option('-c', '--config', type='string', dest='config', default=None, help='Specify config file for mic')
     optparser.add_option('-k', '--cachedir', type='string', action='store', dest='cachedir', default=None, help='Cache directory to store the downloaded')
     optparser.add_option('-o', '--outdir', type='string', action='store', dest='outdir', default=None, help='Output directory')
     optparser.add_option('-A', '--arch', type='string', dest='arch', default=None, help='Specify repo architecture')
     optparser.add_option('', '--release', type='string', dest='release', default=None, metavar='RID', help='Generate a release of RID with all necessary files, when @BUILD_ID@ is contained in kickstart file, it will be replaced by RID')
     optparser.add_option("", "--record-pkgs", type="string", dest="record_pkgs", default=None,
                          help='Record the info of installed packages, multiple values can be specified which joined by ",", valid values: "name", "content", "license"')
     optparser.add_option('', '--pkgmgr', type='string', dest='pkgmgr', default=None, help='Specify backend package manager')
     optparser.add_option('', '--local-pkgs-path', type='string', dest='local_pkgs_path', default=None, help='Path for local pkgs(rpms) to be installed')
     optparser.add_option('', '--compress-disk-image', type='string', dest='compress_disk_image', default=None, help='Sets the disk image compression. NOTE: The available values might depend on the used filesystem type.')
     return optparser
Exemple #2
0
 def get_optparser(self):
     optparser = cmdln.CmdlnOptionParser(self)
     optparser.add_option('-d', '--debug', action='store_true',
                          dest='debug',
                          help=SUPPRESS_HELP)
     optparser.add_option('-v', '--verbose', action='store_true',
                          dest='verbose',
                          help=SUPPRESS_HELP)
     optparser.add_option('', '--logfile', type='string', dest='logfile',
                          default=None,
                          help='Path of logfile')
     optparser.add_option('-c', '--config', type='string', dest='config',
                          default=None,
                          help='Specify config file for mic')
     optparser.add_option('-k', '--cachedir', type='string', action='store',
                          dest='cachedir', default=None,
                          help='Cache directory to store the downloaded')
     optparser.add_option('-o', '--outdir', type='string', action='store',
                          dest='outdir', default=None,
                          help='Output directory')
     optparser.add_option('-A', '--arch', type='string', dest='arch',
                          default=None,
                          help='Specify repo architecture')
     optparser.add_option('', '--release', type='string', dest='release',
                          default=None, metavar='RID',
                          help='Generate a release of RID with all necessary'
                               ' files, when @BUILD_ID@ is contained in '
                               'kickstart file, it will be replaced by RID')
     optparser.add_option("", "--record-pkgs", type="string",
                          dest="record_pkgs", default=None,
                          help='Record the info of installed packages, '
                               'multiple values can be specified which '
                               'joined by ",", valid values: "name", '
                               '"content", "license", "vcs"')
     optparser.add_option('', '--pkgmgr', type='string', dest='pkgmgr',
                          default=None,
                          help='Specify backend package manager')
     optparser.add_option('', '--local-pkgs-path', type='string',
                          dest='local_pkgs_path', default=None,
                          help='Path for local pkgs(rpms) to be installed')
     optparser.add_option('', '--runtime', type='string',
                          dest='runtime', default=None,
                          help='Specify  runtime mode, avaiable: bootstrap, native')
     # --taring-to is alias to --pack-to
     optparser.add_option('', '--taring-to', type='string',
                          dest='pack_to', default=None,
                          help=SUPPRESS_HELP)
     optparser.add_option('', '--pack-to', type='string',
                          dest='pack_to', default=None,
                          help='Pack the images together into the specified'
                               ' achive, extension supported: .zip, .tar, '
                               '.tar.gz, .tar.bz2, etc. by default, .tar '
                               'will be used')
     optparser.add_option('', '--copy-kernel', action='store_true',
                          dest='copy_kernel',
                          help='Copy kernel files from image /boot directory'
                               ' to the image output directory.')
     optparser.add_option('', '--install-pkgs', type='string', action='store',
                          dest='install_pkgs', default=None,
                          help='Specify what type of packages to be installed,'
                               ' valid: source, debuginfo, debugsource')
     optparser.add_option('', '--tmpfs', action='store_true', dest='enabletmpfs',
                          help='Setup tmpdir as tmpfs to accelerate, experimental'
                               ' feature, use it if you have more than 4G memory')
     optparser.add_option('', '--repourl', action='append',
                          dest='repourl', default=[],
                          help=SUPPRESS_HELP)
     return optparser