ccrd

package
v0.12.0 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2020 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package ccrd generates CustomResourceDefinitions from Crossplane definitions.

v1beta1.JSONSchemaProps is incompatible with controller-tools (as of 0.2.4) because it is missing JSON tags and uses float64, which is a disallowed type. We thus copy the entire struct as CRDSpecTemplate. See the below issue: https://github.com/kubernetes-sigs/controller-tools/issues/291

Index

Constants

View Source
const (
	PublishedInfrastructureSuffixKind     = "Requirement"
	PublishedInfrastructureSuffixListKind = "RequirementList"
	PublishedInfrastructureSuffixSingular = "requirement"
	PublishedInfrastructureSuffixPlural   = "requirements"
)

The kind of a published infrastructure resource is the kind of the defined infrastructure resource combined with these suffixes.

Variables

This section is empty.

Functions

func BaseProps

func BaseProps() map[string]v1beta1.JSONSchemaProps

BaseProps is a partial OpenAPIV3Schema for the spec fields that Crossplane expects to be present for all CRDs that it creates.

func DefinedInfrastructureSpecProps

func DefinedInfrastructureSpecProps() map[string]v1beta1.JSONSchemaProps

DefinedInfrastructureSpecProps is a partial OpenAPIV3Schema for the spec fields that Crossplane expects to be present for all defined infrastructure resources.

func InfrastructurePrinterColumns added in v0.11.0

func InfrastructurePrinterColumns() []v1beta1.CustomResourceColumnDefinition

InfrastructurePrinterColumns returns the set of default printer columns that should exist in all generated composite CRDs.

func InfrastructureStatusProps

func InfrastructureStatusProps() map[string]v1beta1.JSONSchemaProps

InfrastructureStatusProps is a partial OpenAPIV3Schema for the status fields that Crossplane expects to be present for all defined or published infrastructure resources.

func IsEstablished

IsEstablished is a helper function to check whether api-server is ready to accept the instances of registered CRD.

func New

New produces a new CustomResourceDefinition.

func NewSpec

NewSpec produces a CustomResourceDefinitionSpec from the supplied template.

func PublishedInfrastructureSpecProps

func PublishedInfrastructureSpecProps() map[string]v1beta1.JSONSchemaProps

PublishedInfrastructureSpecProps is a partial OpenAPIV3Schema for the spec fields that Crossplane expects to be present for all published infrastructure resources.

func RequirementPrinterColumns added in v0.11.0

func RequirementPrinterColumns() []v1beta1.CustomResourceColumnDefinition

RequirementPrinterColumns returns the set of default printer columns that should exist in all generated requirement CRDs.

Types

type Option

An Option configures the supplied CustomResourceDefinition.

func ForInfrastructureDefinition

func ForInfrastructureDefinition(d *v1alpha1.InfrastructureDefinition) Option

ForInfrastructureDefinition configures the CustomResourceDefinition for the supplied InfrastructureDefinition.

func PublishesInfrastructureDefinition

func PublishesInfrastructureDefinition(d *v1alpha1.InfrastructureDefinition, p *v1alpha1.InfrastructurePublication) Option

PublishesInfrastructureDefinition configures the CustomResourceDefinition that publishes the supplied InfrastructureDefinition.

Jump to

Keyboard shortcuts

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