From 1472f2b5dd83162d3cc3e8159f3a437ebd617695 Mon Sep 17 00:00:00 2001 From: James Pace Date: Sun, 29 Jan 2023 19:51:56 -0500 Subject: [PATCH] rm gerrit tasks. Have no way to test -> no point in supporting. --- tasks/j7s-gerrit-clone.yaml | 23 ----------------------- tasks/j7s-gerrit-notify.yaml | 36 ------------------------------------ 2 files changed, 59 deletions(-) delete mode 100644 tasks/j7s-gerrit-clone.yaml delete mode 100644 tasks/j7s-gerrit-notify.yaml diff --git a/tasks/j7s-gerrit-clone.yaml b/tasks/j7s-gerrit-clone.yaml deleted file mode 100644 index c6a8264..0000000 --- a/tasks/j7s-gerrit-clone.yaml +++ /dev/null @@ -1,23 +0,0 @@ -apiVersion: tekton.dev/v1beta1 -kind: Task -metadata: - name: j7s-gerrit-clone -spec: - workspaces: - - name: output - - name: ssh-directory - params: - - name: url - - name: commit - steps: - - image: 192.168.1.128:8443/gitssh:latest - script: | - set -x - cp -r $(workspaces.ssh-directory.path) ~/.ssh - chmod 700 ~/.ssh - chmod -R 400 ~/.ssh/* - git clone $(params.url) $(workspaces.output.path) - cd $(workspaces.output.path) - git fetch origin $(params.commit) - git checkout -f $(params.commit) -b pr-check - git rebase origin/main \ No newline at end of file diff --git a/tasks/j7s-gerrit-notify.yaml b/tasks/j7s-gerrit-notify.yaml deleted file mode 100644 index a9cf508..0000000 --- a/tasks/j7s-gerrit-notify.yaml +++ /dev/null @@ -1,36 +0,0 @@ -apiVersion: tekton.dev/v1beta1 -kind: Task -metadata: - name: j7s-gerrit-notify -spec: - workspaces: - - name: ssh-directory - params: - - name: commit - - name: build-id - - name: status - - name: feedback_url - - name: feedback_port - steps: - - image: 192.168.1.128:8443/gitssh:latest - script: | - #!/usr/bin/env bash - set -ex - cp -r $(workspaces.ssh-directory.path) ~/.ssh - chmod 700 ~/.ssh - chmod -R 400 ~/.ssh/* - - case "$(params.status)" in - "Succeeded" | "Completed") - ssh -p $(params.feedback_port) $(params.feedback_url) gerrit review \ - -m '"Build succeeded. ID: $(params.build-id)"' \ - --verified +1 \ - $(params.commit) - ;; - "Failed" | "None") - ssh -p $(params.feedback_port) $(params.feedback_url) gerrit review \ - -m '"Build failed. ID: $(params.build-id)"' \ - --verified -1 \ - $(params.commit) - ;; - esac \ No newline at end of file