apiVersion: tekton.dev/v1beta1 kind: Task metadata: name: j7s-git-clone-hash spec: workspaces: - name: output - name: ssh-directory params: - name: url - name: hash steps: - image: harbor.internal.jpace121.net/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 checkout $(params.hash)