From bd2c302d349d65fdb7529328480aeee8cc995c84 Mon Sep 17 00:00:00 2001 From: Troy Dawson Date: May 02 2023 22:05:21 +0000 Subject: do not check with scratch builds Signed-off-by: Troy Dawson --- diff --git a/src/centpkg/cli.py b/src/centpkg/cli.py index 358b950..44e27f8 100755 --- a/src/centpkg/cli.py +++ b/src/centpkg/cli.py @@ -159,7 +159,7 @@ class centpkgClient(cliClient): def _build(self, sets=None): # Only do rhel-target if we are centpkg, not centpkg-sig - if not os.path.basename(sys.argv[0]).endswith('-sig'): + if not os.path.basename(sys.argv[0]).endswith('-sig') and not self.args.scratch: # Only run if we have internal configuraions, or scratch internal_config_file = "/etc/rpkg/centpkg_internal.conf" @@ -254,12 +254,11 @@ class centpkgClient(cliClient): self.log.info(" rhel-target: " + json.loads(self.args.custom_user_metadata)['rhel-target']) else: - if not self.args.scratch: - self.log.info("NO INTERNAL CONFIGURATION") - self.log.info("Only scratch builds are allowed without internal configurations") - self.log.info("Hint: Install the rhel-packager package from https://download.devel.redhat.com/rel-eng/RCMTOOLS/latest-RCMTOOLS-2-RHEL-9/compose/BaseOS/x86_64/os/Packages/ if you want to build the package via internal (Red Hat) configuration.") - self.log.info("Exiting") - raise SystemExit + self.log.info("NO INTERNAL CONFIGURATION") + self.log.info("Only scratch builds are allowed without internal configurations") + self.log.info("Hint: Install the rhel-packager package from https://download.devel.redhat.com/rel-eng/RCMTOOLS/latest-RCMTOOLS-2-RHEL-9/compose/BaseOS/x86_64/os/Packages/ if you want to build the package via internal (Red Hat) configuration.") + self.log.info("Exiting") + raise SystemExit # Proceed with build return super(centpkgClient, self)._build(sets)