Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 7 additions & 13 deletions files/bin/deploy-iqe-cji.py
Original file line number Diff line number Diff line change
Expand Up @@ -228,22 +228,16 @@ def check_cji_jobs(self) -> None:
print(f"\nAll jobs succeeded: {job_map}", flush=True)

def run(self) -> None:
if self.pr_labels:
if "run-jenkins-tests" in self.pr_labels:
display("PR labeled to run Jenkins tests instead of Konflux")
return

if "ok-to-skip-smokes" in self.pr_labels:
display("PR labeled to skip smoke tests")
return

if "smokes-required" in self.pr_labels and not any(label.endswith("smoke-tests") for label in self.pr_labels):
sys.exit("Missing smoke tests labels.")
else:
# Labels are empty (nightly/manual snapshot scenario)
if not self.pr_labels:
display("[INFO] No PR labels found. Assuming this is a scheduled or manual test run.")
display("[INFO] Proceeding with full smoke tests...")

if "ok-to-skip-smokes" in self.pr_labels:
display("[INFO] PR labeled with 'ok-to-skip-smokes'. Skipping smoke tests.")
return

display("[INFO] Starting deploy. Label validation was already handled by Tekton.")

self.run_pod()

try:
Expand Down
13 changes: 2 additions & 11 deletions files/bin/deploy.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,27 +135,18 @@ def main() -> None:
components_arg = chain.from_iterable(("--component", component) for component in components)
components_with_resources = os.environ.get("COMPONENTS_W_RESOURCES", "").split()
components_with_resources_arg = chain.from_iterable(("--no-remove-resources", component) for component in components_with_resources)
snapshot_components = {component.name for component in snapshot.components}
deploy_frontends = os.environ.get("DEPLOY_FRONTENDS") or "false"
deploy_timeout = get_timeout("DEPLOY_TIMEOUT", labels)
extra_deploy_args = os.environ.get("EXTRA_DEPLOY_ARGS", "")
optional_deps_method = os.environ.get("OPTIONAL_DEPS_METHOD", "hybrid")
ref_env = os.environ.get("REF_ENV", "insights-production")

if pr_number:
if "run-jenkins-tests" in labels:
display("PR labeled to run Jenkins tests instead of Konflux")
return

if "ok-to-skip-smokes" in labels:
display("PR labeled to skip smoke tests")
display("[INFO] PR labeled with 'ok-to-skip-smokes'. Skipping deploy.")
return

if "koku" in snapshot_components and "smokes-required" in labels and not any(label.endswith("smoke-tests") for label in labels):
sys.exit("Missing smoke tests labels.")

else:
display("[INFO] No PR number found. Assuming nightly/manual test run.")
display("[INFO] No PR number found. Assuming this is a scheduled or manual test run.")
display("[INFO] Proceeding with full smoke tests...")

for secret in ["koku-aws", "koku-gcp"]:
Expand Down