This release is for Go SDK github.com/GoogleContainerTools/kpt-functions-sdk/go/fn@v0.0.1
This version kick-starts the Go SDK to write your own KRM functions in as less as ~10 lines of code.
- The SDK converts STDIN to a
ResourceList
object and provides well handling aroundResourceList
object read/write. The ResourceList specification is defined here - The SDK defines
KubeObject
which is the smallest unit to represent a KRM resource.KubeObject
methods can be called similar to unstructured.Unstructured. For example, you can get/set the MetaType and NameType fields ofKubeObejct
viaGetName
SetNamespace
,GetAnnotation
,GetApiVersion
"IsGVK", or get/set a specific field path viaNestedStringOrDie
SetNestedStringMap
, etc