Skip to content
This repository has been archived by the owner on Mar 23, 2021. It is now read-only.

imjasonh/cel-task

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🚨 This work has moved 🚨

This functionality is now available in Tekton's experimental repo: https://github.com/tektoncd/experimental/tree/main/cel


This repo provides an experimental Tekton Custom Task that, when run, simply evaluates a CEL expression passed as a parameter, and fails if the result is false, or a non-boolean value, or if the expression is invalid or can't be evaluated.

The intention is to demonstrate the kinds of things a Custom Task can do, and to demonstrate how to write a Custom Task.

Install

Install and configure ko.

ko apply -f controller.yaml

This will build and install the controller on your cluster, in the namespace cel-task.

Run a CEL Task

$ kubectl create -f cel-run.yaml 
run.tekton.dev/cel-run-fqqjt created
$ kubectl get runs
NAME            SUCCEEDED   REASON           STARTTIME   COMPLETIONTIME
cel-run-fqqjt   True        ExpressionTrue   2s          2s

If you change the expression in cel-run.yaml to something that evaluates to false, or an invalid CEL expression, the Task will fail instead.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages