Files
stage-infra/Tekton/triggers/trigger-template.yaml
2020-03-16 13:04:01 +01:00

36 lines
1.0 KiB
YAML

---
apiVersion: tekton.dev/v1alpha1
kind: TriggerTemplate
metadata:
name: github-trigger-template
spec:
params:
- name: gitrevision
description: The git revision
default: master
- name: gitrepositoryurl
description: The git repository url
- name: gitreponame
description: the name of the git repository
- name: pipelinename
description: name the pipelinerun will have
resourcetemplates:
- apiVersion: tekton.dev/v1alpha1
kind: PipelineRun
metadata:
name: $(inputs.params.pipelinename)
spec:
serviceAccountName: service-acc
pipelineRef:
name: stage-application-pipeline
workspaces:
- name: workspace
persistentVolumeClaim:
claimName: workspace
params:
- name: git-url
value: $(inputs.params.gitrepositoryurl)
- name: branch
value: $(inputs.params.gitrevision)
- name: git-repo-name
value: $(inputs.params.gitreponame)