How to reuse steps in Tekton tasks

This page summarizes the projects mentioned and recommended in the original post on dev.to

Our great sponsors
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • SaaSHub - Software Alternatives and Reviews
  • reviewdog

    🐶 Automated code review tool integrated with any code analysis tools regardless of programming language

  • # parameters - op: add path: /spec/params/- value: name: report-file default: reportfile description: Report file with errors - op: add path: /spec/params/- value: name: format default: golint description: Format of error input from the task - op: add path: /spec/params/- value: name: reporter default: local description: Reporter type for reviewdog https://github.com/reviewdog/reviewdog#reporters - op: add path: /spec/params/- value: name: diff default: git diff FETCH_HEAD description: Diff command https://github.com/reviewdog/reviewdog#reporters # workspaces - op: add path: /spec/workspaces/- value: name: token description: | Workspace which contains a token file for Github Pull Request comments. Must have a token file with the Github API access token # steps - op: add path: /spec/steps/- value: name: reviewdog-report image: golangci/golangci-lint:v1.31-alpine # both have the same workspace name workingDir: $(workspaces.source.path) script: | #!/bin/sh set -ue wget -O - -q https://raw.githubusercontent.com/reviewdog/reviewdog/master/install.sh | sh -s -- -b $(go env GOPATH)/bin export REVIEWDOG_GITHUB_API_TOKEN=$(cat $(workspaces.token.path)/token) cat $(params.reportfile) | reviewdog -f=$(params.format) -diff="$(params.diff)"

  • pipeline

    A cloud-native Pipeline resource.

  • Creating Tekton tasks is real fun! Its similiarities to pod containers, and how it works makes developing and testing super easy. Still, sometimes it is necessary to reuse a steps in multiple tasks, like when using reviewdog.

  • WorkOS

    The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.

    WorkOS logo
  • tekton-tasks-kustomize

    Customizing Tekton tasks with kustomize

  • In this post we will learn how to do this very easily using kustomize, and the repo danielfbm/tekton-tasks-kustomize has ready to use example.

  • catalog

    Catalog of shared Tasks and Pipelines. (by tektoncd)

  • The most obvious way would be copying and pasting the steps, but for more complex scenarios, where there are n tasks, this becomes error prone. Using a template engine like helm could help, but learning another templating engine, plus having to change the contents of said tasks also becomes a burden. Instead, kustomize has a set of tools to make this job easier, while enjoying reutilizing tasks from the tektoncd/catalog.

  • helm

    The Kubernetes Package Manager

  • The most obvious way would be copying and pasting the steps, but for more complex scenarios, where there are n tasks, this becomes error prone. Using a template engine like helm could help, but learning another templating engine, plus having to change the contents of said tasks also becomes a burden. Instead, kustomize has a set of tools to make this job easier, while enjoying reutilizing tasks from the tektoncd/catalog.

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts