]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
script/ptl-tool: push branch to shaman for qa runs 56839/head
authorPatrick Donnelly <pdonnell@redhat.com>
Thu, 11 Apr 2024 19:13:10 +0000 (15:13 -0400)
committerPatrick Donnelly <pdonnell@redhat.com>
Thu, 11 Apr 2024 19:20:21 +0000 (15:20 -0400)
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
src/script/ptl-tool.py

index 215db9cc06acf15f0f479ef4d4dc0f59728a7e51..0a152dc74313d40bda9d965bad821473b5f91018 100755 (executable)
@@ -452,7 +452,7 @@ def build_branch(args):
             log.info("Created tag %s" % tag)
 
     if args.create_qa:
-        if created_branch is None:
+        if not created_branch:
             log.error("branch already exists!")
             sys.exit(1)
         project = R.project.get(REDMINE_PROJECT_QA)
@@ -473,7 +473,8 @@ def build_branch(args):
         custom_fields.append({'id': REDMINE_CUSTOM_FIELD_ID_QA_RUNS, 'value': branch})
         custom_fields.append({'id': REDMINE_CUSTOM_FIELD_ID_QA_RELEASE, 'value': args.qa_release})
 
-        G.git.push(CI_REMOTE_URL, tag.name)
+        G.git.push(CI_REMOTE_URL, branch) # for shaman
+        G.git.push(CI_REMOTE_URL, tag.name) # for archival
         origin_url = f'{BASE_PROJECT}/{CI_REPO}/commits/{tag.name}'
         custom_fields.append({'id': REDMINE_CUSTOM_FIELD_ID_GIT_BRANCH, 'value': origin_url})