def __init__(
        self, name="system", shortdesc=_("Assemble system information as a tar file or directory"), primary=True
    ):
        CliCommand.__init__(self, name=name, shortdesc=shortdesc, primary=primary)

        self.parser.add_option(
            "--destination",
            dest="destination",
            default="/tmp",
            help=_("the destination location of the result; default is /tmp"),
        )
        # default is to build an archive, this skips the archive and clean up,
        # just leaving the directory of debug info for sosreport to report
        self.parser.add_option(
            "--no-archive",
            action="store_false",
            default=True,
            dest="archive",
            help=_("data will be in an uncompressed directory"),
        )
        self.parser.add_option(
            "--sos",
            action="store_true",
            default=False,
            dest="sos",
            help=_("only data not already included in sos report will be collected"),
        )
Пример #2
0
    def __init__(self, name="system",
                 shortdesc=_("Assemble system information as a tar file or directory"),
                 primary=True):
        CliCommand.__init__(self, name=name, shortdesc=shortdesc, primary=primary)

        self.parser.add_option("--destination", dest="destination",
                               default="/tmp", help=_("the destination location of the result; default is /tmp"))
        # default is to build an archive, this skips the archive and clean up,
        # just leaving the directory of debug info for sosreport to report
        self.parser.add_option("--no-archive", action='store_false',
                               default=True, dest="archive",
                               help=_("data will be in an uncompressed directory"))
        self.parser.add_option("--sos", action='store_true',
                               default=False, dest="sos",
                               help=_("only data not already included in sos report will be collected"))
        # These options don't do anything anymore, since current versions of
        # RHSM api doesn't support it, and previously they failed silently.
        # So now they are hidden, and they are not hooked up to anything. This
        # avoids breaking existing scripts, since it also didn't do anything
        # before. See rhbz #1246680
        self.parser.add_option("--no-subscriptions", action='store_true',
                               dest="placeholder_for_subscriptions_option",
                               default=False, help=optparse.SUPPRESS_HELP)
        self.parser.add_option("--subscriptions", action='store_true',
                               dest="placeholder_for_subscriptions_option",
                               default=False, help=optparse.SUPPRESS_HELP)

        self.assemble_path = ASSEMBLE_DIR

        # so we can track the path of the archive for tests.
        self.final_destination_path = None
Пример #3
0
    def __init__(self,
                 name="system",
                 shortdesc=_(
                     "Assemble system information as a tar file or directory"),
                 primary=True):
        CliCommand.__init__(self,
                            name=name,
                            shortdesc=shortdesc,
                            primary=primary)

        self.parser.add_option(
            "--destination",
            dest="destination",
            default="/tmp",
            help=_("the destination location of the result; default is /tmp"))
        # default is to build an archive, this skips the archive and clean up,
        # just leaving the directory of debug info for sosreport to report
        self.parser.add_option(
            "--no-archive",
            action='store_false',
            default=True,
            dest="archive",
            help=_("data will be in an uncompressed directory"))
        self.parser.add_option(
            "--sos",
            action='store_true',
            default=False,
            dest="sos",
            help=_(
                "only data not already included in sos report will be collected"
            ))
    def __init__(self, name="system",
                 shortdesc=_("Assemble system information as a tar file or directory"),
                 primary=True):
        CliCommand.__init__(self, name=name, shortdesc=shortdesc, primary=primary)

        self.parser.add_option("--destination", dest="destination",
                               default="/tmp", help=_("the destination location of the result; default is /tmp"))
        # default is to build an archive, this skips the archive and clean up,
        # just leaving the directory of debug info for sosreport to report
        self.parser.add_option("--no-archive", action='store_false',
                               default=True, dest="archive",
                               help=_("data will be in an uncompressed directory"))
        self.parser.add_option("--sos", action='store_true',
                               default=False, dest="sos",
                               help=_("only data not already included in sos report will be collected"))
        # These options don't do anything anymore, since current versions of
        # RHSM api doesn't support it, and previously they failed silently.
        # So now they are hidden, and they are not hooked up to anything. This
        # avoids breaking existing scripts, since it also didn't do anything
        # before. See rhbz #1246680
        self.parser.add_option("--no-subscriptions", action='store_true',
                               dest="placeholder_for_subscriptions_option",
                               default=False, help=optparse.SUPPRESS_HELP)
        self.parser.add_option("--subscriptions", action='store_true',
                               dest="placeholder_for_subscriptions_option",
                               default=False, help=optparse.SUPPRESS_HELP)

        self.assemble_path = ASSEMBLE_DIR

        # so we can track the path of the archive for tests.
        self.final_destination_path = None
    def __init__(self, name="system",
                 shortdesc=_("Assemble system information as a tar file or directory"),
                 primary=True):
        CliCommand.__init__(self, name=name, shortdesc=shortdesc, primary=primary)

        self.parser.add_option("--destination", dest="destination",
                               default="/tmp", help=_("the destination location of the result; default is /tmp"))
        # default is to build an archive, this skips the archive and clean up,
        # just leaving the directory of debug info for sosreport to report
        self.parser.add_option("--no-archive", action='store_false',
                               default=True, dest="archive",
                               help=_("data will be in an uncompressed directory"))
        self.parser.add_option("--sos", action='store_true',
                               default=False, dest="sos",
                               help=_("only data not already included in sos report will be collected"))
        # The default is to not collect org level subscriptions info. The
        # --subscriptions option can be used to include that.
        # "--no-subscriptions" is now the default, but keep it for
        # cli backwards compatibility.
        self.parser.add_option("--no-subscriptions", action='store_false',
                               dest="include_subs",
                               help=_("exclude subscription data (default)"))
        self.parser.add_option("--subscriptions", action='store_true',
                               default=False, dest="include_subs",
                               help=_("include subscription data"))
        self.assemble_path = ASSEMBLE_DIR

        # so we can track the path of the archive for tests.
        self.final_destination_path = None