Introducing tasks
The first Tekton concept to which you will be introduced here is a task. Tasks are the basic building block that you will use to build your larger pipelines.
In a nutshell, tasks should perform a single operation in your CI/CD pipeline. Examples of tasks could include cloning a repository, compiling some code, or running a series of tests. Those tasks can take multiple forms and can be more or less complex, depending on your needs. When building your own, you should also try to make them as reusable as possible.
Tasks are defined with YAML files that describe what you want to achieve. The definition of a task follows the standard for all Kubernetes objects. You will specify the API version to use and the kind of object you are defining. Then add some metadata to identify the task.
As a rule of thumb, your tasks will always start like this:
apiVersion: tekton.dev/v1beta1 kind: Task metadata: name: example-task-name &...