Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Generator ¶
Generator represents a pipeline for generating example manifests. Generates example manifests for Terraform resources under examples-generated.
func NewGenerator ¶
func NewGenerator(exampleDir, apisModulePath, shortName string, configResources map[string]*config.Resource, opts ...GeneratorOption) *Generator
NewGenerator returns a configured Generator
func (*Generator) Generate ¶
Generate generates an example manifest for the specified Terraform resource.
func (*Generator) StoreExamples ¶
StoreExamples stores the generated example manifests under examples-generated in their respective API groups.
type GeneratorOption ¶
type GeneratorOption func(*Generator)
func WithCRDScope ¶ added in v2.1.0
func WithCRDScope(scope tjtypes.CRDScope) GeneratorOption
WithCRDScope sets the CRD scope for the generator.
func WithLocalSecretRefs ¶
func WithLocalSecretRefs() GeneratorOption
WithLocalSecretRefs configures the example generator to generate examples with local secret references, i.e. no namespace specified.
func WithNamespace ¶ added in v2.1.0
func WithNamespace(ns string) GeneratorOption
WithNamespace configures the example generator to generate example manifests with the specified namespace.