Help us shape the future of Go! Take the 2026 Go Developer Survey

kustomize

package
v1.9.16 Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2026 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package kustomize builds Kustomizations and merges YAML using Kustomize's libraries. Both read an OpenAPI schema that Kustomize keeps in package-level state and does not fully protect from concurrent use, so this package serializes access to it. Other code should not use those libraries directly.

xref: https://github.com/kubernetes-sigs/kustomize/issues/3659

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Build

func Build(
	fSys filesys.FileSystem,
	path string,
	opts *Options,
	use func(ResMap) error,
) (err error)

Build builds the Kustomization at path in fSys and calls use with the result. Every build starts from Kustomize's default OpenAPI schema, so a custom schema loaded by one build never affects another. A panic during the build or in use is returned as an error.

The ResMap's methods read the schema, so use runs while Build still has exclusive access to it. use must not retain the ResMap, and must not call Build or Merge, which would wait forever for access Build is holding.

func Merge

func Merge(
	src *yaml.RNode,
	dest *yaml.RNode,
	opts yaml.MergeOptions,
) (*yaml.RNode, error)

Merge merges src into dest as kyaml's merge2.Merge does and returns the result. A merge waits for any build or other merge in progress.

Types

type Options

type Options = krusty.Options

Options configures a Build.

type ResMap

type ResMap = resmap.ResMap

ResMap is the result of a Build.

type Resource

type Resource = resource.Resource

Resource is a single resource in a ResMap.

Jump to

Keyboard shortcuts

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