1
0
mirror of https://github.com/tektoncd/catalog.git synced 2024-11-24 06:15:46 +00:00
catalog/task/yq/0.3
vinamra28 e763a4473e Use latest git-clone in Task's tests
With git-clone version 0.8 and onwards, it started running as non-root
and GKE clusters were having some issues, so, we temporarily moved all
tasks to use git-clone version 0.7. Ref: https://github.com/tektoncd/catalog/pull/1079

Since we have now moved to kind clusters in our CI, this issue is now
resolved and thus moving all tasks to use latest version of git-clone

Signed-off-by: vinamra28 <jvinamra776@gmail.com>
2023-09-22 09:32:22 +01:00
..
tests Use latest git-clone in Task's tests 2023-09-22 09:32:22 +01:00
README.md [TEP-0110] Update Tekton Catalog installation instructions 2022-08-16 16:25:52 +01:00
yq.yaml Fix typo in script shebang of yq task 2022-02-03 15:25:05 +00:00

YQ Task

The following task is used to replace a specific field in a yaml in the workspace.

Installing the Task

kubectl apply -f https://api.hub.tekton.dev/v1/resource/tekton/task/yq/0.3/raw

Parameters

  • files: A list of files within the workspace to execute the in-place yq expression on.
  • expression: The actual YQ expression to execute on this file. Checkout the excellent documentation at https://github.com/mikefarah/yq. ="$(params.new-image-sha)"'
  • image: The yq image to use. (default: docker.io/mikefarah/yq:4.16.2@sha256:0d4f6e27bdcac7316f635acd524ab0eecc4ad50834b54d10322268650c7712cb)

Workspaces

  • source : The workspace containing files on which we want to do the replacement on a single file.

Platforms

The Task can be run on linux/amd64 platform.

Usage

For a real usage example checkout the tests directory of this task for an example on how this task can be used on a Github repository. This can be used together with other git actions to commit such changes towards a GitOps repository for example which is automatically reconciled towards your infrastructure.