Documentation ¶
Index ¶
- func CRD(fs embed.FS, gr metav1.GroupResource) (*apiextensionsv1.CustomResourceDefinition, error)
- func Create(ctx context.Context, ...) error
- func CreateFromFS(ctx context.Context, ...) error
- func CreateSingle(ctx context.Context, ...) error
- func Unmarshal(fileName string, crd *apiextensionsv1.CustomResourceDefinition) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CRD ¶ added in v0.7.0
func CRD(fs embed.FS, gr metav1.GroupResource) (*apiextensionsv1.CustomResourceDefinition, error)
CRD returns an *apiextensionsv1.CustomResourceDefinition for the GroupResource specified by gr from fs. The embedded file's name must have the format <group>_<resource>.yaml.
func Create ¶
func Create(ctx context.Context, client apiextensionsv1client.CustomResourceDefinitionInterface, grs ...metav1.GroupResource) error
Create creates the given CRDs using the target client and waits for all of them to become established in parallel. This call is blocking.
func CreateFromFS ¶
func CreateFromFS(ctx context.Context, client apiextensionsv1client.CustomResourceDefinitionInterface, fs embed.FS, grs ...metav1.GroupResource) error
CreateFromFS creates the given CRDs using the target client from the provided filesystem and waits for it to become established. This call is blocking.
func CreateSingle ¶ added in v0.6.0
func CreateSingle(ctx context.Context, client apiextensionsv1client.CustomResourceDefinitionInterface, rawCRD *apiextensionsv1.CustomResourceDefinition) error
func Unmarshal ¶ added in v0.8.0
func Unmarshal(fileName string, crd *apiextensionsv1.CustomResourceDefinition) error
Unmarshal YAML-decodes the give embedded file name into the target.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.