Skip to main content
Testkube 1.21 is out! A new Execution Dashboard, Webhook Credentials and Test/Suite Deprecation are some of the major enhancements, Read More

Templates





Templates allow you to store templates for other resources used in Testkube. We support a list of templates job | container | cronjob | scraper | pvc | webhook | pod. To define templates in Testkube, you'll need to provide a template body (in Golang template format) and a type of the template.

Testkube provides access to the Sprig functions library in templates.

Creating a Template

The template can be created using the API, CLI, or a Custom Resource.

If you prefer to use the API for creating a template, please visit the Core OSS API spec for templates in the doc below.

OpenAPI spec

Using Templates

You will need to refer to a template in the corresponding reference field of the resource.

Check templateReference fields in the Core OSS API spec. For example, Test -> executionRequest -> jobTemplateReference field. OpenAPI spec