Skip to content
Branch: master
Find file History
garethr and tekton-robot Added task for Kubeval
Kubeval is a tool used to validate Kubernetes configuration against
the upstream object schemas. This commit adds a `Task` spec for using
Kubeval from Tekton, along with documentation of the parameters and usage.
Latest commit 19aede4 Aug 18, 2019
Permalink
Type Name Latest commit message Commit time
..
Failed to load latest commit information.
README.md Added task for Kubeval Aug 19, 2019
kubeval.yaml Added task for Kubeval Aug 19, 2019

README.md

Kubeval

This task makes it possible to use Kubeval within your Tekton pipelines. Kubeval is a tool used for validating Kubernetes configuration files.

Installation

In order to use Kubeval with Tekton you need to first install the task.

kubectl apply -f https://raw.githubusercontent.com/tektoncd/catalog/master/kubeval/kubeval.yaml

Usage

Once installed, the task can be used as follows:

apiVersion: tekton.dev/v1alpha1
kind: TaskRun
metadata:
  name: kubeval-example
spec:
  taskRef:
    name: kubeval
  inputs:
    resources:
    - name: source
      resourceSpec:
        type: git
        params:
        - name: revision
          value: master
        - name: url
          value: https://github.com/instrumenta/conftest.git

By default the task will recursively scan the provided repository for YAML files and validate them against the Kubernetes schemas. You can change the default behavious, targetting particular directories, files or Kubernetes versions, using the parameters.

Inputs

Parameters

  • files: The files or directories to test to validate against the schemas
  • output: Which output format to use (default: stdout)
  • args: An arrag of additional arguments to pass to Kubeval (_defaultt [])

Resources

  • source: A git-type PipelineResource specifying the location of the source to build.
You can’t perform that action at this time.