khuedoan-homelab/.tekton/pipelines/pipeline.yaml

73 lines
1.5 KiB
YAML
Raw Normal View History

apiVersion: tekton.dev/v1beta1
kind: Pipeline
metadata:
name: homelab
spec:
workspaces:
- name: shared-data
tasks:
- name: fetch-repo
taskRef:
name: git-clone
workspaces:
- name: output
workspace: shared-data
params:
- name: url
value: http://gitea-http.gitea:3000/ops/homelab
- name: revision
value: master
2021-12-27 00:30:16 +07:00
- name: lint
runAfter:
- fetch-repo
workspaces:
- name: source
workspace: shared-data
taskRef:
name: lint
2021-12-27 00:41:26 +07:00
- name: tools
runAfter:
- fetch-repo
workspaces:
- name: source
workspace: shared-data
# - name: dockerconfig
# workspace: dockerconfig
taskRef:
name: kaniko
params:
- name: CONTEXT
value: ./tools
- name: IMAGE
value: registry.khuedoan.com/tools:latest
- name: EXTRA_ARGS
value:
- --cache=true
- name: external
runAfter:
- fetch-repo
workspaces:
- name: source
workspace: shared-data
taskRef:
name: terraform-external
---
apiVersion: tekton.dev/v1beta1
kind: PipelineRun
metadata:
2021-12-27 00:30:16 +07:00
name: homelab
spec:
serviceAccountName: terraform-sa
pipelineRef:
name: homelab
workspaces:
- name: shared-data
volumeClaimTemplate:
spec:
2021-12-24 18:50:24 +07:00
storageClassName: longhorn
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi