carvel-ytt

module
v0.47.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 9, 2024 License: Apache-2.0

README

logo

OpenSSF Best Practices

ytt

Overview

ytt (pronounced spelled out) is a templating tool that understands YAML structure. It helps you easily configure complex software via reusable templates and user provided values. Ytt includes the following features:

  • Structural templating: understands yaml structure so users can focus on their configuration instead of issues associated with text templating, such as YAML value quoting or manual template indentation
  • Built-in programming language: includes the "fully featured" Python-like programming language Starlark which helps ease the burden of configuring complex software through a richer set of functionality.
  • Reusable configuration: You can reuse the same configuration in different environments by applying environment-specific values.
  • Custom validations: coupled with the fast and deterministic execution, allows you to take advantage of faster feedback loops when creating and testing templates
  • Overlays: this advanced configuration helps users manage the customization required for complex software. For more, see this example in the online playground.
  • Sandboxing: provides a secure, deterministic environment for execution of templates

Try it

To get started with ytt and to see examples, you use the online playground or download the binaries and run the playground locally.

Join the Community and Make Carvel Better

Carvel is better because of our contributors and maintainers. It is because of you that we can bring great software to the community. Please join us during our online community meetings. Details can be found on our Carvel website.

You can chat with us on Kubernetes Slack in the #carvel channel and follow us on Twitter at @carvel_dev.

Check out which organizations are using and contributing to Carvel: Adopter's list

Integrating with ytt

If you want to integrate ytt within your own tooling, review our APIs.

Directories

Path Synopsis
cmd
ytt
pkg
Package pkg is the collection of packages that make up the implementation of ytt.
Package pkg is the collection of packages that make up the implementation of ytt.
cmd
Package cmd is home to the full set of ytt's "commands" -- instances of cobra.Command (not to be confused with ./cmd which contains the bootstrapping for executing ytt in various environments).
Package cmd is home to the full set of ytt's "commands" -- instances of cobra.Command (not to be confused with ./cmd which contains the bootstrapping for executing ytt in various environments).
cmd/template
Package template implements the "template" command (not to be confused with "pkg/template" home of the templating mechanism itself).
Package template implements the "template" command (not to be confused with "pkg/template" home of the templating mechanism itself).
cmd/ui
Package ui provides a thin abstraction over user input and output (typically, a tty device).
Package ui provides a thin abstraction over user input and output (typically, a tty device).
experiments
Package experiments provides a global "Feature Flag" facility for circuit-breaking pre-GA code.
Package experiments provides a global "Feature Flag" facility for circuit-breaking pre-GA code.
filepos
Package filepos provides the concept of Position: a source name (usually a file) and line number within that source.
Package filepos provides the concept of Position: a source name (usually a file) and line number within that source.
files
Package files provides primitives for enumerating and loading data from various file or file-like Source's and for writing output to filesystem files and directories.
Package files provides primitives for enumerating and loading data from various file or file-like Source's and for writing output to filesystem files and directories.
orderedmap
Package orderedmap provides a map implementation where the order of keys is maintained (unlike the native Go map).
Package orderedmap provides a map implementation where the order of keys is maintained (unlike the native Go map).
schema
Package schema enhances yamlmeta.Node structures with fine-grain data types.
Package schema enhances yamlmeta.Node structures with fine-grain data types.
spell
Package spell provides the ability to suggest an exact spelling of a word.
Package spell provides the ability to suggest an exact spelling of a word.
template
Package template provides the core templating engine for ytt.
Package template provides the core templating engine for ytt.
template/core
Package core provides facilities for low-level integration with Starlark.
Package core provides facilities for low-level integration with Starlark.
texttemplate
Package texttemplate implements the text dialect of the ytt templating engine.
Package texttemplate implements the text dialect of the ytt templating engine.
validations
Package validations enriches YAML structures by attaching user-defined constraints (that is, validationRun rules) onto individual yamlmeta.Node's.
Package validations enriches YAML structures by attaching user-defined constraints (that is, validationRun rules) onto individual yamlmeta.Node's.
version
Package version is where the version of the ytt binary is set.
Package version is where the version of the ytt binary is set.
website
Package website provides the web-based Playground via an HTTP webserver.
Package website provides the web-based Playground via an HTTP webserver.
workspace
Package workspace is home to primitives for loading and processing ytt artifacts including the core four steps: pre-processing schema and data values, evaluating templates, and post-processing overlays.
Package workspace is home to primitives for loading and processing ytt artifacts including the core four steps: pre-processing schema and data values, evaluating templates, and post-processing overlays.
workspace/datavalues
Package datavalues integrates the schema and data values features into the workspace, providing a means of "addressing" to specific libraries.
Package datavalues integrates the schema and data values features into the workspace, providing a means of "addressing" to specific libraries.
workspace/ref
Package ref provides the general-purpose ability to mark a document as targeted for specific library.
Package ref provides the general-purpose ability to mark a document as targeted for specific library.
yamlfmt
Package yamlfmt implements the "fmt" command — formatting YAML (preserving comments) into a canonical form.
Package yamlfmt implements the "fmt" command — formatting YAML (preserving comments) into a canonical form.
yamlmeta
Package yamlmeta parses YAML streams into a data structure (tree of yamlmeta.Node's) on which comments and metadata can be attached.
Package yamlmeta parses YAML streams into a data structure (tree of yamlmeta.Node's) on which comments and metadata can be attached.
yamlmeta/internal/yaml.v2
Package yaml implements YAML support for the Go language.
Package yaml implements YAML support for the Go language.
yamltemplate
Package yamltemplate implements the YAML dialect of the ytt templating engine.
Package yamltemplate implements the YAML dialect of the ytt templating engine.
yttlibrary
Package yttlibrary implements the "Standard Library" of modules that are built-in to the ytt templating engine.
Package yttlibrary implements the "Standard Library" of modules that are built-in to the ytt templating engine.
yttlibrary/overlay
Package overlay implements YAML patching via ytt annotations.
Package overlay implements YAML patching via ytt annotations.
yttlibraryext
Package yttlibraryext contains "Standard Library" modules that involve Go module dependencies and therefore are optional or extensions.
Package yttlibraryext contains "Standard Library" modules that involve Go module dependencies and therefore are optional or extensions.
yttlibraryext/toml
Package toml extends the ytt "Standard Library" with the ability to encode and decode text in TOML format.
Package toml extends the ytt "Standard Library" with the ability to encode and decode text in TOML format.
test
filetests
Package filetests houses a test harness for evaluating templates and asserting the expected output.
Package filetests houses a test harness for evaluating templates and asserting the expected output.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL