From a669617e916d0ec53598bd59957dcbd0a77d0f4e Mon Sep 17 00:00:00 2001 From: Charlie Doern Date: Fri, 4 Aug 2023 11:38:15 -0400 Subject: [PATCH] bring in MCO API openshift/api now has an MCO API that needs clients generated for it Signed-off-by: Charlie Doern --- .../config/v1/gcpplatformstatus.go | 32 +- .../applyconfigurations/internal/internal.go | 42 - config/applyconfigurations/utils.go | 4 - go.mod | 2 + go.sum | 4 +- .../applyconfigurations/internal/internal.go | 1 - .../applyconfigurations/internal/internal.go | 147 +- .../v1/ingresscontrollerhttpheaders.go | 9 - .../operator/v1/machineconfiguration.go | 240 +++ .../operator/v1/machineconfigurationspec.go | 84 + .../operator/v1/machineconfigurationstatus.go | 94 ++ operator/applyconfigurations/utils.go | 14 +- .../v1/fake/fake_machineconfiguration.go | 163 ++ .../operator/v1/fake/fake_operator_client.go | 4 + .../typed/operator/v1/generated_expansion.go | 2 + .../typed/operator/v1/machineconfiguration.go | 227 +++ .../typed/operator/v1/operator_client.go | 5 + .../informers/externalversions/generic.go | 2 + .../externalversions/operator/v1/interface.go | 7 + .../operator/v1/machineconfiguration.go | 73 + .../operator/v1/expansion_generated.go | 4 + .../operator/v1/machineconfiguration.go | 52 + .../applyconfigurations/internal/internal.go | 62 - .../applyconfigurations/route/v1/routespec.go | 9 - route/applyconfigurations/utils.go | 10 - ...ersion-operator_01_clusterversion.crd.yaml | 9 +- ...01_infrastructure-CustomNoUpgrade.crd.yaml | 73 - ...frastructure-TechPreviewNoUpgrade.crd.yaml | 73 - .../v1/custom.infrastructure.testsuite.yaml | 371 +---- .../techpreview.infrastructure.testsuite.yaml | 306 ---- .../api/config/v1/types_cluster_version.go | 36 +- .../api/config/v1/types_infrastructure.go | 81 - .../api/config/v1/zz_generated.deepcopy.go | 44 +- .../v1/zz_generated.swagger_doc_generated.go | 29 +- ...ml => 0000_10_consoleclidownload.crd.yaml} | 0 ...> 0000_10_consoleexternalloglink.crd.yaml} | 0 ....crd.yaml => 0000_10_consolelink.crd.yaml} | 0 ...l => 0000_10_consolenotification.crd.yaml} | 0 ...rd.yaml => 0000_10_consoleplugin.crd.yaml} | 0 ...aml => 0000_10_consolequickstart.crd.yaml} | 0 ...rd.yaml => 0000_10_consolesample.crd.yaml} | 0 ...aml => 0000_10_consoleyamlsample.crd.yaml} | 0 .../stable.consoleclidownload.testsuite.yaml | 2 +- ...able.consoleexternalloglink.testsuite.yaml | 2 +- .../v1/stable.consolelink.testsuite.yaml | 2 +- .../stable.consolenotification.testsuite.yaml | 2 +- .../v1/stable.consoleplugin.testsuite.yaml | 2 +- .../stable.consolequickstart.testsuite.yaml | 2 +- .../v1/stable.consolesample.testsuite.yaml | 2 +- .../stable.consoleyamlsample.testsuite.yaml | 2 +- ...rd.yaml => 0000_10_consoleplugin.crd.yaml} | 0 .../stable.consoleplugin.testsuite.yaml | 2 +- .../0000_10_controlplanemachineset.crd.yaml | 5 +- ...olplanemachineset.openstack.testsuite.yaml | 47 +- .../v1/types_controlplanemachineset.go | 11 +- .../v1/zz_generated.swagger_doc_generated.go | 2 +- .../openshift/api/openapi/openapi.json | 449 +++--- ...ess-operator_00-ingresscontroller.crd.yaml | 125 +- ...yaml => 0000_70_console-operator.crd.yaml} | 0 ...machine-config-operator_01_config.crd.yaml | 192 +++ .../openshift/api/operator/v1/register.go | 2 + .../operator/v1/stable.console.testsuite.yaml | 2 +- .../stable.ingresscontroller.testsuite.yaml | 463 ------ ...stable.machineconfiguration.testsuite.yaml | 16 + .../api/operator/v1/types_ingress.go | 138 -- .../operator/v1/types_machineconfiguration.go | 59 + .../api/operator/v1/zz_generated.deepcopy.go | 180 ++- .../v1/zz_generated.swagger_doc_generated.go | 61 +- .../openshift/api/route/v1/generated.pb.go | 1362 ++--------------- .../openshift/api/route/v1/generated.proto | 151 -- .../route/v1/route-CustomNoUpgrade.crd.yaml | 129 +- .../v1/route-TechPreviewNoUpgrade.crd.yaml | 129 +- .../openshift/api/route/v1/route.crd.yaml | 129 +- .../api/route/v1/stable.route.testsuite.yaml | 591 ------- .../openshift/api/route/v1/types.go | 160 -- .../api/route/v1/zz_generated.deepcopy.go | 106 -- .../v1/zz_generated.swagger_doc_generated.go | 51 +- ...rd.yaml => 0000_10_samplesconfig.crd.yaml} | 0 .../samples/v1/stable.config.testsuite.yaml | 2 +- vendor/modules.txt | 3 +- 80 files changed, 1905 insertions(+), 4993 deletions(-) create mode 100644 operator/applyconfigurations/operator/v1/machineconfiguration.go create mode 100644 operator/applyconfigurations/operator/v1/machineconfigurationspec.go create mode 100644 operator/applyconfigurations/operator/v1/machineconfigurationstatus.go create mode 100644 operator/clientset/versioned/typed/operator/v1/fake/fake_machineconfiguration.go create mode 100644 operator/clientset/versioned/typed/operator/v1/machineconfiguration.go create mode 100644 operator/informers/externalversions/operator/v1/machineconfiguration.go create mode 100644 operator/listers/operator/v1/machineconfiguration.go rename vendor/github.com/openshift/api/console/v1/{00_consoleclidownload.crd.yaml => 0000_10_consoleclidownload.crd.yaml} (100%) rename vendor/github.com/openshift/api/console/v1/{00_consoleexternalloglink.crd.yaml => 0000_10_consoleexternalloglink.crd.yaml} (100%) rename vendor/github.com/openshift/api/console/v1/{00_consolelink.crd.yaml => 0000_10_consolelink.crd.yaml} (100%) rename vendor/github.com/openshift/api/console/v1/{00_consolenotification.crd.yaml => 0000_10_consolenotification.crd.yaml} (100%) rename vendor/github.com/openshift/api/console/v1/{90_consoleplugin.crd.yaml => 0000_10_consoleplugin.crd.yaml} (100%) rename vendor/github.com/openshift/api/console/v1/{00_consolequickstart.crd.yaml => 0000_10_consolequickstart.crd.yaml} (100%) rename vendor/github.com/openshift/api/console/v1/{00_consolesample.crd.yaml => 0000_10_consolesample.crd.yaml} (100%) rename vendor/github.com/openshift/api/console/v1/{00_consoleyamlsample.crd.yaml => 0000_10_consoleyamlsample.crd.yaml} (100%) rename vendor/github.com/openshift/api/console/v1alpha1/{90_consoleplugin.crd.yaml => 0000_10_consoleplugin.crd.yaml} (100%) rename vendor/github.com/openshift/api/operator/v1/{00_console-operator.crd.yaml => 0000_70_console-operator.crd.yaml} (100%) create mode 100644 vendor/github.com/openshift/api/operator/v1/0000_80_machine-config-operator_01_config.crd.yaml create mode 100644 vendor/github.com/openshift/api/operator/v1/stable.machineconfiguration.testsuite.yaml create mode 100644 vendor/github.com/openshift/api/operator/v1/types_machineconfiguration.go rename vendor/github.com/openshift/api/samples/v1/{00_samplesconfig.crd.yaml => 0000_10_samplesconfig.crd.yaml} (100%) diff --git a/config/applyconfigurations/config/v1/gcpplatformstatus.go b/config/applyconfigurations/config/v1/gcpplatformstatus.go index c37c88b8d9..fdc2af9f34 100644 --- a/config/applyconfigurations/config/v1/gcpplatformstatus.go +++ b/config/applyconfigurations/config/v1/gcpplatformstatus.go @@ -5,10 +5,8 @@ package v1 // GCPPlatformStatusApplyConfiguration represents an declarative configuration of the GCPPlatformStatus type for use // with apply. type GCPPlatformStatusApplyConfiguration struct { - ProjectID *string `json:"projectID,omitempty"` - Region *string `json:"region,omitempty"` - ResourceLabels []GCPResourceLabelApplyConfiguration `json:"resourceLabels,omitempty"` - ResourceTags []GCPResourceTagApplyConfiguration `json:"resourceTags,omitempty"` + ProjectID *string `json:"projectID,omitempty"` + Region *string `json:"region,omitempty"` } // GCPPlatformStatusApplyConfiguration constructs an declarative configuration of the GCPPlatformStatus type for use with @@ -32,29 +30,3 @@ func (b *GCPPlatformStatusApplyConfiguration) WithRegion(value string) *GCPPlatf b.Region = &value return b } - -// WithResourceLabels adds the given value to the ResourceLabels field in the declarative configuration -// and returns the receiver, so that objects can be build by chaining "With" function invocations. -// If called multiple times, values provided by each call will be appended to the ResourceLabels field. -func (b *GCPPlatformStatusApplyConfiguration) WithResourceLabels(values ...*GCPResourceLabelApplyConfiguration) *GCPPlatformStatusApplyConfiguration { - for i := range values { - if values[i] == nil { - panic("nil value passed to WithResourceLabels") - } - b.ResourceLabels = append(b.ResourceLabels, *values[i]) - } - return b -} - -// WithResourceTags adds the given value to the ResourceTags field in the declarative configuration -// and returns the receiver, so that objects can be build by chaining "With" function invocations. -// If called multiple times, values provided by each call will be appended to the ResourceTags field. -func (b *GCPPlatformStatusApplyConfiguration) WithResourceTags(values ...*GCPResourceTagApplyConfiguration) *GCPPlatformStatusApplyConfiguration { - for i := range values { - if values[i] == nil { - panic("nil value passed to WithResourceTags") - } - b.ResourceTags = append(b.ResourceTags, *values[i]) - } - return b -} diff --git a/config/applyconfigurations/internal/internal.go b/config/applyconfigurations/internal/internal.go index 40ff54fbfc..e914918383 100644 --- a/config/applyconfigurations/internal/internal.go +++ b/config/applyconfigurations/internal/internal.go @@ -1173,48 +1173,6 @@ var schemaYAML = typed.YAMLObject(`types: type: scalar: string default: "" - - name: resourceLabels - type: - list: - elementType: - namedType: com.github.openshift.api.config.v1.GCPResourceLabel - elementRelationship: associative - keys: - - key - - name: resourceTags - type: - list: - elementType: - namedType: com.github.openshift.api.config.v1.GCPResourceTag - elementRelationship: associative - keys: - - key -- name: com.github.openshift.api.config.v1.GCPResourceLabel - map: - fields: - - name: key - type: - scalar: string - default: "" - - name: value - type: - scalar: string - default: "" -- name: com.github.openshift.api.config.v1.GCPResourceTag - map: - fields: - - name: key - type: - scalar: string - default: "" - - name: parentID - type: - scalar: string - default: "" - - name: value - type: - scalar: string - default: "" - name: com.github.openshift.api.config.v1.GitHubIdentityProvider map: fields: diff --git a/config/applyconfigurations/utils.go b/config/applyconfigurations/utils.go index 007752e57b..21907c5dcd 100644 --- a/config/applyconfigurations/utils.go +++ b/config/applyconfigurations/utils.go @@ -151,10 +151,6 @@ func ForKind(kind schema.GroupVersionKind) interface{} { return &configv1.FeatureGateStatusApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("GCPPlatformStatus"): return &configv1.GCPPlatformStatusApplyConfiguration{} - case v1.SchemeGroupVersion.WithKind("GCPResourceLabel"): - return &configv1.GCPResourceLabelApplyConfiguration{} - case v1.SchemeGroupVersion.WithKind("GCPResourceTag"): - return &configv1.GCPResourceTagApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("GitHubIdentityProvider"): return &configv1.GitHubIdentityProviderApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("GitLabIdentityProvider"): diff --git a/go.mod b/go.mod index 552d4387f3..0a02281323 100644 --- a/go.mod +++ b/go.mod @@ -69,3 +69,5 @@ retract v3.9.0+incompatible // To make go aware of the retraction, we need to tag a new version that can be // retracted by itself. retract v0.0.1 + +replace github.com/openshift/api => github.com/jkyros/api v0.0.0-20230804193108-c3f001422ebe diff --git a/go.sum b/go.sum index a396362417..a79d77d59a 100644 --- a/go.sum +++ b/go.sum @@ -134,6 +134,8 @@ github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/imdario/mergo v0.3.6 h1:xTNEAn+kxVO7dTZGu0CegyqKZmoWFI0rF8UxjlB2d28= github.com/imdario/mergo v0.3.6/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA= +github.com/jkyros/api v0.0.0-20230804193108-c3f001422ebe h1:kyDkzRvUWVSh1XecN004yRuTvXiDxvbOM5dMqDYaYtk= +github.com/jkyros/api v0.0.0-20230804193108-c3f001422ebe/go.mod h1:yimSGmjsI+XF1mr+AKBs2//fSXIOhhetHGbMlBEfXbs= github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= @@ -161,8 +163,6 @@ github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/onsi/ginkgo/v2 v2.9.1 h1:zie5Ly042PD3bsCvsSOPvRnFwyo3rKe64TJlD6nu0mk= github.com/onsi/gomega v1.27.4 h1:Z2AnStgsdSayCMDiCU42qIz+HLqEPcgiOCXjAU/w+8E= -github.com/openshift/api v0.0.0-20230807121159-a81c3efc8824 h1:tyXFOOOL6pmacGu9jYjiqjtpMwO8UkIjR9EthRJF5Tk= -github.com/openshift/api v0.0.0-20230807121159-a81c3efc8824/go.mod h1:yimSGmjsI+XF1mr+AKBs2//fSXIOhhetHGbMlBEfXbs= github.com/openshift/build-machinery-go v0.0.0-20220913142420-e25cf57ea46d h1:RR4ah7FfaPR1WePizm0jlrsbmPu91xQZnAsVVreQV1k= github.com/openshift/build-machinery-go v0.0.0-20220913142420-e25cf57ea46d/go.mod h1:b1BuldmJlbA/xYtdZvKi+7j5YGB44qJUJDZ9zwiNCfE= github.com/openshift/kube-openapi v0.0.0-20230324164143-98c122c21a89 h1:+Q//FzVM9TKZkqYAB1IkxQdf6cFiDUDR4YHQPTP20Oo= diff --git a/machine/applyconfigurations/internal/internal.go b/machine/applyconfigurations/internal/internal.go index 1419792cba..641717610b 100644 --- a/machine/applyconfigurations/internal/internal.go +++ b/machine/applyconfigurations/internal/internal.go @@ -273,7 +273,6 @@ var schemaYAML = typed.YAMLObject(`types: - name: volumeType type: scalar: string - default: "" - name: com.github.openshift.api.machine.v1beta1.Condition map: fields: diff --git a/operator/applyconfigurations/internal/internal.go b/operator/applyconfigurations/internal/internal.go index b9be30a192..dec6f78493 100644 --- a/operator/applyconfigurations/internal/internal.go +++ b/operator/applyconfigurations/internal/internal.go @@ -1457,58 +1457,9 @@ var schemaYAML = typed.YAMLObject(`types: elementType: namedType: com.github.openshift.api.operator.v1.IngressControllerCaptureHTTPHeader elementRelationship: atomic -- name: com.github.openshift.api.operator.v1.IngressControllerHTTPHeader - map: - fields: - - name: action - type: - namedType: com.github.openshift.api.operator.v1.IngressControllerHTTPHeaderActionUnion - default: {} - - name: name - type: - scalar: string - default: "" -- name: com.github.openshift.api.operator.v1.IngressControllerHTTPHeaderActionUnion - map: - fields: - - name: set - type: - namedType: com.github.openshift.api.operator.v1.IngressControllerSetHTTPHeader - - name: type - type: - scalar: string - default: "" - unions: - - discriminator: type - fields: - - fieldName: set - discriminatorValue: Set -- name: com.github.openshift.api.operator.v1.IngressControllerHTTPHeaderActions - map: - fields: - - name: request - type: - list: - elementType: - namedType: com.github.openshift.api.operator.v1.IngressControllerHTTPHeader - elementRelationship: associative - keys: - - name - - name: response - type: - list: - elementType: - namedType: com.github.openshift.api.operator.v1.IngressControllerHTTPHeader - elementRelationship: associative - keys: - - name - name: com.github.openshift.api.operator.v1.IngressControllerHTTPHeaders map: fields: - - name: actions - type: - namedType: com.github.openshift.api.operator.v1.IngressControllerHTTPHeaderActions - default: {} - name: forwardedHeaderPolicy type: scalar: string @@ -1537,13 +1488,6 @@ var schemaYAML = typed.YAMLObject(`types: - name: access type: namedType: com.github.openshift.api.operator.v1.AccessLogging -- name: com.github.openshift.api.operator.v1.IngressControllerSetHTTPHeader - map: - fields: - - name: value - type: - scalar: string - default: "" - name: com.github.openshift.api.operator.v1.IngressControllerSpec map: fields: @@ -2201,6 +2145,97 @@ var schemaYAML = typed.YAMLObject(`types: - name: to type: scalar: numeric +- name: com.github.openshift.api.operator.v1.MachineConfiguration + map: + fields: + - name: apiVersion + type: + scalar: string + - name: kind + type: + scalar: string + - name: metadata + type: + namedType: io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta + default: {} + - name: spec + type: + namedType: com.github.openshift.api.operator.v1.MachineConfigurationSpec + default: {} + - name: status + type: + namedType: com.github.openshift.api.operator.v1.MachineConfigurationStatus + default: {} +- name: com.github.openshift.api.operator.v1.MachineConfigurationSpec + map: + fields: + - name: failedRevisionLimit + type: + scalar: numeric + - name: forceRedeploymentReason + type: + scalar: string + default: "" + - name: logLevel + type: + scalar: string + - name: managementState + type: + scalar: string + default: "" + - name: observedConfig + type: + namedType: __untyped_atomic_ + default: {} + - name: operatorLogLevel + type: + scalar: string + - name: succeededRevisionLimit + type: + scalar: numeric + - name: unsupportedConfigOverrides + type: + namedType: __untyped_atomic_ + default: {} +- name: com.github.openshift.api.operator.v1.MachineConfigurationStatus + map: + fields: + - name: conditions + type: + list: + elementType: + namedType: com.github.openshift.api.operator.v1.OperatorCondition + elementRelationship: atomic + - name: generations + type: + list: + elementType: + namedType: com.github.openshift.api.operator.v1.GenerationStatus + elementRelationship: atomic + - name: latestAvailableRevision + type: + scalar: numeric + default: 0 + - name: latestAvailableRevisionReason + type: + scalar: string + default: "" + - name: nodeStatuses + type: + list: + elementType: + namedType: com.github.openshift.api.operator.v1.NodeStatus + elementRelationship: atomic + - name: observedGeneration + type: + scalar: numeric + - name: readyReplicas + type: + scalar: numeric + default: 0 + - name: version + type: + scalar: string - name: com.github.openshift.api.operator.v1.NetFlowConfig map: fields: diff --git a/operator/applyconfigurations/operator/v1/ingresscontrollerhttpheaders.go b/operator/applyconfigurations/operator/v1/ingresscontrollerhttpheaders.go index 983372140f..ad1d2eb22a 100644 --- a/operator/applyconfigurations/operator/v1/ingresscontrollerhttpheaders.go +++ b/operator/applyconfigurations/operator/v1/ingresscontrollerhttpheaders.go @@ -12,7 +12,6 @@ type IngressControllerHTTPHeadersApplyConfiguration struct { ForwardedHeaderPolicy *v1.IngressControllerHTTPHeaderPolicy `json:"forwardedHeaderPolicy,omitempty"` UniqueId *IngressControllerHTTPUniqueIdHeaderPolicyApplyConfiguration `json:"uniqueId,omitempty"` HeaderNameCaseAdjustments []v1.IngressControllerHTTPHeaderNameCaseAdjustment `json:"headerNameCaseAdjustments,omitempty"` - Actions *IngressControllerHTTPHeaderActionsApplyConfiguration `json:"actions,omitempty"` } // IngressControllerHTTPHeadersApplyConfiguration constructs an declarative configuration of the IngressControllerHTTPHeaders type for use with @@ -46,11 +45,3 @@ func (b *IngressControllerHTTPHeadersApplyConfiguration) WithHeaderNameCaseAdjus } return b } - -// WithActions sets the Actions field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Actions field is set to the value of the last call. -func (b *IngressControllerHTTPHeadersApplyConfiguration) WithActions(value *IngressControllerHTTPHeaderActionsApplyConfiguration) *IngressControllerHTTPHeadersApplyConfiguration { - b.Actions = value - return b -} diff --git a/operator/applyconfigurations/operator/v1/machineconfiguration.go b/operator/applyconfigurations/operator/v1/machineconfiguration.go new file mode 100644 index 0000000000..5865b0a6da --- /dev/null +++ b/operator/applyconfigurations/operator/v1/machineconfiguration.go @@ -0,0 +1,240 @@ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1 + +import ( + apioperatorv1 "github.com/openshift/api/operator/v1" + internal "github.com/openshift/client-go/operator/applyconfigurations/internal" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + managedfields "k8s.io/apimachinery/pkg/util/managedfields" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// MachineConfigurationApplyConfiguration represents an declarative configuration of the MachineConfiguration type for use +// with apply. +type MachineConfigurationApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *MachineConfigurationSpecApplyConfiguration `json:"spec,omitempty"` + Status *MachineConfigurationStatusApplyConfiguration `json:"status,omitempty"` +} + +// MachineConfiguration constructs an declarative configuration of the MachineConfiguration type for use with +// apply. +func MachineConfiguration(name string) *MachineConfigurationApplyConfiguration { + b := &MachineConfigurationApplyConfiguration{} + b.WithName(name) + b.WithKind("MachineConfiguration") + b.WithAPIVersion("operator.openshift.io/v1") + return b +} + +// ExtractMachineConfiguration extracts the applied configuration owned by fieldManager from +// machineConfiguration. If no managedFields are found in machineConfiguration for fieldManager, a +// MachineConfigurationApplyConfiguration is returned with only the Name, Namespace (if applicable), +// APIVersion and Kind populated. It is possible that no managed fields were found for because other +// field managers have taken ownership of all the fields previously owned by fieldManager, or because +// the fieldManager never owned fields any fields. +// machineConfiguration must be a unmodified MachineConfiguration API object that was retrieved from the Kubernetes API. +// ExtractMachineConfiguration provides a way to perform a extract/modify-in-place/apply workflow. +// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously +// applied if another fieldManager has updated or force applied any of the previously applied fields. +// Experimental! +func ExtractMachineConfiguration(machineConfiguration *apioperatorv1.MachineConfiguration, fieldManager string) (*MachineConfigurationApplyConfiguration, error) { + return extractMachineConfiguration(machineConfiguration, fieldManager, "") +} + +// ExtractMachineConfigurationStatus is the same as ExtractMachineConfiguration except +// that it extracts the status subresource applied configuration. +// Experimental! +func ExtractMachineConfigurationStatus(machineConfiguration *apioperatorv1.MachineConfiguration, fieldManager string) (*MachineConfigurationApplyConfiguration, error) { + return extractMachineConfiguration(machineConfiguration, fieldManager, "status") +} + +func extractMachineConfiguration(machineConfiguration *apioperatorv1.MachineConfiguration, fieldManager string, subresource string) (*MachineConfigurationApplyConfiguration, error) { + b := &MachineConfigurationApplyConfiguration{} + err := managedfields.ExtractInto(machineConfiguration, internal.Parser().Type("com.github.openshift.api.operator.v1.MachineConfiguration"), fieldManager, b, subresource) + if err != nil { + return nil, err + } + b.WithName(machineConfiguration.Name) + + b.WithKind("MachineConfiguration") + b.WithAPIVersion("operator.openshift.io/v1") + return b, nil +} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *MachineConfigurationApplyConfiguration) WithKind(value string) *MachineConfigurationApplyConfiguration { + b.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *MachineConfigurationApplyConfiguration) WithAPIVersion(value string) *MachineConfigurationApplyConfiguration { + b.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *MachineConfigurationApplyConfiguration) WithName(value string) *MachineConfigurationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *MachineConfigurationApplyConfiguration) WithGenerateName(value string) *MachineConfigurationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *MachineConfigurationApplyConfiguration) WithNamespace(value string) *MachineConfigurationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *MachineConfigurationApplyConfiguration) WithUID(value types.UID) *MachineConfigurationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *MachineConfigurationApplyConfiguration) WithResourceVersion(value string) *MachineConfigurationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *MachineConfigurationApplyConfiguration) WithGeneration(value int64) *MachineConfigurationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *MachineConfigurationApplyConfiguration) WithCreationTimestamp(value metav1.Time) *MachineConfigurationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *MachineConfigurationApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *MachineConfigurationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *MachineConfigurationApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *MachineConfigurationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *MachineConfigurationApplyConfiguration) WithLabels(entries map[string]string) *MachineConfigurationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.Labels == nil && len(entries) > 0 { + b.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *MachineConfigurationApplyConfiguration) WithAnnotations(entries map[string]string) *MachineConfigurationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.Annotations == nil && len(entries) > 0 { + b.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *MachineConfigurationApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *MachineConfigurationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.OwnerReferences = append(b.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *MachineConfigurationApplyConfiguration) WithFinalizers(values ...string) *MachineConfigurationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.Finalizers = append(b.Finalizers, values[i]) + } + return b +} + +func (b *MachineConfigurationApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *MachineConfigurationApplyConfiguration) WithSpec(value *MachineConfigurationSpecApplyConfiguration) *MachineConfigurationApplyConfiguration { + b.Spec = value + return b +} + +// WithStatus sets the Status field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Status field is set to the value of the last call. +func (b *MachineConfigurationApplyConfiguration) WithStatus(value *MachineConfigurationStatusApplyConfiguration) *MachineConfigurationApplyConfiguration { + b.Status = value + return b +} diff --git a/operator/applyconfigurations/operator/v1/machineconfigurationspec.go b/operator/applyconfigurations/operator/v1/machineconfigurationspec.go new file mode 100644 index 0000000000..4ca52827eb --- /dev/null +++ b/operator/applyconfigurations/operator/v1/machineconfigurationspec.go @@ -0,0 +1,84 @@ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1 + +import ( + operatorv1 "github.com/openshift/api/operator/v1" + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// MachineConfigurationSpecApplyConfiguration represents an declarative configuration of the MachineConfigurationSpec type for use +// with apply. +type MachineConfigurationSpecApplyConfiguration struct { + StaticPodOperatorSpecApplyConfiguration `json:",inline"` +} + +// MachineConfigurationSpecApplyConfiguration constructs an declarative configuration of the MachineConfigurationSpec type for use with +// apply. +func MachineConfigurationSpec() *MachineConfigurationSpecApplyConfiguration { + return &MachineConfigurationSpecApplyConfiguration{} +} + +// WithManagementState sets the ManagementState field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ManagementState field is set to the value of the last call. +func (b *MachineConfigurationSpecApplyConfiguration) WithManagementState(value operatorv1.ManagementState) *MachineConfigurationSpecApplyConfiguration { + b.ManagementState = &value + return b +} + +// WithLogLevel sets the LogLevel field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the LogLevel field is set to the value of the last call. +func (b *MachineConfigurationSpecApplyConfiguration) WithLogLevel(value operatorv1.LogLevel) *MachineConfigurationSpecApplyConfiguration { + b.LogLevel = &value + return b +} + +// WithOperatorLogLevel sets the OperatorLogLevel field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the OperatorLogLevel field is set to the value of the last call. +func (b *MachineConfigurationSpecApplyConfiguration) WithOperatorLogLevel(value operatorv1.LogLevel) *MachineConfigurationSpecApplyConfiguration { + b.OperatorLogLevel = &value + return b +} + +// WithUnsupportedConfigOverrides sets the UnsupportedConfigOverrides field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UnsupportedConfigOverrides field is set to the value of the last call. +func (b *MachineConfigurationSpecApplyConfiguration) WithUnsupportedConfigOverrides(value runtime.RawExtension) *MachineConfigurationSpecApplyConfiguration { + b.UnsupportedConfigOverrides = &value + return b +} + +// WithObservedConfig sets the ObservedConfig field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ObservedConfig field is set to the value of the last call. +func (b *MachineConfigurationSpecApplyConfiguration) WithObservedConfig(value runtime.RawExtension) *MachineConfigurationSpecApplyConfiguration { + b.ObservedConfig = &value + return b +} + +// WithForceRedeploymentReason sets the ForceRedeploymentReason field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ForceRedeploymentReason field is set to the value of the last call. +func (b *MachineConfigurationSpecApplyConfiguration) WithForceRedeploymentReason(value string) *MachineConfigurationSpecApplyConfiguration { + b.ForceRedeploymentReason = &value + return b +} + +// WithFailedRevisionLimit sets the FailedRevisionLimit field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the FailedRevisionLimit field is set to the value of the last call. +func (b *MachineConfigurationSpecApplyConfiguration) WithFailedRevisionLimit(value int32) *MachineConfigurationSpecApplyConfiguration { + b.FailedRevisionLimit = &value + return b +} + +// WithSucceededRevisionLimit sets the SucceededRevisionLimit field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the SucceededRevisionLimit field is set to the value of the last call. +func (b *MachineConfigurationSpecApplyConfiguration) WithSucceededRevisionLimit(value int32) *MachineConfigurationSpecApplyConfiguration { + b.SucceededRevisionLimit = &value + return b +} diff --git a/operator/applyconfigurations/operator/v1/machineconfigurationstatus.go b/operator/applyconfigurations/operator/v1/machineconfigurationstatus.go new file mode 100644 index 0000000000..5740627b4b --- /dev/null +++ b/operator/applyconfigurations/operator/v1/machineconfigurationstatus.go @@ -0,0 +1,94 @@ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1 + +// MachineConfigurationStatusApplyConfiguration represents an declarative configuration of the MachineConfigurationStatus type for use +// with apply. +type MachineConfigurationStatusApplyConfiguration struct { + StaticPodOperatorStatusApplyConfiguration `json:",inline"` +} + +// MachineConfigurationStatusApplyConfiguration constructs an declarative configuration of the MachineConfigurationStatus type for use with +// apply. +func MachineConfigurationStatus() *MachineConfigurationStatusApplyConfiguration { + return &MachineConfigurationStatusApplyConfiguration{} +} + +// WithObservedGeneration sets the ObservedGeneration field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ObservedGeneration field is set to the value of the last call. +func (b *MachineConfigurationStatusApplyConfiguration) WithObservedGeneration(value int64) *MachineConfigurationStatusApplyConfiguration { + b.ObservedGeneration = &value + return b +} + +// WithConditions adds the given value to the Conditions field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Conditions field. +func (b *MachineConfigurationStatusApplyConfiguration) WithConditions(values ...*OperatorConditionApplyConfiguration) *MachineConfigurationStatusApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithConditions") + } + b.Conditions = append(b.Conditions, *values[i]) + } + return b +} + +// WithVersion sets the Version field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Version field is set to the value of the last call. +func (b *MachineConfigurationStatusApplyConfiguration) WithVersion(value string) *MachineConfigurationStatusApplyConfiguration { + b.Version = &value + return b +} + +// WithReadyReplicas sets the ReadyReplicas field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ReadyReplicas field is set to the value of the last call. +func (b *MachineConfigurationStatusApplyConfiguration) WithReadyReplicas(value int32) *MachineConfigurationStatusApplyConfiguration { + b.ReadyReplicas = &value + return b +} + +// WithGenerations adds the given value to the Generations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Generations field. +func (b *MachineConfigurationStatusApplyConfiguration) WithGenerations(values ...*GenerationStatusApplyConfiguration) *MachineConfigurationStatusApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithGenerations") + } + b.Generations = append(b.Generations, *values[i]) + } + return b +} + +// WithLatestAvailableRevision sets the LatestAvailableRevision field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the LatestAvailableRevision field is set to the value of the last call. +func (b *MachineConfigurationStatusApplyConfiguration) WithLatestAvailableRevision(value int32) *MachineConfigurationStatusApplyConfiguration { + b.LatestAvailableRevision = &value + return b +} + +// WithLatestAvailableRevisionReason sets the LatestAvailableRevisionReason field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the LatestAvailableRevisionReason field is set to the value of the last call. +func (b *MachineConfigurationStatusApplyConfiguration) WithLatestAvailableRevisionReason(value string) *MachineConfigurationStatusApplyConfiguration { + b.LatestAvailableRevisionReason = &value + return b +} + +// WithNodeStatuses adds the given value to the NodeStatuses field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the NodeStatuses field. +func (b *MachineConfigurationStatusApplyConfiguration) WithNodeStatuses(values ...*NodeStatusApplyConfiguration) *MachineConfigurationStatusApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithNodeStatuses") + } + b.NodeStatuses = append(b.NodeStatuses, *values[i]) + } + return b +} diff --git a/operator/applyconfigurations/utils.go b/operator/applyconfigurations/utils.go index 308542aea4..3c1c32afda 100644 --- a/operator/applyconfigurations/utils.go +++ b/operator/applyconfigurations/utils.go @@ -155,20 +155,12 @@ func ForKind(kind schema.GroupVersionKind) interface{} { return &operatorv1.IngressControllerCaptureHTTPHeaderApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("IngressControllerCaptureHTTPHeaders"): return &operatorv1.IngressControllerCaptureHTTPHeadersApplyConfiguration{} - case v1.SchemeGroupVersion.WithKind("IngressControllerHTTPHeader"): - return &operatorv1.IngressControllerHTTPHeaderApplyConfiguration{} - case v1.SchemeGroupVersion.WithKind("IngressControllerHTTPHeaderActions"): - return &operatorv1.IngressControllerHTTPHeaderActionsApplyConfiguration{} - case v1.SchemeGroupVersion.WithKind("IngressControllerHTTPHeaderActionUnion"): - return &operatorv1.IngressControllerHTTPHeaderActionUnionApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("IngressControllerHTTPHeaders"): return &operatorv1.IngressControllerHTTPHeadersApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("IngressControllerHTTPUniqueIdHeaderPolicy"): return &operatorv1.IngressControllerHTTPUniqueIdHeaderPolicyApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("IngressControllerLogging"): return &operatorv1.IngressControllerLoggingApplyConfiguration{} - case v1.SchemeGroupVersion.WithKind("IngressControllerSetHTTPHeader"): - return &operatorv1.IngressControllerSetHTTPHeaderApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("IngressControllerSpec"): return &operatorv1.IngressControllerSpecApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("IngressControllerStatus"): @@ -217,6 +209,12 @@ func ForKind(kind schema.GroupVersionKind) interface{} { return &operatorv1.LoadBalancerStrategyApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("LoggingDestination"): return &operatorv1.LoggingDestinationApplyConfiguration{} + case v1.SchemeGroupVersion.WithKind("MachineConfiguration"): + return &operatorv1.MachineConfigurationApplyConfiguration{} + case v1.SchemeGroupVersion.WithKind("MachineConfigurationSpec"): + return &operatorv1.MachineConfigurationSpecApplyConfiguration{} + case v1.SchemeGroupVersion.WithKind("MachineConfigurationStatus"): + return &operatorv1.MachineConfigurationStatusApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("MTUMigration"): return &operatorv1.MTUMigrationApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("MTUMigrationValues"): diff --git a/operator/clientset/versioned/typed/operator/v1/fake/fake_machineconfiguration.go b/operator/clientset/versioned/typed/operator/v1/fake/fake_machineconfiguration.go new file mode 100644 index 0000000000..3fcad8a763 --- /dev/null +++ b/operator/clientset/versioned/typed/operator/v1/fake/fake_machineconfiguration.go @@ -0,0 +1,163 @@ +// Code generated by client-gen. DO NOT EDIT. + +package fake + +import ( + "context" + json "encoding/json" + "fmt" + + operatorv1 "github.com/openshift/api/operator/v1" + applyconfigurationsoperatorv1 "github.com/openshift/client-go/operator/applyconfigurations/operator/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + labels "k8s.io/apimachinery/pkg/labels" + schema "k8s.io/apimachinery/pkg/runtime/schema" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + testing "k8s.io/client-go/testing" +) + +// FakeMachineConfigurations implements MachineConfigurationInterface +type FakeMachineConfigurations struct { + Fake *FakeOperatorV1 +} + +var machineconfigurationsResource = schema.GroupVersionResource{Group: "operator.openshift.io", Version: "v1", Resource: "machineconfigurations"} + +var machineconfigurationsKind = schema.GroupVersionKind{Group: "operator.openshift.io", Version: "v1", Kind: "MachineConfiguration"} + +// Get takes name of the machineConfiguration, and returns the corresponding machineConfiguration object, and an error if there is any. +func (c *FakeMachineConfigurations) Get(ctx context.Context, name string, options v1.GetOptions) (result *operatorv1.MachineConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewRootGetAction(machineconfigurationsResource, name), &operatorv1.MachineConfiguration{}) + if obj == nil { + return nil, err + } + return obj.(*operatorv1.MachineConfiguration), err +} + +// List takes label and field selectors, and returns the list of MachineConfigurations that match those selectors. +func (c *FakeMachineConfigurations) List(ctx context.Context, opts v1.ListOptions) (result *operatorv1.MachineConfigurationList, err error) { + obj, err := c.Fake. + Invokes(testing.NewRootListAction(machineconfigurationsResource, machineconfigurationsKind, opts), &operatorv1.MachineConfigurationList{}) + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &operatorv1.MachineConfigurationList{ListMeta: obj.(*operatorv1.MachineConfigurationList).ListMeta} + for _, item := range obj.(*operatorv1.MachineConfigurationList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +// Watch returns a watch.Interface that watches the requested machineConfigurations. +func (c *FakeMachineConfigurations) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) { + return c.Fake. + InvokesWatch(testing.NewRootWatchAction(machineconfigurationsResource, opts)) +} + +// Create takes the representation of a machineConfiguration and creates it. Returns the server's representation of the machineConfiguration, and an error, if there is any. +func (c *FakeMachineConfigurations) Create(ctx context.Context, machineConfiguration *operatorv1.MachineConfiguration, opts v1.CreateOptions) (result *operatorv1.MachineConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewRootCreateAction(machineconfigurationsResource, machineConfiguration), &operatorv1.MachineConfiguration{}) + if obj == nil { + return nil, err + } + return obj.(*operatorv1.MachineConfiguration), err +} + +// Update takes the representation of a machineConfiguration and updates it. Returns the server's representation of the machineConfiguration, and an error, if there is any. +func (c *FakeMachineConfigurations) Update(ctx context.Context, machineConfiguration *operatorv1.MachineConfiguration, opts v1.UpdateOptions) (result *operatorv1.MachineConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewRootUpdateAction(machineconfigurationsResource, machineConfiguration), &operatorv1.MachineConfiguration{}) + if obj == nil { + return nil, err + } + return obj.(*operatorv1.MachineConfiguration), err +} + +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). +func (c *FakeMachineConfigurations) UpdateStatus(ctx context.Context, machineConfiguration *operatorv1.MachineConfiguration, opts v1.UpdateOptions) (*operatorv1.MachineConfiguration, error) { + obj, err := c.Fake. + Invokes(testing.NewRootUpdateSubresourceAction(machineconfigurationsResource, "status", machineConfiguration), &operatorv1.MachineConfiguration{}) + if obj == nil { + return nil, err + } + return obj.(*operatorv1.MachineConfiguration), err +} + +// Delete takes name of the machineConfiguration and deletes it. Returns an error if one occurs. +func (c *FakeMachineConfigurations) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error { + _, err := c.Fake. + Invokes(testing.NewRootDeleteActionWithOptions(machineconfigurationsResource, name, opts), &operatorv1.MachineConfiguration{}) + return err +} + +// DeleteCollection deletes a collection of objects. +func (c *FakeMachineConfigurations) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error { + action := testing.NewRootDeleteCollectionAction(machineconfigurationsResource, listOpts) + + _, err := c.Fake.Invokes(action, &operatorv1.MachineConfigurationList{}) + return err +} + +// Patch applies the patch and returns the patched machineConfiguration. +func (c *FakeMachineConfigurations) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *operatorv1.MachineConfiguration, err error) { + obj, err := c.Fake. + Invokes(testing.NewRootPatchSubresourceAction(machineconfigurationsResource, name, pt, data, subresources...), &operatorv1.MachineConfiguration{}) + if obj == nil { + return nil, err + } + return obj.(*operatorv1.MachineConfiguration), err +} + +// Apply takes the given apply declarative configuration, applies it and returns the applied machineConfiguration. +func (c *FakeMachineConfigurations) Apply(ctx context.Context, machineConfiguration *applyconfigurationsoperatorv1.MachineConfigurationApplyConfiguration, opts v1.ApplyOptions) (result *operatorv1.MachineConfiguration, err error) { + if machineConfiguration == nil { + return nil, fmt.Errorf("machineConfiguration provided to Apply must not be nil") + } + data, err := json.Marshal(machineConfiguration) + if err != nil { + return nil, err + } + name := machineConfiguration.Name + if name == nil { + return nil, fmt.Errorf("machineConfiguration.Name must be provided to Apply") + } + obj, err := c.Fake. + Invokes(testing.NewRootPatchSubresourceAction(machineconfigurationsResource, *name, types.ApplyPatchType, data), &operatorv1.MachineConfiguration{}) + if obj == nil { + return nil, err + } + return obj.(*operatorv1.MachineConfiguration), err +} + +// ApplyStatus was generated because the type contains a Status member. +// Add a +genclient:noStatus comment above the type to avoid generating ApplyStatus(). +func (c *FakeMachineConfigurations) ApplyStatus(ctx context.Context, machineConfiguration *applyconfigurationsoperatorv1.MachineConfigurationApplyConfiguration, opts v1.ApplyOptions) (result *operatorv1.MachineConfiguration, err error) { + if machineConfiguration == nil { + return nil, fmt.Errorf("machineConfiguration provided to Apply must not be nil") + } + data, err := json.Marshal(machineConfiguration) + if err != nil { + return nil, err + } + name := machineConfiguration.Name + if name == nil { + return nil, fmt.Errorf("machineConfiguration.Name must be provided to Apply") + } + obj, err := c.Fake. + Invokes(testing.NewRootPatchSubresourceAction(machineconfigurationsResource, *name, types.ApplyPatchType, data, "status"), &operatorv1.MachineConfiguration{}) + if obj == nil { + return nil, err + } + return obj.(*operatorv1.MachineConfiguration), err +} diff --git a/operator/clientset/versioned/typed/operator/v1/fake/fake_operator_client.go b/operator/clientset/versioned/typed/operator/v1/fake/fake_operator_client.go index a20955e54a..45d39303ed 100644 --- a/operator/clientset/versioned/typed/operator/v1/fake/fake_operator_client.go +++ b/operator/clientset/versioned/typed/operator/v1/fake/fake_operator_client.go @@ -68,6 +68,10 @@ func (c *FakeOperatorV1) KubeStorageVersionMigrators() v1.KubeStorageVersionMigr return &FakeKubeStorageVersionMigrators{c} } +func (c *FakeOperatorV1) MachineConfigurations() v1.MachineConfigurationInterface { + return &FakeMachineConfigurations{c} +} + func (c *FakeOperatorV1) Networks() v1.NetworkInterface { return &FakeNetworks{c} } diff --git a/operator/clientset/versioned/typed/operator/v1/generated_expansion.go b/operator/clientset/versioned/typed/operator/v1/generated_expansion.go index 025a746b6d..dd8a5efd39 100644 --- a/operator/clientset/versioned/typed/operator/v1/generated_expansion.go +++ b/operator/clientset/versioned/typed/operator/v1/generated_expansion.go @@ -30,6 +30,8 @@ type KubeSchedulerExpansion interface{} type KubeStorageVersionMigratorExpansion interface{} +type MachineConfigurationExpansion interface{} + type NetworkExpansion interface{} type OpenShiftAPIServerExpansion interface{} diff --git a/operator/clientset/versioned/typed/operator/v1/machineconfiguration.go b/operator/clientset/versioned/typed/operator/v1/machineconfiguration.go new file mode 100644 index 0000000000..3ab0d46bed --- /dev/null +++ b/operator/clientset/versioned/typed/operator/v1/machineconfiguration.go @@ -0,0 +1,227 @@ +// Code generated by client-gen. DO NOT EDIT. + +package v1 + +import ( + "context" + json "encoding/json" + "fmt" + "time" + + v1 "github.com/openshift/api/operator/v1" + operatorv1 "github.com/openshift/client-go/operator/applyconfigurations/operator/v1" + scheme "github.com/openshift/client-go/operator/clientset/versioned/scheme" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" +) + +// MachineConfigurationsGetter has a method to return a MachineConfigurationInterface. +// A group's client should implement this interface. +type MachineConfigurationsGetter interface { + MachineConfigurations() MachineConfigurationInterface +} + +// MachineConfigurationInterface has methods to work with MachineConfiguration resources. +type MachineConfigurationInterface interface { + Create(ctx context.Context, machineConfiguration *v1.MachineConfiguration, opts metav1.CreateOptions) (*v1.MachineConfiguration, error) + Update(ctx context.Context, machineConfiguration *v1.MachineConfiguration, opts metav1.UpdateOptions) (*v1.MachineConfiguration, error) + UpdateStatus(ctx context.Context, machineConfiguration *v1.MachineConfiguration, opts metav1.UpdateOptions) (*v1.MachineConfiguration, error) + Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error + DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error + Get(ctx context.Context, name string, opts metav1.GetOptions) (*v1.MachineConfiguration, error) + List(ctx context.Context, opts metav1.ListOptions) (*v1.MachineConfigurationList, error) + Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) + Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (result *v1.MachineConfiguration, err error) + Apply(ctx context.Context, machineConfiguration *operatorv1.MachineConfigurationApplyConfiguration, opts metav1.ApplyOptions) (result *v1.MachineConfiguration, err error) + ApplyStatus(ctx context.Context, machineConfiguration *operatorv1.MachineConfigurationApplyConfiguration, opts metav1.ApplyOptions) (result *v1.MachineConfiguration, err error) + MachineConfigurationExpansion +} + +// machineConfigurations implements MachineConfigurationInterface +type machineConfigurations struct { + client rest.Interface +} + +// newMachineConfigurations returns a MachineConfigurations +func newMachineConfigurations(c *OperatorV1Client) *machineConfigurations { + return &machineConfigurations{ + client: c.RESTClient(), + } +} + +// Get takes name of the machineConfiguration, and returns the corresponding machineConfiguration object, and an error if there is any. +func (c *machineConfigurations) Get(ctx context.Context, name string, options metav1.GetOptions) (result *v1.MachineConfiguration, err error) { + result = &v1.MachineConfiguration{} + err = c.client.Get(). + Resource("machineconfigurations"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(ctx). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of MachineConfigurations that match those selectors. +func (c *machineConfigurations) List(ctx context.Context, opts metav1.ListOptions) (result *v1.MachineConfigurationList, err error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + result = &v1.MachineConfigurationList{} + err = c.client.Get(). + Resource("machineconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Do(ctx). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested machineConfigurations. +func (c *machineConfigurations) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + opts.Watch = true + return c.client.Get(). + Resource("machineconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Watch(ctx) +} + +// Create takes the representation of a machineConfiguration and creates it. Returns the server's representation of the machineConfiguration, and an error, if there is any. +func (c *machineConfigurations) Create(ctx context.Context, machineConfiguration *v1.MachineConfiguration, opts metav1.CreateOptions) (result *v1.MachineConfiguration, err error) { + result = &v1.MachineConfiguration{} + err = c.client.Post(). + Resource("machineconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(machineConfiguration). + Do(ctx). + Into(result) + return +} + +// Update takes the representation of a machineConfiguration and updates it. Returns the server's representation of the machineConfiguration, and an error, if there is any. +func (c *machineConfigurations) Update(ctx context.Context, machineConfiguration *v1.MachineConfiguration, opts metav1.UpdateOptions) (result *v1.MachineConfiguration, err error) { + result = &v1.MachineConfiguration{} + err = c.client.Put(). + Resource("machineconfigurations"). + Name(machineConfiguration.Name). + VersionedParams(&opts, scheme.ParameterCodec). + Body(machineConfiguration). + Do(ctx). + Into(result) + return +} + +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). +func (c *machineConfigurations) UpdateStatus(ctx context.Context, machineConfiguration *v1.MachineConfiguration, opts metav1.UpdateOptions) (result *v1.MachineConfiguration, err error) { + result = &v1.MachineConfiguration{} + err = c.client.Put(). + Resource("machineconfigurations"). + Name(machineConfiguration.Name). + SubResource("status"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(machineConfiguration). + Do(ctx). + Into(result) + return +} + +// Delete takes name of the machineConfiguration and deletes it. Returns an error if one occurs. +func (c *machineConfigurations) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error { + return c.client.Delete(). + Resource("machineconfigurations"). + Name(name). + Body(&opts). + Do(ctx). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *machineConfigurations) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error { + var timeout time.Duration + if listOpts.TimeoutSeconds != nil { + timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second + } + return c.client.Delete(). + Resource("machineconfigurations"). + VersionedParams(&listOpts, scheme.ParameterCodec). + Timeout(timeout). + Body(&opts). + Do(ctx). + Error() +} + +// Patch applies the patch and returns the patched machineConfiguration. +func (c *machineConfigurations) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (result *v1.MachineConfiguration, err error) { + result = &v1.MachineConfiguration{} + err = c.client.Patch(pt). + Resource("machineconfigurations"). + Name(name). + SubResource(subresources...). + VersionedParams(&opts, scheme.ParameterCodec). + Body(data). + Do(ctx). + Into(result) + return +} + +// Apply takes the given apply declarative configuration, applies it and returns the applied machineConfiguration. +func (c *machineConfigurations) Apply(ctx context.Context, machineConfiguration *operatorv1.MachineConfigurationApplyConfiguration, opts metav1.ApplyOptions) (result *v1.MachineConfiguration, err error) { + if machineConfiguration == nil { + return nil, fmt.Errorf("machineConfiguration provided to Apply must not be nil") + } + patchOpts := opts.ToPatchOptions() + data, err := json.Marshal(machineConfiguration) + if err != nil { + return nil, err + } + name := machineConfiguration.Name + if name == nil { + return nil, fmt.Errorf("machineConfiguration.Name must be provided to Apply") + } + result = &v1.MachineConfiguration{} + err = c.client.Patch(types.ApplyPatchType). + Resource("machineconfigurations"). + Name(*name). + VersionedParams(&patchOpts, scheme.ParameterCodec). + Body(data). + Do(ctx). + Into(result) + return +} + +// ApplyStatus was generated because the type contains a Status member. +// Add a +genclient:noStatus comment above the type to avoid generating ApplyStatus(). +func (c *machineConfigurations) ApplyStatus(ctx context.Context, machineConfiguration *operatorv1.MachineConfigurationApplyConfiguration, opts metav1.ApplyOptions) (result *v1.MachineConfiguration, err error) { + if machineConfiguration == nil { + return nil, fmt.Errorf("machineConfiguration provided to Apply must not be nil") + } + patchOpts := opts.ToPatchOptions() + data, err := json.Marshal(machineConfiguration) + if err != nil { + return nil, err + } + + name := machineConfiguration.Name + if name == nil { + return nil, fmt.Errorf("machineConfiguration.Name must be provided to Apply") + } + + result = &v1.MachineConfiguration{} + err = c.client.Patch(types.ApplyPatchType). + Resource("machineconfigurations"). + Name(*name). + SubResource("status"). + VersionedParams(&patchOpts, scheme.ParameterCodec). + Body(data). + Do(ctx). + Into(result) + return +} diff --git a/operator/clientset/versioned/typed/operator/v1/operator_client.go b/operator/clientset/versioned/typed/operator/v1/operator_client.go index eb4f78717c..996fad76d7 100644 --- a/operator/clientset/versioned/typed/operator/v1/operator_client.go +++ b/operator/clientset/versioned/typed/operator/v1/operator_client.go @@ -26,6 +26,7 @@ type OperatorV1Interface interface { KubeControllerManagersGetter KubeSchedulersGetter KubeStorageVersionMigratorsGetter + MachineConfigurationsGetter NetworksGetter OpenShiftAPIServersGetter OpenShiftControllerManagersGetter @@ -96,6 +97,10 @@ func (c *OperatorV1Client) KubeStorageVersionMigrators() KubeStorageVersionMigra return newKubeStorageVersionMigrators(c) } +func (c *OperatorV1Client) MachineConfigurations() MachineConfigurationInterface { + return newMachineConfigurations(c) +} + func (c *OperatorV1Client) Networks() NetworkInterface { return newNetworks(c) } diff --git a/operator/informers/externalversions/generic.go b/operator/informers/externalversions/generic.go index 7d08938b54..f255f0f371 100644 --- a/operator/informers/externalversions/generic.go +++ b/operator/informers/externalversions/generic.go @@ -66,6 +66,8 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource return &genericInformer{resource: resource.GroupResource(), informer: f.Operator().V1().KubeSchedulers().Informer()}, nil case v1.SchemeGroupVersion.WithResource("kubestorageversionmigrators"): return &genericInformer{resource: resource.GroupResource(), informer: f.Operator().V1().KubeStorageVersionMigrators().Informer()}, nil + case v1.SchemeGroupVersion.WithResource("machineconfigurations"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Operator().V1().MachineConfigurations().Informer()}, nil case v1.SchemeGroupVersion.WithResource("networks"): return &genericInformer{resource: resource.GroupResource(), informer: f.Operator().V1().Networks().Informer()}, nil case v1.SchemeGroupVersion.WithResource("openshiftapiservers"): diff --git a/operator/informers/externalversions/operator/v1/interface.go b/operator/informers/externalversions/operator/v1/interface.go index 59eb5eb93f..a6331e803d 100644 --- a/operator/informers/externalversions/operator/v1/interface.go +++ b/operator/informers/externalversions/operator/v1/interface.go @@ -36,6 +36,8 @@ type Interface interface { KubeSchedulers() KubeSchedulerInformer // KubeStorageVersionMigrators returns a KubeStorageVersionMigratorInformer. KubeStorageVersionMigrators() KubeStorageVersionMigratorInformer + // MachineConfigurations returns a MachineConfigurationInformer. + MachineConfigurations() MachineConfigurationInformer // Networks returns a NetworkInformer. Networks() NetworkInformer // OpenShiftAPIServers returns a OpenShiftAPIServerInformer. @@ -133,6 +135,11 @@ func (v *version) KubeStorageVersionMigrators() KubeStorageVersionMigratorInform return &kubeStorageVersionMigratorInformer{factory: v.factory, tweakListOptions: v.tweakListOptions} } +// MachineConfigurations returns a MachineConfigurationInformer. +func (v *version) MachineConfigurations() MachineConfigurationInformer { + return &machineConfigurationInformer{factory: v.factory, tweakListOptions: v.tweakListOptions} +} + // Networks returns a NetworkInformer. func (v *version) Networks() NetworkInformer { return &networkInformer{factory: v.factory, tweakListOptions: v.tweakListOptions} diff --git a/operator/informers/externalversions/operator/v1/machineconfiguration.go b/operator/informers/externalversions/operator/v1/machineconfiguration.go new file mode 100644 index 0000000000..e16f6ff104 --- /dev/null +++ b/operator/informers/externalversions/operator/v1/machineconfiguration.go @@ -0,0 +1,73 @@ +// Code generated by informer-gen. DO NOT EDIT. + +package v1 + +import ( + "context" + time "time" + + operatorv1 "github.com/openshift/api/operator/v1" + versioned "github.com/openshift/client-go/operator/clientset/versioned" + internalinterfaces "github.com/openshift/client-go/operator/informers/externalversions/internalinterfaces" + v1 "github.com/openshift/client-go/operator/listers/operator/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + watch "k8s.io/apimachinery/pkg/watch" + cache "k8s.io/client-go/tools/cache" +) + +// MachineConfigurationInformer provides access to a shared informer and lister for +// MachineConfigurations. +type MachineConfigurationInformer interface { + Informer() cache.SharedIndexInformer + Lister() v1.MachineConfigurationLister +} + +type machineConfigurationInformer struct { + factory internalinterfaces.SharedInformerFactory + tweakListOptions internalinterfaces.TweakListOptionsFunc +} + +// NewMachineConfigurationInformer constructs a new informer for MachineConfiguration type. +// Always prefer using an informer factory to get a shared informer instead of getting an independent +// one. This reduces memory footprint and number of connections to the server. +func NewMachineConfigurationInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer { + return NewFilteredMachineConfigurationInformer(client, resyncPeriod, indexers, nil) +} + +// NewFilteredMachineConfigurationInformer constructs a new informer for MachineConfiguration type. +// Always prefer using an informer factory to get a shared informer instead of getting an independent +// one. This reduces memory footprint and number of connections to the server. +func NewFilteredMachineConfigurationInformer(client versioned.Interface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { + return cache.NewSharedIndexInformer( + &cache.ListWatch{ + ListFunc: func(options metav1.ListOptions) (runtime.Object, error) { + if tweakListOptions != nil { + tweakListOptions(&options) + } + return client.OperatorV1().MachineConfigurations().List(context.TODO(), options) + }, + WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) { + if tweakListOptions != nil { + tweakListOptions(&options) + } + return client.OperatorV1().MachineConfigurations().Watch(context.TODO(), options) + }, + }, + &operatorv1.MachineConfiguration{}, + resyncPeriod, + indexers, + ) +} + +func (f *machineConfigurationInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { + return NewFilteredMachineConfigurationInformer(client, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions) +} + +func (f *machineConfigurationInformer) Informer() cache.SharedIndexInformer { + return f.factory.InformerFor(&operatorv1.MachineConfiguration{}, f.defaultInformer) +} + +func (f *machineConfigurationInformer) Lister() v1.MachineConfigurationLister { + return v1.NewMachineConfigurationLister(f.Informer().GetIndexer()) +} diff --git a/operator/listers/operator/v1/expansion_generated.go b/operator/listers/operator/v1/expansion_generated.go index f7d082e1a5..d2e75d0c36 100644 --- a/operator/listers/operator/v1/expansion_generated.go +++ b/operator/listers/operator/v1/expansion_generated.go @@ -62,6 +62,10 @@ type KubeSchedulerListerExpansion interface{} // KubeStorageVersionMigratorLister. type KubeStorageVersionMigratorListerExpansion interface{} +// MachineConfigurationListerExpansion allows custom methods to be added to +// MachineConfigurationLister. +type MachineConfigurationListerExpansion interface{} + // NetworkListerExpansion allows custom methods to be added to // NetworkLister. type NetworkListerExpansion interface{} diff --git a/operator/listers/operator/v1/machineconfiguration.go b/operator/listers/operator/v1/machineconfiguration.go new file mode 100644 index 0000000000..304d8f2971 --- /dev/null +++ b/operator/listers/operator/v1/machineconfiguration.go @@ -0,0 +1,52 @@ +// Code generated by lister-gen. DO NOT EDIT. + +package v1 + +import ( + v1 "github.com/openshift/api/operator/v1" + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/client-go/tools/cache" +) + +// MachineConfigurationLister helps list MachineConfigurations. +// All objects returned here must be treated as read-only. +type MachineConfigurationLister interface { + // List lists all MachineConfigurations in the indexer. + // Objects returned here must be treated as read-only. + List(selector labels.Selector) (ret []*v1.MachineConfiguration, err error) + // Get retrieves the MachineConfiguration from the index for a given name. + // Objects returned here must be treated as read-only. + Get(name string) (*v1.MachineConfiguration, error) + MachineConfigurationListerExpansion +} + +// machineConfigurationLister implements the MachineConfigurationLister interface. +type machineConfigurationLister struct { + indexer cache.Indexer +} + +// NewMachineConfigurationLister returns a new MachineConfigurationLister. +func NewMachineConfigurationLister(indexer cache.Indexer) MachineConfigurationLister { + return &machineConfigurationLister{indexer: indexer} +} + +// List lists all MachineConfigurations in the indexer. +func (s *machineConfigurationLister) List(selector labels.Selector) (ret []*v1.MachineConfiguration, err error) { + err = cache.ListAll(s.indexer, selector, func(m interface{}) { + ret = append(ret, m.(*v1.MachineConfiguration)) + }) + return ret, err +} + +// Get retrieves the MachineConfiguration from the index for a given name. +func (s *machineConfigurationLister) Get(name string) (*v1.MachineConfiguration, error) { + obj, exists, err := s.indexer.GetByKey(name) + if err != nil { + return nil, err + } + if !exists { + return nil, errors.NewNotFound(v1.Resource("machineconfiguration"), name) + } + return obj.(*v1.MachineConfiguration), nil +} diff --git a/route/applyconfigurations/internal/internal.go b/route/applyconfigurations/internal/internal.go index 38acf6dc72..d248deb636 100644 --- a/route/applyconfigurations/internal/internal.go +++ b/route/applyconfigurations/internal/internal.go @@ -51,58 +51,6 @@ var schemaYAML = typed.YAMLObject(`types: type: namedType: com.github.openshift.api.route.v1.RouteStatus default: {} -- name: com.github.openshift.api.route.v1.RouteHTTPHeader - map: - fields: - - name: action - type: - namedType: com.github.openshift.api.route.v1.RouteHTTPHeaderActionUnion - default: {} - - name: name - type: - scalar: string - default: "" -- name: com.github.openshift.api.route.v1.RouteHTTPHeaderActionUnion - map: - fields: - - name: set - type: - namedType: com.github.openshift.api.route.v1.RouteSetHTTPHeader - - name: type - type: - scalar: string - default: "" - unions: - - discriminator: type - fields: - - fieldName: set - discriminatorValue: Set -- name: com.github.openshift.api.route.v1.RouteHTTPHeaderActions - map: - fields: - - name: request - type: - list: - elementType: - namedType: com.github.openshift.api.route.v1.RouteHTTPHeader - elementRelationship: associative - keys: - - name - - name: response - type: - list: - elementType: - namedType: com.github.openshift.api.route.v1.RouteHTTPHeader - elementRelationship: associative - keys: - - name -- name: com.github.openshift.api.route.v1.RouteHTTPHeaders - map: - fields: - - name: actions - type: - namedType: com.github.openshift.api.route.v1.RouteHTTPHeaderActions - default: {} - name: com.github.openshift.api.route.v1.RouteIngress map: fields: @@ -151,13 +99,6 @@ var schemaYAML = typed.YAMLObject(`types: type: namedType: io.k8s.apimachinery.pkg.util.intstr.IntOrString default: {} -- name: com.github.openshift.api.route.v1.RouteSetHTTPHeader - map: - fields: - - name: value - type: - scalar: string - default: "" - name: com.github.openshift.api.route.v1.RouteSpec map: fields: @@ -170,9 +111,6 @@ var schemaYAML = typed.YAMLObject(`types: - name: host type: scalar: string - - name: httpHeaders - type: - namedType: com.github.openshift.api.route.v1.RouteHTTPHeaders - name: path type: scalar: string diff --git a/route/applyconfigurations/route/v1/routespec.go b/route/applyconfigurations/route/v1/routespec.go index c6dcacfb27..8034bace02 100644 --- a/route/applyconfigurations/route/v1/routespec.go +++ b/route/applyconfigurations/route/v1/routespec.go @@ -17,7 +17,6 @@ type RouteSpecApplyConfiguration struct { Port *RoutePortApplyConfiguration `json:"port,omitempty"` TLS *TLSConfigApplyConfiguration `json:"tls,omitempty"` WildcardPolicy *routev1.WildcardPolicyType `json:"wildcardPolicy,omitempty"` - HTTPHeaders *RouteHTTPHeadersApplyConfiguration `json:"httpHeaders,omitempty"` } // RouteSpecApplyConfiguration constructs an declarative configuration of the RouteSpec type for use with @@ -94,11 +93,3 @@ func (b *RouteSpecApplyConfiguration) WithWildcardPolicy(value routev1.WildcardP b.WildcardPolicy = &value return b } - -// WithHTTPHeaders sets the HTTPHeaders field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the HTTPHeaders field is set to the value of the last call. -func (b *RouteSpecApplyConfiguration) WithHTTPHeaders(value *RouteHTTPHeadersApplyConfiguration) *RouteSpecApplyConfiguration { - b.HTTPHeaders = value - return b -} diff --git a/route/applyconfigurations/utils.go b/route/applyconfigurations/utils.go index edd6df66bd..e941522aba 100644 --- a/route/applyconfigurations/utils.go +++ b/route/applyconfigurations/utils.go @@ -17,22 +17,12 @@ func ForKind(kind schema.GroupVersionKind) interface{} { return &routev1.LocalObjectReferenceApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("Route"): return &routev1.RouteApplyConfiguration{} - case v1.SchemeGroupVersion.WithKind("RouteHTTPHeader"): - return &routev1.RouteHTTPHeaderApplyConfiguration{} - case v1.SchemeGroupVersion.WithKind("RouteHTTPHeaderActions"): - return &routev1.RouteHTTPHeaderActionsApplyConfiguration{} - case v1.SchemeGroupVersion.WithKind("RouteHTTPHeaderActionUnion"): - return &routev1.RouteHTTPHeaderActionUnionApplyConfiguration{} - case v1.SchemeGroupVersion.WithKind("RouteHTTPHeaders"): - return &routev1.RouteHTTPHeadersApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("RouteIngress"): return &routev1.RouteIngressApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("RouteIngressCondition"): return &routev1.RouteIngressConditionApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("RoutePort"): return &routev1.RoutePortApplyConfiguration{} - case v1.SchemeGroupVersion.WithKind("RouteSetHTTPHeader"): - return &routev1.RouteSetHTTPHeaderApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("RouteSpec"): return &routev1.RouteSpecApplyConfiguration{} case v1.SchemeGroupVersion.WithKind("RouteStatus"): diff --git a/vendor/github.com/openshift/api/config/v1/0000_00_cluster-version-operator_01_clusterversion.crd.yaml b/vendor/github.com/openshift/api/config/v1/0000_00_cluster-version-operator_01_clusterversion.crd.yaml index 69a2ed280f..c417797329 100644 --- a/vendor/github.com/openshift/api/config/v1/0000_00_cluster-version-operator_01_clusterversion.crd.yaml +++ b/vendor/github.com/openshift/api/config/v1/0000_00_cluster-version-operator_01_clusterversion.crd.yaml @@ -72,8 +72,7 @@ spec: - CSISnapshot - NodeTuning - MachineAPI - - Build - - DeploymentConfig + - Ingress x-kubernetes-list-type: atomic baselineCapabilitySet: description: baselineCapabilitySet selects an initial set of optional capabilities to enable, which can be extended via additionalEnabledCapabilities. If unset, the cluster will choose a default, and the default may change over time. The current default is vCurrent. @@ -197,8 +196,7 @@ spec: - CSISnapshot - NodeTuning - MachineAPI - - Build - - DeploymentConfig + - Ingress x-kubernetes-list-type: atomic knownCapabilities: description: knownCapabilities lists all the capabilities known to the current cluster. @@ -216,8 +214,7 @@ spec: - CSISnapshot - NodeTuning - MachineAPI - - Build - - DeploymentConfig + - Ingress x-kubernetes-list-type: atomic conditionalUpdates: description: conditionalUpdates contains the list of updates that may be recommended for this cluster if it meets specific required conditions. Consumers interested in the set of updates that are actually recommended for this cluster should use availableUpdates. This list may be empty if no updates are recommended, if the update service is unavailable, or if an empty or invalid channel has been specified. diff --git a/vendor/github.com/openshift/api/config/v1/0000_10_config-operator_01_infrastructure-CustomNoUpgrade.crd.yaml b/vendor/github.com/openshift/api/config/v1/0000_10_config-operator_01_infrastructure-CustomNoUpgrade.crd.yaml index 4c6d4c0744..74e9b3bd3b 100644 --- a/vendor/github.com/openshift/api/config/v1/0000_10_config-operator_01_infrastructure-CustomNoUpgrade.crd.yaml +++ b/vendor/github.com/openshift/api/config/v1/0000_10_config-operator_01_infrastructure-CustomNoUpgrade.crd.yaml @@ -646,80 +646,7 @@ spec: region: description: region holds the region for new GCP resources created for the cluster. type: string - resourceLabels: - description: resourceLabels is a list of additional labels to apply to GCP resources created for the cluster. See https://cloud.google.com/compute/docs/labeling-resources for information on labeling GCP resources. GCP supports a maximum of 64 labels per resource. OpenShift reserves 32 labels for internal use, allowing 32 labels for user configuration. - items: - description: GCPResourceLabel is a label to apply to GCP resources created for the cluster. - properties: - key: - description: key is the key part of the label. A label key can have a maximum of 63 characters and cannot be empty. Label key must begin with a lowercase letter, and must contain only lowercase letters, numeric characters, and the following special characters `_-`. Label key must not have the reserved prefixes `kubernetes-io` and `openshift-io`. - maxLength: 63 - minLength: 1 - pattern: ^[a-z][0-9a-z_-]+$ - type: string - x-kubernetes-validations: - - message: label keys must not start with either `openshift-io` or `kubernetes-io` - rule: '!self.startsWith(''openshift-io'') && !self.startsWith(''kubernetes-io'')' - value: - description: value is the value part of the label. A label value can have a maximum of 63 characters and cannot be empty. Value must contain only lowercase letters, numeric characters, and the following special characters `_-`. - maxLength: 63 - minLength: 1 - pattern: ^[0-9a-z_-]+$ - type: string - required: - - key - - value - type: object - maxItems: 32 - type: array - x-kubernetes-list-map-keys: - - key - x-kubernetes-list-type: map - x-kubernetes-validations: - - message: resourceLabels are immutable and may only be configured during installation - rule: self.all(x, x in oldSelf) && oldSelf.all(x, x in self) - resourceTags: - description: resourceTags is a list of additional tags to apply to GCP resources created for the cluster. See https://cloud.google.com/resource-manager/docs/tags/tags-overview for information on tagging GCP resources. GCP supports a maximum of 50 tags per resource. - items: - description: GCPResourceTag is a tag to apply to GCP resources created for the cluster. - properties: - key: - description: key is the key part of the tag. A tag key can have a maximum of 63 characters and cannot be empty. Tag key must begin and end with an alphanumeric character, and must contain only uppercase, lowercase alphanumeric characters, and the following special characters `._-`. - maxLength: 63 - minLength: 1 - pattern: ^[a-zA-Z0-9]([0-9A-Za-z_.-]{0,61}[a-zA-Z0-9])?$ - type: string - parentID: - description: 'parentID is the ID of the hierarchical resource where the tags are defined, e.g. at the Organization or the Project level. To find the Organization or Project ID refer to the following pages: https://cloud.google.com/resource-manager/docs/creating-managing-organization#retrieving_your_organization_id, https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects. An OrganizationID must consist of decimal numbers, and cannot have leading zeroes. A ProjectID must be 6 to 30 characters in length, can only contain lowercase letters, numbers, and hyphens, and must start with a letter, and cannot end with a hyphen.' - maxLength: 32 - minLength: 1 - pattern: (^[1-9][0-9]{0,31}$)|(^[a-z][a-z0-9-]{4,28}[a-z0-9]$) - type: string - value: - description: value is the value part of the tag. A tag value can have a maximum of 63 characters and cannot be empty. Tag value must begin and end with an alphanumeric character, and must contain only uppercase, lowercase alphanumeric characters, and the following special characters `_-.@%=+:,*#&(){}[]` and spaces. - maxLength: 63 - minLength: 1 - pattern: ^[a-zA-Z0-9]([0-9A-Za-z_.@%=+:,*#&()\[\]{}\-\s]{0,61}[a-zA-Z0-9])?$ - type: string - required: - - key - - parentID - - value - type: object - maxItems: 50 - type: array - x-kubernetes-list-map-keys: - - key - x-kubernetes-list-type: map - x-kubernetes-validations: - - message: resourceTags are immutable and may only be configured during installation - rule: self.all(x, x in oldSelf) && oldSelf.all(x, x in self) type: object - x-kubernetes-validations: - - message: resourceLabels may only be configured during installation - rule: '!has(oldSelf.resourceLabels) && !has(self.resourceLabels) || has(oldSelf.resourceLabels) && has(self.resourceLabels)' - - message: resourceTags may only be configured during installation - rule: '!has(oldSelf.resourceTags) && !has(self.resourceTags) || has(oldSelf.resourceTags) && has(self.resourceTags)' ibmcloud: description: IBMCloud contains settings specific to the IBMCloud infrastructure provider. properties: diff --git a/vendor/github.com/openshift/api/config/v1/0000_10_config-operator_01_infrastructure-TechPreviewNoUpgrade.crd.yaml b/vendor/github.com/openshift/api/config/v1/0000_10_config-operator_01_infrastructure-TechPreviewNoUpgrade.crd.yaml index 0698bc6803..13d0d1f465 100644 --- a/vendor/github.com/openshift/api/config/v1/0000_10_config-operator_01_infrastructure-TechPreviewNoUpgrade.crd.yaml +++ b/vendor/github.com/openshift/api/config/v1/0000_10_config-operator_01_infrastructure-TechPreviewNoUpgrade.crd.yaml @@ -646,80 +646,7 @@ spec: region: description: region holds the region for new GCP resources created for the cluster. type: string - resourceLabels: - description: resourceLabels is a list of additional labels to apply to GCP resources created for the cluster. See https://cloud.google.com/compute/docs/labeling-resources for information on labeling GCP resources. GCP supports a maximum of 64 labels per resource. OpenShift reserves 32 labels for internal use, allowing 32 labels for user configuration. - items: - description: GCPResourceLabel is a label to apply to GCP resources created for the cluster. - properties: - key: - description: key is the key part of the label. A label key can have a maximum of 63 characters and cannot be empty. Label key must begin with a lowercase letter, and must contain only lowercase letters, numeric characters, and the following special characters `_-`. Label key must not have the reserved prefixes `kubernetes-io` and `openshift-io`. - maxLength: 63 - minLength: 1 - pattern: ^[a-z][0-9a-z_-]+$ - type: string - x-kubernetes-validations: - - message: label keys must not start with either `openshift-io` or `kubernetes-io` - rule: '!self.startsWith(''openshift-io'') && !self.startsWith(''kubernetes-io'')' - value: - description: value is the value part of the label. A label value can have a maximum of 63 characters and cannot be empty. Value must contain only lowercase letters, numeric characters, and the following special characters `_-`. - maxLength: 63 - minLength: 1 - pattern: ^[0-9a-z_-]+$ - type: string - required: - - key - - value - type: object - maxItems: 32 - type: array - x-kubernetes-list-map-keys: - - key - x-kubernetes-list-type: map - x-kubernetes-validations: - - message: resourceLabels are immutable and may only be configured during installation - rule: self.all(x, x in oldSelf) && oldSelf.all(x, x in self) - resourceTags: - description: resourceTags is a list of additional tags to apply to GCP resources created for the cluster. See https://cloud.google.com/resource-manager/docs/tags/tags-overview for information on tagging GCP resources. GCP supports a maximum of 50 tags per resource. - items: - description: GCPResourceTag is a tag to apply to GCP resources created for the cluster. - properties: - key: - description: key is the key part of the tag. A tag key can have a maximum of 63 characters and cannot be empty. Tag key must begin and end with an alphanumeric character, and must contain only uppercase, lowercase alphanumeric characters, and the following special characters `._-`. - maxLength: 63 - minLength: 1 - pattern: ^[a-zA-Z0-9]([0-9A-Za-z_.-]{0,61}[a-zA-Z0-9])?$ - type: string - parentID: - description: 'parentID is the ID of the hierarchical resource where the tags are defined, e.g. at the Organization or the Project level. To find the Organization or Project ID refer to the following pages: https://cloud.google.com/resource-manager/docs/creating-managing-organization#retrieving_your_organization_id, https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects. An OrganizationID must consist of decimal numbers, and cannot have leading zeroes. A ProjectID must be 6 to 30 characters in length, can only contain lowercase letters, numbers, and hyphens, and must start with a letter, and cannot end with a hyphen.' - maxLength: 32 - minLength: 1 - pattern: (^[1-9][0-9]{0,31}$)|(^[a-z][a-z0-9-]{4,28}[a-z0-9]$) - type: string - value: - description: value is the value part of the tag. A tag value can have a maximum of 63 characters and cannot be empty. Tag value must begin and end with an alphanumeric character, and must contain only uppercase, lowercase alphanumeric characters, and the following special characters `_-.@%=+:,*#&(){}[]` and spaces. - maxLength: 63 - minLength: 1 - pattern: ^[a-zA-Z0-9]([0-9A-Za-z_.@%=+:,*#&()\[\]{}\-\s]{0,61}[a-zA-Z0-9])?$ - type: string - required: - - key - - parentID - - value - type: object - maxItems: 50 - type: array - x-kubernetes-list-map-keys: - - key - x-kubernetes-list-type: map - x-kubernetes-validations: - - message: resourceTags are immutable and may only be configured during installation - rule: self.all(x, x in oldSelf) && oldSelf.all(x, x in self) type: object - x-kubernetes-validations: - - message: resourceLabels may only be configured during installation - rule: '!has(oldSelf.resourceLabels) && !has(self.resourceLabels) || has(oldSelf.resourceLabels) && has(self.resourceLabels)' - - message: resourceTags may only be configured during installation - rule: '!has(oldSelf.resourceTags) && !has(self.resourceTags) || has(oldSelf.resourceTags) && has(self.resourceTags)' ibmcloud: description: IBMCloud contains settings specific to the IBMCloud infrastructure provider. properties: diff --git a/vendor/github.com/openshift/api/config/v1/custom.infrastructure.testsuite.yaml b/vendor/github.com/openshift/api/config/v1/custom.infrastructure.testsuite.yaml index 24433f4f75..ab1a123b60 100644 --- a/vendor/github.com/openshift/api/config/v1/custom.infrastructure.testsuite.yaml +++ b/vendor/github.com/openshift/api/config/v1/custom.infrastructure.testsuite.yaml @@ -1,321 +1,104 @@ apiVersion: apiextensions.k8s.io/v1 # Hack because controller-gen complains if we don't have this -name: "[Custom] Infrastructure" -crd: 0000_10_config-operator_01_infrastructure-CustomNoUpgrade.crd.yaml +name: "[Custom] DNS" +crd: 0000_10_config-operator_01_dns-CustomNoUpgrade.crd.yaml tests: onCreate: - - name: Should be able to create a minimal Infrastructure + - name: Should be able to create a minimal DNS initial: | apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} # No spec is required for a Infrastructure + kind: DNS + spec: {} # No spec is required for a DNS expected: | apiVersion: config.openshift.io/v1 - kind: Infrastructure + kind: DNS spec: {} - onUpdate: - - name: Should not be able to modify an existing GCP ResourceLabels Label - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - controlPlaneTopology: "HighlyAvailable" - infrastructureTopology: "HighlyAvailable" - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "changed"} - expectedStatusError: "status.platformStatus.gcp.resourceLabels: Invalid value: \"array\": resourceLabels are immutable and may only be configured during installation" - - name: Should not be able to add a Label to an existing GCP ResourceLabels - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - controlPlaneTopology: "HighlyAvailable" - infrastructureTopology: "HighlyAvailable" - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - - {key: "new", value: "entry"} - expectedStatusError: "status.platformStatus.gcp.resourceLabels: Invalid value: \"array\": resourceLabels are immutable and may only be configured during installation" - - name: Should not be able to remove a Label from an existing GCP ResourceLabels - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - - {key: "new", value: "entry"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - expectedStatusError: "status.platformStatus.gcp.resourceLabels: Invalid value: \"array\": resourceLabels are immutable and may only be configured during installation" - - name: Should not be able to add GCP ResourceLabels to an empty platformStatus.gcp - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: {} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - gcp: - resourceLabels: - - {key: "key", value: "value"} - expectedStatusError: "status.platformStatus.gcp: Invalid value: \"object\": resourceLabels may only be configured during installation" - - name: Should not be able to remove GCP ResourceLabels from platformStatus.gcp - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: {} - expectedStatusError: "status.platformStatus.gcp: Invalid value: \"object\": resourceLabels may only be configured during installation" - - name: Should not have label key start with openshift-io for GCP ResourceLabels in platformStatus.gcp + - name: Should be able to specify an AWS role ARN for a private hosted zone initial: | apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: {} - updated: | + kind: DNS + spec: + platform: + type: AWS + aws: + privateZoneIAMRole: arn:aws:iam::123456789012:role/foo + expected: | apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - - {key: "openshift-io-created-cluster", value: "true"} - expectedStatusError: "status.platformStatus.gcp.resourceLabels[1].key: Invalid value: \"string\": label keys must not start with either `openshift-io` or `kubernetes-io`" - - name: Should not have label key start with kubernetes-io for GCP ResourceLabels in platformStatus.gcp + kind: DNS + spec: + platform: + type: AWS + aws: + privateZoneIAMRole: arn:aws:iam::123456789012:role/foo + - name: Should not be able to specify unsupported platform initial: | apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: {} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - - {key: "kubernetes-io-created-cluster", value: "true"} - expectedStatusError: "status.platformStatus.gcp.resourceLabels[1].key: Invalid value: \"string\": label keys must not start with either `openshift-io` or `kubernetes-io`" - - name: Should not be able to modify an existing GCP ResourceTags Tag + kind: DNS + spec: + platform: + type: Azure + azure: + privateZoneIAMRole: arn:aws:iam::123456789012:role/foo + expectedError: "Invalid value: \"string\": allowed values are '' and 'AWS'" + - name: Should not be able to specify invalid AWS role ARN initial: | apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - controlPlaneTopology: "HighlyAvailable" - infrastructureTopology: "HighlyAvailable" - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key", value: "value"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key", value: "changed"} - expectedStatusError: "status.platformStatus.gcp.resourceTags: Invalid value: \"array\": resourceTags are immutable and may only be configured during installation" - - name: Should not be able to add a Tag to an existing GCP ResourceTags + kind: DNS + metadata: + name: cluster + spec: + platform: + type: AWS + aws: + privateZoneIAMRole: arn:aws:iam:bad:123456789012:role/foo + expectedError: "DNS.config.openshift.io \"cluster\" is invalid: spec.platform.aws.privateZoneIAMRole: Invalid value: \"arn:aws:iam:bad:123456789012:role/foo\": spec.platform.aws.privateZoneIAMRole in body should match '^arn:(aws|aws-cn|aws-us-gov):iam::[0-9]{12}:role\\/.*$'" + - name: Should not be able to specify different type and platform initial: | apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - controlPlaneTopology: "HighlyAvailable" - infrastructureTopology: "HighlyAvailable" - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key", value: "value"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key", value: "value"} - - {parentID: "test-project-123", key: "new", value: "tag"} - expectedStatusError: "status.platformStatus.gcp.resourceTags: Invalid value: \"array\": resourceTags are immutable and may only be configured during installation" - - name: Should not be able to remove a Tag from an existing GCP ResourceTags + kind: DNS + spec: + platform: + type: "" + aws: + privateZoneIAMRole: arn:aws:iam::123456789012:role/foo + expectedError: "Invalid value: \"object\": aws configuration is required when platform is AWS, and forbidden otherwise" + onUpdate: + - name: Can switch from empty (default), to AWS initial: | apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key1", value: "value1"} - - {parentID: "test-project-123", key: "key2", value: "value2"} + kind: DNS + spec: + platform: + type: "" updated: | apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key1", value: "value1"} - expectedStatusError: "status.platformStatus.gcp.resourceTags: Invalid value: \"array\": resourceTags are immutable and may only be configured during installation" - - name: Should not be able to add GCP ResourceTags to an empty platformStatus.gcp - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: {} - updated: | + kind: DNS + spec: + platform: + type: AWS + aws: + privateZoneIAMRole: arn:aws:iam::123456789012:role/foo + expected: | apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - gcp: - resourceTags: - - {parentID: "1234567890", key: "key", value: "value"} - expectedStatusError: "status.platformStatus.gcp: Invalid value: \"object\": resourceTags may only be configured during installation" - - name: Should not be able to remove GCP ResourceTags from platformStatus.gcp + kind: DNS + spec: + platform: + type: AWS + aws: + privateZoneIAMRole: arn:aws:iam::123456789012:role/foo + - name: Upgrade case is valid initial: | apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key", value: "value"} + kind: DNS + spec: {} # No spec is required for a DNS updated: | apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: {} - expectedStatusError: "status.platformStatus.gcp: Invalid value: \"object\": resourceTags may only be configured during installation" - - name: Should not be able to modify ParentID of a Tag in the GCP ResourceTags - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - controlPlaneTopology: "HighlyAvailable" - infrastructureTopology: "HighlyAvailable" - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key", value: "value"} - updated: | + kind: DNS + spec: + platform: + type: "" + expected: | apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "test-project-123", key: "key", value: "value"} - expectedStatusError: "status.platformStatus.gcp.resourceTags: Invalid value: \"array\": resourceTags are immutable and may only be configured during installation" + kind: DNS + spec: + platform: + type: "" diff --git a/vendor/github.com/openshift/api/config/v1/techpreview.infrastructure.testsuite.yaml b/vendor/github.com/openshift/api/config/v1/techpreview.infrastructure.testsuite.yaml index 7834e1f841..f9829b9a39 100644 --- a/vendor/github.com/openshift/api/config/v1/techpreview.infrastructure.testsuite.yaml +++ b/vendor/github.com/openshift/api/config/v1/techpreview.infrastructure.testsuite.yaml @@ -211,309 +211,3 @@ tests: type: FooBar type: BareMetal expectedStatusError: "status.platformStatus.baremetal.loadBalancer.type: Unsupported value: \"FooBar\": supported values: \"OpenShiftManagedDefault\", \"UserManaged\"" - - name: Should not be able to modify an existing GCP ResourceLabels Label - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - controlPlaneTopology: "HighlyAvailable" - infrastructureTopology: "HighlyAvailable" - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "changed"} - expectedStatusError: "status.platformStatus.gcp.resourceLabels: Invalid value: \"array\": resourceLabels are immutable and may only be configured during installation" - - name: Should not be able to add a Label to an existing GCP ResourceLabels - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - controlPlaneTopology: "HighlyAvailable" - infrastructureTopology: "HighlyAvailable" - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - - {key: "new", value: "entry"} - expectedStatusError: "status.platformStatus.gcp.resourceLabels: Invalid value: \"array\": resourceLabels are immutable and may only be configured during installation" - - name: Should not be able to remove a Label from an existing GCP ResourceLabels - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - - {key: "new", value: "entry"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - expectedStatusError: "status.platformStatus.gcp.resourceLabels: Invalid value: \"array\": resourceLabels are immutable and may only be configured during installation" - - name: Should not be able to add GCP ResourceLabels to an empty platformStatus.gcp - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: {} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - gcp: - resourceLabels: - - {key: "key", value: "value"} - expectedStatusError: "status.platformStatus.gcp: Invalid value: \"object\": resourceLabels may only be configured during installation" - - name: Should not be able to remove GCP ResourceLabels from platformStatus.gcp - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: {} - expectedStatusError: "status.platformStatus.gcp: Invalid value: \"object\": resourceLabels may only be configured during installation" - - name: Should not have label key start with openshift-io for GCP ResourceLabels in platformStatus.gcp - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: {} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - - {key: "openshift-io-created-cluster", value: "true"} - expectedStatusError: "status.platformStatus.gcp.resourceLabels[1].key: Invalid value: \"string\": label keys must not start with either `openshift-io` or `kubernetes-io`" - - name: Should not have label key start with kubernetes-io for GCP ResourceLabels in platformStatus.gcp - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: {} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceLabels: - - {key: "key", value: "value"} - - {key: "kubernetes-io-created-cluster", value: "true"} - expectedStatusError: "status.platformStatus.gcp.resourceLabels[1].key: Invalid value: \"string\": label keys must not start with either `openshift-io` or `kubernetes-io`" - - name: Should not be able to modify an existing GCP ResourceTags Tag - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - controlPlaneTopology: "HighlyAvailable" - infrastructureTopology: "HighlyAvailable" - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key", value: "value"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key", value: "changed"} - expectedStatusError: "status.platformStatus.gcp.resourceTags: Invalid value: \"array\": resourceTags are immutable and may only be configured during installation" - - name: Should not be able to add a Tag to an existing GCP ResourceTags - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - controlPlaneTopology: "HighlyAvailable" - infrastructureTopology: "HighlyAvailable" - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key", value: "value"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key", value: "value"} - - {parentID: "test-project-123", key: "new", value: "tag"} - expectedStatusError: "status.platformStatus.gcp.resourceTags: Invalid value: \"array\": resourceTags are immutable and may only be configured during installation" - - name: Should not be able to remove a Tag from an existing GCP ResourceTags - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key1", value: "value1"} - - {parentID: "test-project-123", key: "key2", value: "value2"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key1", value: "value1"} - expectedStatusError: "status.platformStatus.gcp.resourceTags: Invalid value: \"array\": resourceTags are immutable and may only be configured during installation" - - name: Should not be able to add GCP ResourceTags to an empty platformStatus.gcp - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: {} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - gcp: - resourceTags: - - {parentID: "1234567890", key: "key", value: "value"} - expectedStatusError: "status.platformStatus.gcp: Invalid value: \"object\": resourceTags may only be configured during installation" - - name: Should not be able to remove GCP ResourceTags from platformStatus.gcp - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key", value: "value"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: {} - expectedStatusError: "status.platformStatus.gcp: Invalid value: \"object\": resourceTags may only be configured during installation" - - name: Should not be able to modify ParentID of a Tag in the GCP ResourceTags - initial: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - controlPlaneTopology: "HighlyAvailable" - infrastructureTopology: "HighlyAvailable" - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "1234567890", key: "key", value: "value"} - updated: | - apiVersion: config.openshift.io/v1 - kind: Infrastructure - spec: {} - status: - platform: GCP - platformStatus: - type: GCP - gcp: - resourceTags: - - {parentID: "test-project-123", key: "key", value: "value"} - expectedStatusError: "status.platformStatus.gcp.resourceTags: Invalid value: \"array\": resourceTags are immutable and may only be configured during installation" diff --git a/vendor/github.com/openshift/api/config/v1/types_cluster_version.go b/vendor/github.com/openshift/api/config/v1/types_cluster_version.go index 888a9658ac..3c44eccf42 100644 --- a/vendor/github.com/openshift/api/config/v1/types_cluster_version.go +++ b/vendor/github.com/openshift/api/config/v1/types_cluster_version.go @@ -247,7 +247,7 @@ const ( ) // ClusterVersionCapability enumerates optional, core cluster components. -// +kubebuilder:validation:Enum=openshift-samples;baremetal;marketplace;Console;Insights;Storage;CSISnapshot;NodeTuning;MachineAPI;Build;DeploymentConfig +// +kubebuilder:validation:Enum=openshift-samples;baremetal;marketplace;Console;Insights;Storage;CSISnapshot;NodeTuning;MachineAPI;Ingress type ClusterVersionCapability string const ( @@ -314,28 +314,26 @@ const ( // and may cause cluster damage ClusterVersionCapabilityMachineAPI ClusterVersionCapability = "MachineAPI" - // ClusterVersionCapabilityBuild manages the Build API which is responsible - // for watching the Build API objects and managing their lifecycle. - // The functionality is located under openshift-apiserver and openshift-controller-manager. + // ClusterVersionCapabilityIngress manages the cluster ingress operator + // which is responsible for running the ingress controllers (including OpenShift router). // - // The following resources are taken into account: - // - builds - // - buildconfigs - ClusterVersionCapabilityBuild ClusterVersionCapability = "Build" - - // ClusterVersionCapabilityDeploymentConfig manages the DeploymentConfig API - // which is responsible for watching the DeploymentConfig API and managing their lifecycle. - // The functionality is located under openshift-apiserver and openshift-controller-manager. + // The following CRDs are part of the capability as well: + // IngressController + // DNSRecord + // GatewayClass + // Gateway + // HTTPRoute + // ReferenceGrant // - // The following resources are taken into account: - // - deploymentconfigs - ClusterVersionCapabilityDeploymentConfig ClusterVersionCapability = "DeploymentConfig" + // WARNING: This capability cannot be disabled on the standalone OpenShift. + ClusterVersionCapabilityIngress ClusterVersionCapability = "Ingress" ) // KnownClusterVersionCapabilities includes all known optional, core cluster components. var KnownClusterVersionCapabilities = []ClusterVersionCapability{ ClusterVersionCapabilityBaremetal, ClusterVersionCapabilityConsole, + ClusterVersionCapabilityIngress, ClusterVersionCapabilityInsights, ClusterVersionCapabilityMarketplace, ClusterVersionCapabilityStorage, @@ -343,8 +341,6 @@ var KnownClusterVersionCapabilities = []ClusterVersionCapability{ ClusterVersionCapabilityCSISnapshot, ClusterVersionCapabilityNodeTuning, ClusterVersionCapabilityMachineAPI, - ClusterVersionCapabilityBuild, - ClusterVersionCapabilityDeploymentConfig, } // ClusterVersionCapabilitySet defines sets of cluster version capabilities. @@ -416,6 +412,7 @@ var ClusterVersionCapabilitySets = map[ClusterVersionCapabilitySet][]ClusterVers ClusterVersionCapabilitySet4_14: { ClusterVersionCapabilityBaremetal, ClusterVersionCapabilityConsole, + ClusterVersionCapabilityIngress, ClusterVersionCapabilityInsights, ClusterVersionCapabilityMarketplace, ClusterVersionCapabilityStorage, @@ -423,12 +420,11 @@ var ClusterVersionCapabilitySets = map[ClusterVersionCapabilitySet][]ClusterVers ClusterVersionCapabilityCSISnapshot, ClusterVersionCapabilityNodeTuning, ClusterVersionCapabilityMachineAPI, - ClusterVersionCapabilityBuild, - ClusterVersionCapabilityDeploymentConfig, }, ClusterVersionCapabilitySetCurrent: { ClusterVersionCapabilityBaremetal, ClusterVersionCapabilityConsole, + ClusterVersionCapabilityIngress, ClusterVersionCapabilityInsights, ClusterVersionCapabilityMarketplace, ClusterVersionCapabilityStorage, @@ -436,8 +432,6 @@ var ClusterVersionCapabilitySets = map[ClusterVersionCapabilitySet][]ClusterVers ClusterVersionCapabilityCSISnapshot, ClusterVersionCapabilityNodeTuning, ClusterVersionCapabilityMachineAPI, - ClusterVersionCapabilityBuild, - ClusterVersionCapabilityDeploymentConfig, }, } diff --git a/vendor/github.com/openshift/api/config/v1/types_infrastructure.go b/vendor/github.com/openshift/api/config/v1/types_infrastructure.go index 6c791ee8c8..2c1423deda 100644 --- a/vendor/github.com/openshift/api/config/v1/types_infrastructure.go +++ b/vendor/github.com/openshift/api/config/v1/types_infrastructure.go @@ -580,93 +580,12 @@ const ( type GCPPlatformSpec struct{} // GCPPlatformStatus holds the current status of the Google Cloud Platform infrastructure provider. -// +openshift:validation:FeatureSetAwareXValidation:featureSet=CustomNoUpgrade;TechPreviewNoUpgrade,rule="!has(oldSelf.resourceLabels) && !has(self.resourceLabels) || has(oldSelf.resourceLabels) && has(self.resourceLabels)",message="resourceLabels may only be configured during installation" -// +openshift:validation:FeatureSetAwareXValidation:featureSet=CustomNoUpgrade;TechPreviewNoUpgrade,rule="!has(oldSelf.resourceTags) && !has(self.resourceTags) || has(oldSelf.resourceTags) && has(self.resourceTags)",message="resourceTags may only be configured during installation" type GCPPlatformStatus struct { // resourceGroupName is the Project ID for new GCP resources created for the cluster. ProjectID string `json:"projectID"` // region holds the region for new GCP resources created for the cluster. Region string `json:"region"` - - // resourceLabels is a list of additional labels to apply to GCP resources created for the cluster. - // See https://cloud.google.com/compute/docs/labeling-resources for information on labeling GCP resources. - // GCP supports a maximum of 64 labels per resource. OpenShift reserves 32 labels for internal use, - // allowing 32 labels for user configuration. - // +kubebuilder:validation:MaxItems=32 - // +kubebuilder:validation:XValidation:rule="self.all(x, x in oldSelf) && oldSelf.all(x, x in self)",message="resourceLabels are immutable and may only be configured during installation" - // +listType=map - // +listMapKey=key - // +optional - // +openshift:enable:FeatureSets=CustomNoUpgrade;TechPreviewNoUpgrade - ResourceLabels []GCPResourceLabel `json:"resourceLabels,omitempty"` - - // resourceTags is a list of additional tags to apply to GCP resources created for the cluster. - // See https://cloud.google.com/resource-manager/docs/tags/tags-overview for information on - // tagging GCP resources. GCP supports a maximum of 50 tags per resource. - // +kubebuilder:validation:MaxItems=50 - // +kubebuilder:validation:XValidation:rule="self.all(x, x in oldSelf) && oldSelf.all(x, x in self)",message="resourceTags are immutable and may only be configured during installation" - // +listType=map - // +listMapKey=key - // +optional - // +openshift:enable:FeatureSets=CustomNoUpgrade;TechPreviewNoUpgrade - ResourceTags []GCPResourceTag `json:"resourceTags,omitempty"` -} - -// GCPResourceLabel is a label to apply to GCP resources created for the cluster. -type GCPResourceLabel struct { - // key is the key part of the label. A label key can have a maximum of 63 characters and cannot be empty. - // Label key must begin with a lowercase letter, and must contain only lowercase letters, numeric characters, - // and the following special characters `_-`. Label key must not have the reserved prefixes `kubernetes-io` - // and `openshift-io`. - // +kubebuilder:validation:XValidation:rule="!self.startsWith('openshift-io') && !self.startsWith('kubernetes-io')",message="label keys must not start with either `openshift-io` or `kubernetes-io`" - // +kubebuilder:validation:Required - // +kubebuilder:validation:MinLength=1 - // +kubebuilder:validation:MaxLength=63 - // +kubebuilder:validation:Pattern=`^[a-z][0-9a-z_-]+$` - Key string `json:"key"` - - // value is the value part of the label. A label value can have a maximum of 63 characters and cannot be empty. - // Value must contain only lowercase letters, numeric characters, and the following special characters `_-`. - // +kubebuilder:validation:Required - // +kubebuilder:validation:MinLength=1 - // +kubebuilder:validation:MaxLength=63 - // +kubebuilder:validation:Pattern=`^[0-9a-z_-]+$` - Value string `json:"value"` -} - -// GCPResourceTag is a tag to apply to GCP resources created for the cluster. -type GCPResourceTag struct { - // parentID is the ID of the hierarchical resource where the tags are defined, - // e.g. at the Organization or the Project level. To find the Organization or Project ID refer to the following pages: - // https://cloud.google.com/resource-manager/docs/creating-managing-organization#retrieving_your_organization_id, - // https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects. - // An OrganizationID must consist of decimal numbers, and cannot have leading zeroes. - // A ProjectID must be 6 to 30 characters in length, can only contain lowercase letters, numbers, - // and hyphens, and must start with a letter, and cannot end with a hyphen. - // +kubebuilder:validation:Required - // +kubebuilder:validation:MinLength=1 - // +kubebuilder:validation:MaxLength=32 - // +kubebuilder:validation:Pattern=`(^[1-9][0-9]{0,31}$)|(^[a-z][a-z0-9-]{4,28}[a-z0-9]$)` - ParentID string `json:"parentID"` - - // key is the key part of the tag. A tag key can have a maximum of 63 characters and cannot be empty. - // Tag key must begin and end with an alphanumeric character, and must contain only uppercase, lowercase - // alphanumeric characters, and the following special characters `._-`. - // +kubebuilder:validation:Required - // +kubebuilder:validation:MinLength=1 - // +kubebuilder:validation:MaxLength=63 - // +kubebuilder:validation:Pattern=`^[a-zA-Z0-9]([0-9A-Za-z_.-]{0,61}[a-zA-Z0-9])?$` - Key string `json:"key"` - - // value is the value part of the tag. A tag value can have a maximum of 63 characters and cannot be empty. - // Tag value must begin and end with an alphanumeric character, and must contain only uppercase, lowercase - // alphanumeric characters, and the following special characters `_-.@%=+:,*#&(){}[]` and spaces. - // +kubebuilder:validation:Required - // +kubebuilder:validation:MinLength=1 - // +kubebuilder:validation:MaxLength=63 - // +kubebuilder:validation:Pattern=`^[a-zA-Z0-9]([0-9A-Za-z_.@%=+:,*#&()\[\]{}\-\s]{0,61}[a-zA-Z0-9])?$` - Value string `json:"value"` } // BareMetalPlatformLoadBalancer defines the load balancer used by the cluster on BareMetal platform. diff --git a/vendor/github.com/openshift/api/config/v1/zz_generated.deepcopy.go b/vendor/github.com/openshift/api/config/v1/zz_generated.deepcopy.go index 44d7428e6c..5738354605 100644 --- a/vendor/github.com/openshift/api/config/v1/zz_generated.deepcopy.go +++ b/vendor/github.com/openshift/api/config/v1/zz_generated.deepcopy.go @@ -2137,16 +2137,6 @@ func (in *GCPPlatformSpec) DeepCopy() *GCPPlatformSpec { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *GCPPlatformStatus) DeepCopyInto(out *GCPPlatformStatus) { *out = *in - if in.ResourceLabels != nil { - in, out := &in.ResourceLabels, &out.ResourceLabels - *out = make([]GCPResourceLabel, len(*in)) - copy(*out, *in) - } - if in.ResourceTags != nil { - in, out := &in.ResourceTags, &out.ResourceTags - *out = make([]GCPResourceTag, len(*in)) - copy(*out, *in) - } return } @@ -2160,38 +2150,6 @@ func (in *GCPPlatformStatus) DeepCopy() *GCPPlatformStatus { return out } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *GCPResourceLabel) DeepCopyInto(out *GCPResourceLabel) { - *out = *in - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GCPResourceLabel. -func (in *GCPResourceLabel) DeepCopy() *GCPResourceLabel { - if in == nil { - return nil - } - out := new(GCPResourceLabel) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *GCPResourceTag) DeepCopyInto(out *GCPResourceTag) { - *out = *in - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GCPResourceTag. -func (in *GCPResourceTag) DeepCopy() *GCPResourceTag { - if in == nil { - return nil - } - out := new(GCPResourceTag) - in.DeepCopyInto(out) - return out -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *GenericAPIServerConfig) DeepCopyInto(out *GenericAPIServerConfig) { *out = *in @@ -4377,7 +4335,7 @@ func (in *PlatformStatus) DeepCopyInto(out *PlatformStatus) { if in.GCP != nil { in, out := &in.GCP, &out.GCP *out = new(GCPPlatformStatus) - (*in).DeepCopyInto(*out) + **out = **in } if in.BareMetal != nil { in, out := &in.BareMetal, &out.BareMetal diff --git a/vendor/github.com/openshift/api/config/v1/zz_generated.swagger_doc_generated.go b/vendor/github.com/openshift/api/config/v1/zz_generated.swagger_doc_generated.go index 33ec922375..f84e44573b 100644 --- a/vendor/github.com/openshift/api/config/v1/zz_generated.swagger_doc_generated.go +++ b/vendor/github.com/openshift/api/config/v1/zz_generated.swagger_doc_generated.go @@ -1237,38 +1237,15 @@ func (GCPPlatformSpec) SwaggerDoc() map[string]string { } var map_GCPPlatformStatus = map[string]string{ - "": "GCPPlatformStatus holds the current status of the Google Cloud Platform infrastructure provider.", - "projectID": "resourceGroupName is the Project ID for new GCP resources created for the cluster.", - "region": "region holds the region for new GCP resources created for the cluster.", - "resourceLabels": "resourceLabels is a list of additional labels to apply to GCP resources created for the cluster. See https://cloud.google.com/compute/docs/labeling-resources for information on labeling GCP resources. GCP supports a maximum of 64 labels per resource. OpenShift reserves 32 labels for internal use, allowing 32 labels for user configuration.", - "resourceTags": "resourceTags is a list of additional tags to apply to GCP resources created for the cluster. See https://cloud.google.com/resource-manager/docs/tags/tags-overview for information on tagging GCP resources. GCP supports a maximum of 50 tags per resource.", + "": "GCPPlatformStatus holds the current status of the Google Cloud Platform infrastructure provider.", + "projectID": "resourceGroupName is the Project ID for new GCP resources created for the cluster.", + "region": "region holds the region for new GCP resources created for the cluster.", } func (GCPPlatformStatus) SwaggerDoc() map[string]string { return map_GCPPlatformStatus } -var map_GCPResourceLabel = map[string]string{ - "": "GCPResourceLabel is a label to apply to GCP resources created for the cluster.", - "key": "key is the key part of the label. A label key can have a maximum of 63 characters and cannot be empty. Label key must begin with a lowercase letter, and must contain only lowercase letters, numeric characters, and the following special characters `_-`. Label key must not have the reserved prefixes `kubernetes-io` and `openshift-io`.", - "value": "value is the value part of the label. A label value can have a maximum of 63 characters and cannot be empty. Value must contain only lowercase letters, numeric characters, and the following special characters `_-`.", -} - -func (GCPResourceLabel) SwaggerDoc() map[string]string { - return map_GCPResourceLabel -} - -var map_GCPResourceTag = map[string]string{ - "": "GCPResourceTag is a tag to apply to GCP resources created for the cluster.", - "parentID": "parentID is the ID of the hierarchical resource where the tags are defined, e.g. at the Organization or the Project level. To find the Organization or Project ID refer to the following pages: https://cloud.google.com/resource-manager/docs/creating-managing-organization#retrieving_your_organization_id, https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects. An OrganizationID must consist of decimal numbers, and cannot have leading zeroes. A ProjectID must be 6 to 30 characters in length, can only contain lowercase letters, numbers, and hyphens, and must start with a letter, and cannot end with a hyphen.", - "key": "key is the key part of the tag. A tag key can have a maximum of 63 characters and cannot be empty. Tag key must begin and end with an alphanumeric character, and must contain only uppercase, lowercase alphanumeric characters, and the following special characters `._-`.", - "value": "value is the value part of the tag. A tag value can have a maximum of 63 characters and cannot be empty. Tag value must begin and end with an alphanumeric character, and must contain only uppercase, lowercase alphanumeric characters, and the following special characters `_-.@%=+:,*#&(){}[]` and spaces.", -} - -func (GCPResourceTag) SwaggerDoc() map[string]string { - return map_GCPResourceTag -} - var map_IBMCloudPlatformSpec = map[string]string{ "": "IBMCloudPlatformSpec holds the desired state of the IBMCloud infrastructure provider. This only includes fields that can be modified in the cluster.", } diff --git a/vendor/github.com/openshift/api/console/v1/00_consoleclidownload.crd.yaml b/vendor/github.com/openshift/api/console/v1/0000_10_consoleclidownload.crd.yaml similarity index 100% rename from vendor/github.com/openshift/api/console/v1/00_consoleclidownload.crd.yaml rename to vendor/github.com/openshift/api/console/v1/0000_10_consoleclidownload.crd.yaml diff --git a/vendor/github.com/openshift/api/console/v1/00_consoleexternalloglink.crd.yaml b/vendor/github.com/openshift/api/console/v1/0000_10_consoleexternalloglink.crd.yaml similarity index 100% rename from vendor/github.com/openshift/api/console/v1/00_consoleexternalloglink.crd.yaml rename to vendor/github.com/openshift/api/console/v1/0000_10_consoleexternalloglink.crd.yaml diff --git a/vendor/github.com/openshift/api/console/v1/00_consolelink.crd.yaml b/vendor/github.com/openshift/api/console/v1/0000_10_consolelink.crd.yaml similarity index 100% rename from vendor/github.com/openshift/api/console/v1/00_consolelink.crd.yaml rename to vendor/github.com/openshift/api/console/v1/0000_10_consolelink.crd.yaml diff --git a/vendor/github.com/openshift/api/console/v1/00_consolenotification.crd.yaml b/vendor/github.com/openshift/api/console/v1/0000_10_consolenotification.crd.yaml similarity index 100% rename from vendor/github.com/openshift/api/console/v1/00_consolenotification.crd.yaml rename to vendor/github.com/openshift/api/console/v1/0000_10_consolenotification.crd.yaml diff --git a/vendor/github.com/openshift/api/console/v1/90_consoleplugin.crd.yaml b/vendor/github.com/openshift/api/console/v1/0000_10_consoleplugin.crd.yaml similarity index 100% rename from vendor/github.com/openshift/api/console/v1/90_consoleplugin.crd.yaml rename to vendor/github.com/openshift/api/console/v1/0000_10_consoleplugin.crd.yaml diff --git a/vendor/github.com/openshift/api/console/v1/00_consolequickstart.crd.yaml b/vendor/github.com/openshift/api/console/v1/0000_10_consolequickstart.crd.yaml similarity index 100% rename from vendor/github.com/openshift/api/console/v1/00_consolequickstart.crd.yaml rename to vendor/github.com/openshift/api/console/v1/0000_10_consolequickstart.crd.yaml diff --git a/vendor/github.com/openshift/api/console/v1/00_consolesample.crd.yaml b/vendor/github.com/openshift/api/console/v1/0000_10_consolesample.crd.yaml similarity index 100% rename from vendor/github.com/openshift/api/console/v1/00_consolesample.crd.yaml rename to vendor/github.com/openshift/api/console/v1/0000_10_consolesample.crd.yaml diff --git a/vendor/github.com/openshift/api/console/v1/00_consoleyamlsample.crd.yaml b/vendor/github.com/openshift/api/console/v1/0000_10_consoleyamlsample.crd.yaml similarity index 100% rename from vendor/github.com/openshift/api/console/v1/00_consoleyamlsample.crd.yaml rename to vendor/github.com/openshift/api/console/v1/0000_10_consoleyamlsample.crd.yaml diff --git a/vendor/github.com/openshift/api/console/v1/stable.consoleclidownload.testsuite.yaml b/vendor/github.com/openshift/api/console/v1/stable.consoleclidownload.testsuite.yaml index 8faef369b3..0f1b27db92 100644 --- a/vendor/github.com/openshift/api/console/v1/stable.consoleclidownload.testsuite.yaml +++ b/vendor/github.com/openshift/api/console/v1/stable.consoleclidownload.testsuite.yaml @@ -1,6 +1,6 @@ apiVersion: apiextensions.k8s.io/v1 # Hack because controller-gen complains if we don't have this name: "[Stable] ConsoleCLIDownload" -crd: 00_consoleclidownload.crd.yaml +crd: 0000_10_consoleclidownload.crd.yaml tests: onCreate: - name: Should be able to create a minimal ConsoleCLIDownload diff --git a/vendor/github.com/openshift/api/console/v1/stable.consoleexternalloglink.testsuite.yaml b/vendor/github.com/openshift/api/console/v1/stable.consoleexternalloglink.testsuite.yaml index 8602d88b8e..76846597f9 100644 --- a/vendor/github.com/openshift/api/console/v1/stable.consoleexternalloglink.testsuite.yaml +++ b/vendor/github.com/openshift/api/console/v1/stable.consoleexternalloglink.testsuite.yaml @@ -1,6 +1,6 @@ apiVersion: apiextensions.k8s.io/v1 # Hack because controller-gen complains if we don't have this name: "[Stable] ConsoleExternalLogLink" -crd: 00_consoleexternalloglink.crd.yaml +crd: 0000_10_consoleexternalloglink.crd.yaml tests: onCreate: - name: Should be able to create a minimal ConsoleExternalLogLink diff --git a/vendor/github.com/openshift/api/console/v1/stable.consolelink.testsuite.yaml b/vendor/github.com/openshift/api/console/v1/stable.consolelink.testsuite.yaml index 87415ec163..9ab5596427 100644 --- a/vendor/github.com/openshift/api/console/v1/stable.consolelink.testsuite.yaml +++ b/vendor/github.com/openshift/api/console/v1/stable.consolelink.testsuite.yaml @@ -1,6 +1,6 @@ apiVersion: apiextensions.k8s.io/v1 # Hack because controller-gen complains if we don't have this name: "[Stable] ConsoleLink" -crd: 00_consolelink.crd.yaml +crd: 0000_10_consolelink.crd.yaml tests: onCreate: - name: Should be able to create a minimal ConsoleLink diff --git a/vendor/github.com/openshift/api/console/v1/stable.consolenotification.testsuite.yaml b/vendor/github.com/openshift/api/console/v1/stable.consolenotification.testsuite.yaml index c60dd0a64e..ade1c6ac69 100644 --- a/vendor/github.com/openshift/api/console/v1/stable.consolenotification.testsuite.yaml +++ b/vendor/github.com/openshift/api/console/v1/stable.consolenotification.testsuite.yaml @@ -1,6 +1,6 @@ apiVersion: apiextensions.k8s.io/v1 # Hack because controller-gen complains if we don't have this name: "[Stable] ConsoleNotification" -crd: 00_consolenotification.crd.yaml +crd: 0000_10_consolenotification.crd.yaml tests: onCreate: - name: Should be able to create a minimal ConsoleNotification diff --git a/vendor/github.com/openshift/api/console/v1/stable.consoleplugin.testsuite.yaml b/vendor/github.com/openshift/api/console/v1/stable.consoleplugin.testsuite.yaml index 0abe23ba7a..627cea6f38 100644 --- a/vendor/github.com/openshift/api/console/v1/stable.consoleplugin.testsuite.yaml +++ b/vendor/github.com/openshift/api/console/v1/stable.consoleplugin.testsuite.yaml @@ -1,6 +1,6 @@ apiVersion: apiextensions.k8s.io/v1 # Hack because controller-gen complains if we don't have this name: "[Stable] ConsolePlugin" -crd: 90_consoleplugin.crd.yaml +crd: 0000_10_consoleplugin.crd.yaml tests: onCreate: - name: Should be able to create a minimal ConsolePlugin diff --git a/vendor/github.com/openshift/api/console/v1/stable.consolequickstart.testsuite.yaml b/vendor/github.com/openshift/api/console/v1/stable.consolequickstart.testsuite.yaml index d9c3ec93f4..b5a403be59 100644 --- a/vendor/github.com/openshift/api/console/v1/stable.consolequickstart.testsuite.yaml +++ b/vendor/github.com/openshift/api/console/v1/stable.consolequickstart.testsuite.yaml @@ -1,6 +1,6 @@ apiVersion: apiextensions.k8s.io/v1 # Hack because controller-gen complains if we don't have this name: "[Stable] ConsoleQuickStart" -crd: 00_consolequickstart.crd.yaml +crd: 0000_10_consolequickstart.crd.yaml tests: onCreate: - name: Should be able to create a minimal ConsoleQuickStart diff --git a/vendor/github.com/openshift/api/console/v1/stable.consolesample.testsuite.yaml b/vendor/github.com/openshift/api/console/v1/stable.consolesample.testsuite.yaml index f5af743603..8929fa9eb4 100644 --- a/vendor/github.com/openshift/api/console/v1/stable.consolesample.testsuite.yaml +++ b/vendor/github.com/openshift/api/console/v1/stable.consolesample.testsuite.yaml @@ -1,6 +1,6 @@ apiVersion: apiextensions.k8s.io/v1 # Hack because controller-gen complains if we don't have this name: "[Stable] ConsoleSample" -crd: 00_consolesample.crd.yaml +crd: 0000_10_consolesample.crd.yaml tests: onCreate: - name: Should be able to create a minimal ConsoleSample with GitImport diff --git a/vendor/github.com/openshift/api/console/v1/stable.consoleyamlsample.testsuite.yaml b/vendor/github.com/openshift/api/console/v1/stable.consoleyamlsample.testsuite.yaml index 1e72d5ac71..661c48fe07 100644 --- a/vendor/github.com/openshift/api/console/v1/stable.consoleyamlsample.testsuite.yaml +++ b/vendor/github.com/openshift/api/console/v1/stable.consoleyamlsample.testsuite.yaml @@ -1,6 +1,6 @@ apiVersion: apiextensions.k8s.io/v1 # Hack because controller-gen complains if we don't have this name: "[Stable] ConsoleYAMLSample" -crd: 00_consoleyamlsample.crd.yaml +crd: 0000_10_consoleyamlsample.crd.yaml tests: onCreate: - name: Should be able to create a minimal ConsoleYAMLSample diff --git a/vendor/github.com/openshift/api/console/v1alpha1/90_consoleplugin.crd.yaml b/vendor/github.com/openshift/api/console/v1alpha1/0000_10_consoleplugin.crd.yaml similarity index 100% rename from vendor/github.com/openshift/api/console/v1alpha1/90_consoleplugin.crd.yaml rename to vendor/github.com/openshift/api/console/v1alpha1/0000_10_consoleplugin.crd.yaml diff --git a/vendor/github.com/openshift/api/console/v1alpha1/stable.consoleplugin.testsuite.yaml b/vendor/github.com/openshift/api/console/v1alpha1/stable.consoleplugin.testsuite.yaml index d861a65434..138e8f6fa5 100644 --- a/vendor/github.com/openshift/api/console/v1alpha1/stable.consoleplugin.testsuite.yaml +++ b/vendor/github.com/openshift/api/console/v1alpha1/stable.consoleplugin.testsuite.yaml @@ -1,6 +1,6 @@ apiVersion: apiextensions.k8s.io/v1 # Hack because controller-gen complains if we don't have this name: "[Stable] ConsolePlugin" -crd: 90_consoleplugin.crd.yaml +crd: 0000_10_consoleplugin.crd.yaml tests: onCreate: - name: Should be able to create a minimal ConsolePlugin diff --git a/vendor/github.com/openshift/api/machine/v1/0000_10_controlplanemachineset.crd.yaml b/vendor/github.com/openshift/api/machine/v1/0000_10_controlplanemachineset.crd.yaml index 699621ec49..00b5311a0f 100644 --- a/vendor/github.com/openshift/api/machine/v1/0000_10_controlplanemachineset.crd.yaml +++ b/vendor/github.com/openshift/api/machine/v1/0000_10_controlplanemachineset.crd.yaml @@ -261,8 +261,7 @@ spec: rootVolume: description: rootVolume contains settings that will be used by the OpenStack machine provider to create the root volume attached to the VM. If not specified, no root volume will be created. type: object - required: - - volumeType + minProperties: 1 properties: availabilityZone: description: availabilityZone specifies the Cinder availability zone where the root volume will be created. If not specifified, the root volume will be created in the availability zone specified by the volume type in the cinder configuration. If the volume type (configured in the OpenStack cluster) does not specify an availability zone, the root volume will be created in the default availability zone specified in the cinder configuration. See https://docs.openstack.org/cinder/latest/admin/availability-zone-type.html for more details. If the OpenStack cluster is deployed with the cross_az_attach configuration option set to false, the root volume will have to be in the same availability zone as the VM (defined by OpenStackFailureDomain.AvailabilityZone). Availability zone names must NOT contain spaces otherwise it will lead to volume that belongs to this availability zone register failure, see kubernetes/cloud-provider-openstack#1379 for further information. The maximum length of availability zone name is 63 as per labels limits. @@ -271,7 +270,7 @@ spec: minLength: 1 pattern: ^[^ ]*$ volumeType: - description: volumeType specifies the type of the root volume that will be provisioned. The maximum length of a volume type name is 255 characters, as per the OpenStack limit. + description: volumeType specifies the type of the root volume that will be provisioned. If not specifified, the root volume will be created as the type in the machine template. The maximum length of a volume type name is 255 characters, as per the OpenStack limit. type: string maxLength: 255 minLength: 1 diff --git a/vendor/github.com/openshift/api/machine/v1/stable.controlplanemachineset.openstack.testsuite.yaml b/vendor/github.com/openshift/api/machine/v1/stable.controlplanemachineset.openstack.testsuite.yaml index a09de51e0f..e5759f4b06 100644 --- a/vendor/github.com/openshift/api/machine/v1/stable.controlplanemachineset.openstack.testsuite.yaml +++ b/vendor/github.com/openshift/api/machine/v1/stable.controlplanemachineset.openstack.testsuite.yaml @@ -213,7 +213,6 @@ tests: openstack: - rootVolume: availabilityZone: foo - volumeType: fast expected: | apiVersion: machine.openshift.io/v1 kind: ControlPlaneMachineSet @@ -241,7 +240,6 @@ tests: openstack: - rootVolume: availabilityZone: foo - volumeType: fast - name: Should accept an OpenStack failure domain with only the root volume type provided initial: | apiVersion: machine.openshift.io/v1 @@ -318,7 +316,6 @@ tests: - availabilityZone: foo rootVolume: availabilityZone: foo - volumeType: fast expected: | apiVersion: machine.openshift.io/v1 kind: ControlPlaneMachineSet @@ -347,7 +344,6 @@ tests: - availabilityZone: foo rootVolume: availabilityZone: foo - volumeType: fast - name: Should accept an OpenStack failure domain with both availabilityZone and root volume type provided initial: | apiVersion: machine.openshift.io/v1 @@ -403,32 +399,7 @@ tests: rootVolume: availabilityZone: foo volumeType: bar - - name: Should reject an OpenStack failure domain with no rootVolume volumeType provided - initial: | - apiVersion: machine.openshift.io/v1 - kind: ControlPlaneMachineSet - spec: - selector: - matchLabels: - machine.openshift.io/cluster-api-machine-role: master - machine.openshift.io/cluster-api-machine-type: master - template: - machineType: machines_v1beta1_machine_openshift_io - machines_v1beta1_machine_openshift_io: - metadata: - labels: - machine.openshift.io/cluster-api-machine-role: master - machine.openshift.io/cluster-api-machine-type: master - machine.openshift.io/cluster-api-cluster: cluster - spec: - providerSpec: {} - failureDomains: - platform: OpenStack - openstack: - - rootVolume: - availabilityZone: foo - expectedError: "spec.template.machines_v1beta1_machine_openshift_io.failureDomains.openstack[0].rootVolume.volumeType: Required value, : Invalid value: \"null\": some validation rules were not checked" - - name: Should reject an OpenStack failure domain with an empty rootVolume volumeType provided + - name: Should reject an OpenStack failure domain with too long a rootVolume volumeType name initial: | apiVersion: machine.openshift.io/v1 kind: ControlPlaneMachineSet @@ -450,10 +421,11 @@ tests: failureDomains: platform: OpenStack openstack: - - rootVolume: - volumeType: "" - expectedError: "spec.template.machines_v1beta1_machine_openshift_io.failureDomains.openstack[0].rootVolume.volumeType: Invalid value: \"\": spec.template.machines_v1beta1_machine_openshift_io.failureDomains.openstack[0].rootVolume.volumeType in body should be at least 1 chars long" - - name: Should reject an OpenStack failure domain with too long a rootVolume volumeType name + - availabilityZone: foo + rootVolume: + volumeType: a123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345 + expectedError: "spec.template.machines_v1beta1_machine_openshift_io.failureDomains.openstack[0].rootVolume.volumeType: Too long: may not be longer than 255" + - name: Should reject an OpenStack failure domain with an empty rootVolume provided initial: | apiVersion: machine.openshift.io/v1 kind: ControlPlaneMachineSet @@ -476,9 +448,8 @@ tests: platform: OpenStack openstack: - availabilityZone: foo - rootVolume: - volumeType: a123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345 - expectedError: "spec.template.machines_v1beta1_machine_openshift_io.failureDomains.openstack[0].rootVolume.volumeType: Too long: may not be longer than 255" + rootVolume: {} + expectedError: "spec.template.machines_v1beta1_machine_openshift_io.failureDomains.openstack[0].rootVolume in body should have at least 1 properties" - name: Should reject an OpenStack failure domain with both availabilityZone and root volume provided but with missing root volume availabilityZone initial: | apiVersion: machine.openshift.io/v1 @@ -578,7 +549,6 @@ tests: openstack: - rootVolume: availabilityZone: "" - volumeType: fast expectedError: "spec.template.machines_v1beta1_machine_openshift_io.failureDomains.openstack[0].rootVolume.availabilityZone in body should be at least 1 chars long" - name: Should reject an OpenStack failure domain with an invalid availabilityZone provided initial: | @@ -628,5 +598,4 @@ tests: openstack: - rootVolume: availabilityZone: "foo bar" - volumeType: fast expectedError: "spec.template.machines_v1beta1_machine_openshift_io.failureDomains.openstack[0].rootVolume.availabilityZone in body should match" diff --git a/vendor/github.com/openshift/api/machine/v1/types_controlplanemachineset.go b/vendor/github.com/openshift/api/machine/v1/types_controlplanemachineset.go index 9f81f4d103..b31e0e5486 100644 --- a/vendor/github.com/openshift/api/machine/v1/types_controlplanemachineset.go +++ b/vendor/github.com/openshift/api/machine/v1/types_controlplanemachineset.go @@ -325,6 +325,7 @@ type OpenStackFailureDomain struct { // RootVolume represents the volume metadata to boot from. // The original RootVolume struct is defined in the v1alpha1 but it's not best practice to use it directly here so we define a new one // that should stay in sync with the original one. +// +kubebuilder:validation:MinProperties:=1 type RootVolume struct { // availabilityZone specifies the Cinder availability zone where the root volume will be created. // If not specifified, the root volume will be created in the availability zone specified by the volume type in the cinder configuration. @@ -342,16 +343,12 @@ type RootVolume struct { AvailabilityZone string `json:"availabilityZone,omitempty"` // volumeType specifies the type of the root volume that will be provisioned. + // If not specifified, the root volume will be created as the type in the machine template. // The maximum length of a volume type name is 255 characters, as per the OpenStack limit. - // + --- - // + Historically, the installer has always required a volume type to be specified when deploying - // + the control plane with a root volume. This is because the default volume type in Cinder is not guaranteed - // + to be available, therefore we prefer the user to be explicit about the volume type to use. - // + We apply the same logic in CPMS: if the failure domain specifies a root volume, we require the user to specify a volume type. - // +kubebuilder:validation:Required // +kubebuilder:validation:MinLength=1 // +kubebuilder:validation:MaxLength=255 - VolumeType string `json:"volumeType"` + // +optional + VolumeType string `json:"volumeType,omitempty"` } // ControlPlaneMachineSetStatus represents the status of the ControlPlaneMachineSet CRD. diff --git a/vendor/github.com/openshift/api/machine/v1/zz_generated.swagger_doc_generated.go b/vendor/github.com/openshift/api/machine/v1/zz_generated.swagger_doc_generated.go index 03f4f8267c..01269a67d1 100644 --- a/vendor/github.com/openshift/api/machine/v1/zz_generated.swagger_doc_generated.go +++ b/vendor/github.com/openshift/api/machine/v1/zz_generated.swagger_doc_generated.go @@ -287,7 +287,7 @@ func (OpenStackFailureDomain) SwaggerDoc() map[string]string { var map_RootVolume = map[string]string{ "": "RootVolume represents the volume metadata to boot from. The original RootVolume struct is defined in the v1alpha1 but it's not best practice to use it directly here so we define a new one that should stay in sync with the original one.", "availabilityZone": "availabilityZone specifies the Cinder availability zone where the root volume will be created. If not specifified, the root volume will be created in the availability zone specified by the volume type in the cinder configuration. If the volume type (configured in the OpenStack cluster) does not specify an availability zone, the root volume will be created in the default availability zone specified in the cinder configuration. See https://docs.openstack.org/cinder/latest/admin/availability-zone-type.html for more details. If the OpenStack cluster is deployed with the cross_az_attach configuration option set to false, the root volume will have to be in the same availability zone as the VM (defined by OpenStackFailureDomain.AvailabilityZone). Availability zone names must NOT contain spaces otherwise it will lead to volume that belongs to this availability zone register failure, see kubernetes/cloud-provider-openstack#1379 for further information. The maximum length of availability zone name is 63 as per labels limits.", - "volumeType": "volumeType specifies the type of the root volume that will be provisioned. The maximum length of a volume type name is 255 characters, as per the OpenStack limit. ", + "volumeType": "volumeType specifies the type of the root volume that will be provisioned. If not specifified, the root volume will be created as the type in the machine template. The maximum length of a volume type name is 255 characters, as per the OpenStack limit.", } func (RootVolume) SwaggerDoc() map[string]string { diff --git a/vendor/github.com/openshift/api/openapi/openapi.json b/vendor/github.com/openshift/api/openapi/openapi.json index 7b73e6de6d..33b36a9521 100644 --- a/vendor/github.com/openshift/api/openapi/openapi.json +++ b/vendor/github.com/openshift/api/openapi/openapi.json @@ -6256,76 +6256,6 @@ "description": "region holds the region for new GCP resources created for the cluster.", "type": "string", "default": "" - }, - "resourceLabels": { - "description": "resourceLabels is a list of additional labels to apply to GCP resources created for the cluster. See https://cloud.google.com/compute/docs/labeling-resources for information on labeling GCP resources. GCP supports a maximum of 64 labels per resource. OpenShift reserves 32 labels for internal use, allowing 32 labels for user configuration.", - "type": "array", - "items": { - "default": {}, - "$ref": "#/definitions/com.github.openshift.api.config.v1.GCPResourceLabel" - }, - "x-kubernetes-list-map-keys": [ - "key" - ], - "x-kubernetes-list-type": "map" - }, - "resourceTags": { - "description": "resourceTags is a list of additional tags to apply to GCP resources created for the cluster. See https://cloud.google.com/resource-manager/docs/tags/tags-overview for information on tagging GCP resources. GCP supports a maximum of 50 tags per resource.", - "type": "array", - "items": { - "default": {}, - "$ref": "#/definitions/com.github.openshift.api.config.v1.GCPResourceTag" - }, - "x-kubernetes-list-map-keys": [ - "key" - ], - "x-kubernetes-list-type": "map" - } - } - }, - "com.github.openshift.api.config.v1.GCPResourceLabel": { - "description": "GCPResourceLabel is a label to apply to GCP resources created for the cluster.", - "type": "object", - "required": [ - "key", - "value" - ], - "properties": { - "key": { - "description": "key is the key part of the label. A label key can have a maximum of 63 characters and cannot be empty. Label key must begin with a lowercase letter, and must contain only lowercase letters, numeric characters, and the following special characters `_-`. Label key must not have the reserved prefixes `kubernetes-io` and `openshift-io`.", - "type": "string", - "default": "" - }, - "value": { - "description": "value is the value part of the label. A label value can have a maximum of 63 characters and cannot be empty. Value must contain only lowercase letters, numeric characters, and the following special characters `_-`.", - "type": "string", - "default": "" - } - } - }, - "com.github.openshift.api.config.v1.GCPResourceTag": { - "description": "GCPResourceTag is a tag to apply to GCP resources created for the cluster.", - "type": "object", - "required": [ - "parentID", - "key", - "value" - ], - "properties": { - "key": { - "description": "key is the key part of the tag. A tag key can have a maximum of 63 characters and cannot be empty. Tag key must begin and end with an alphanumeric character, and must contain only uppercase, lowercase alphanumeric characters, and the following special characters `._-`.", - "type": "string", - "default": "" - }, - "parentID": { - "description": "parentID is the ID of the hierarchical resource where the tags are defined, e.g. at the Organization or the Project level. To find the Organization or Project ID refer to the following pages: https://cloud.google.com/resource-manager/docs/creating-managing-organization#retrieving_your_organization_id, https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects. An OrganizationID must consist of decimal numbers, and cannot have leading zeroes. A ProjectID must be 6 to 30 characters in length, can only contain lowercase letters, numbers, and hyphens, and must start with a letter, and cannot end with a hyphen.", - "type": "string", - "default": "" - }, - "value": { - "description": "value is the value part of the tag. A tag value can have a maximum of 63 characters and cannot be empty. Tag value must begin and end with an alphanumeric character, and must contain only uppercase, lowercase alphanumeric characters, and the following special characters `_-.@%=+:,*#&(){}[]` and spaces.", - "type": "string", - "default": "" } } }, @@ -18164,18 +18094,14 @@ "com.github.openshift.api.machine.v1.RootVolume": { "description": "RootVolume represents the volume metadata to boot from. The original RootVolume struct is defined in the v1alpha1 but it's not best practice to use it directly here so we define a new one that should stay in sync with the original one.", "type": "object", - "required": [ - "volumeType" - ], "properties": { "availabilityZone": { "description": "availabilityZone specifies the Cinder availability zone where the root volume will be created. If not specifified, the root volume will be created in the availability zone specified by the volume type in the cinder configuration. If the volume type (configured in the OpenStack cluster) does not specify an availability zone, the root volume will be created in the default availability zone specified in the cinder configuration. See https://docs.openstack.org/cinder/latest/admin/availability-zone-type.html for more details. If the OpenStack cluster is deployed with the cross_az_attach configuration option set to false, the root volume will have to be in the same availability zone as the VM (defined by OpenStackFailureDomain.AvailabilityZone). Availability zone names must NOT contain spaces otherwise it will lead to volume that belongs to this availability zone register failure, see kubernetes/cloud-provider-openstack#1379 for further information. The maximum length of availability zone name is 63 as per labels limits.", "type": "string" }, "volumeType": { - "description": "volumeType specifies the type of the root volume that will be provisioned. The maximum length of a volume type name is 255 characters, as per the OpenStack limit.", - "type": "string", - "default": "" + "description": "volumeType specifies the type of the root volume that will be provisioned. If not specifified, the root volume will be created as the type in the machine template. The maximum length of a volume type name is 255 characters, as per the OpenStack limit.", + "type": "string" } } }, @@ -25569,91 +25495,10 @@ } } }, - "com.github.openshift.api.operator.v1.IngressControllerHTTPHeader": { - "description": "IngressControllerHTTPHeader specifies configuration for setting or deleting an HTTP header.", - "type": "object", - "required": [ - "name", - "action" - ], - "properties": { - "action": { - "description": "action specifies actions to perform on headers, such as setting or deleting headers.", - "default": {}, - "$ref": "#/definitions/com.github.openshift.api.operator.v1.IngressControllerHTTPHeaderActionUnion" - }, - "name": { - "description": "name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header name as defined in RFC 2616 section 4.2. The name must consist only of alphanumeric and the following special characters, \"-!#$%&'*+.^_`\". The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Host, Cookie, Set-Cookie. It must be no more than 1024 characters in length. Header name must be unique.", - "type": "string", - "default": "" - } - } - }, - "com.github.openshift.api.operator.v1.IngressControllerHTTPHeaderActionUnion": { - "description": "IngressControllerHTTPHeaderActionUnion specifies an action to take on an HTTP header.", - "type": "object", - "required": [ - "type" - ], - "properties": { - "set": { - "description": "set specifies how the HTTP header should be set. This field is required when type is Set and forbidden otherwise.", - "$ref": "#/definitions/com.github.openshift.api.operator.v1.IngressControllerSetHTTPHeader" - }, - "type": { - "description": "type defines the type of the action to be applied on the header. Possible values are Set or Delete. Set allows you to set HTTP request and response headers. Delete allows you to delete HTTP request and response headers.", - "type": "string", - "default": "" - } - }, - "x-kubernetes-unions": [ - { - "discriminator": "type", - "fields-to-discriminateBy": { - "set": "Set" - } - } - ] - }, - "com.github.openshift.api.operator.v1.IngressControllerHTTPHeaderActions": { - "description": "IngressControllerHTTPHeaderActions defines configuration for actions on HTTP request and response headers.", - "type": "object", - "properties": { - "request": { - "description": "request is a list of HTTP request headers to modify. Actions defined here will modify the request headers of all requests passing through an ingress controller. These actions are applied to all Routes i.e. for all connections handled by the ingress controller defined within a cluster. IngressController actions for request headers will be executed before Route actions. Currently, actions may define to either `Set` or `Delete` headers values. Actions are applied in sequence as defined in this list. A maximum of 20 request header actions may be configured. Sample fetchers allowed are \"req.hdr\" and \"ssl_c_der\". Converters allowed are \"lower\" and \"base64\". Example header values: \"%[req.hdr(X-target),lower]\", \"%{+Q}[ssl_c_der,base64]\".", - "type": "array", - "items": { - "default": {}, - "$ref": "#/definitions/com.github.openshift.api.operator.v1.IngressControllerHTTPHeader" - }, - "x-kubernetes-list-map-keys": [ - "name" - ], - "x-kubernetes-list-type": "map" - }, - "response": { - "description": "response is a list of HTTP response headers to modify. Actions defined here will modify the response headers of all requests passing through an ingress controller. These actions are applied to all Routes i.e. for all connections handled by the ingress controller defined within a cluster. IngressController actions for response headers will be executed after Route actions. Currently, actions may define to either `Set` or `Delete` headers values. Actions are applied in sequence as defined in this list. A maximum of 20 response header actions may be configured. Sample fetchers allowed are \"res.hdr\" and \"ssl_c_der\". Converters allowed are \"lower\" and \"base64\". Example header values: \"%[res.hdr(X-target),lower]\", \"%{+Q}[ssl_c_der,base64]\".", - "type": "array", - "items": { - "default": {}, - "$ref": "#/definitions/com.github.openshift.api.operator.v1.IngressControllerHTTPHeader" - }, - "x-kubernetes-list-map-keys": [ - "name" - ], - "x-kubernetes-list-type": "map" - } - } - }, "com.github.openshift.api.operator.v1.IngressControllerHTTPHeaders": { "description": "IngressControllerHTTPHeaders specifies how the IngressController handles certain HTTP headers.", "type": "object", "properties": { - "actions": { - "description": "actions specifies options for modifying headers and their values. Note that this option only applies to cleartext HTTP connections and to secure HTTP connections for which the ingress controller terminates encryption (that is, edge-terminated or reencrypt connections). Headers cannot be modified for TLS passthrough connections. Setting the HSTS (`Strict-Transport-Security`) header is not supported via actions. `Strict-Transport-Security` may only be configured using the \"haproxy.router.openshift.io/hsts_header\" route annotation, and only in accordance with the policy specified in Ingress.Spec.RequiredHSTSPolicies. Any actions defined here are applied after any actions related to the following other fields: cache-control, spec.clientTLS, spec.httpHeaders.forwardedHeaderPolicy, spec.httpHeaders.uniqueId, and spec.httpHeaders.headerNameCaseAdjustments. In case of HTTP request headers, the actions specified in spec.httpHeaders.actions on the Route will be executed after the actions specified in the IngressController's spec.httpHeaders.actions field. In case of HTTP response headers, the actions specified in spec.httpHeaders.actions on the IngressController will be executed after the actions specified in the Route's spec.httpHeaders.actions field. Headers set using this API cannot be captured for use in access logs. The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Host, Cookie, Set-Cookie. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. Please refer to the documentation for that API field for more details.", - "default": {}, - "$ref": "#/definitions/com.github.openshift.api.operator.v1.IngressControllerHTTPHeaderActions" - }, "forwardedHeaderPolicy": { "description": "forwardedHeaderPolicy specifies when and how the IngressController sets the Forwarded, X-Forwarded-For, X-Forwarded-Host, X-Forwarded-Port, X-Forwarded-Proto, and X-Forwarded-Proto-Version HTTP headers. The value may be one of the following:\n\n* \"Append\", which specifies that the IngressController appends the\n headers, preserving existing headers.\n\n* \"Replace\", which specifies that the IngressController sets the\n headers, replacing any existing Forwarded or X-Forwarded-* headers.\n\n* \"IfNone\", which specifies that the IngressController sets the\n headers if they are not already set.\n\n* \"Never\", which specifies that the IngressController never sets the\n headers, preserving any existing headers.\n\nBy default, the policy is \"Append\".", "type": "string" @@ -25726,20 +25571,6 @@ } } }, - "com.github.openshift.api.operator.v1.IngressControllerSetHTTPHeader": { - "description": "IngressControllerSetHTTPHeader defines the value which needs to be set on an HTTP header.", - "type": "object", - "required": [ - "value" - ], - "properties": { - "value": { - "description": "value specifies a header value. Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. The value of this field must be no more than 16384 characters in length. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController.", - "type": "string", - "default": "" - } - } - }, "com.github.openshift.api.operator.v1.IngressControllerSpec": { "description": "IngressControllerSpec is the specification of the desired behavior of the IngressController.", "type": "object", @@ -26889,6 +26720,175 @@ } } }, + "com.github.openshift.api.operator.v1.MachineConfiguration": { + "description": "MachineConfiguration provides information to configure an operator to manage Machine Configuration.\n\nCompatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).", + "type": "object", + "required": [ + "metadata", + "spec" + ], + "properties": { + "apiVersion": { + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + "type": "string" + }, + "kind": { + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + "type": "string" + }, + "metadata": { + "description": "metadata is the standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + "default": {}, + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta" + }, + "spec": { + "description": "spec is the specification of the desired behavior of the Machine Config Operator", + "default": {}, + "$ref": "#/definitions/com.github.openshift.api.operator.v1.MachineConfigurationSpec" + }, + "status": { + "description": "status is the most recently observed status of the Machine Config Operator", + "default": {}, + "$ref": "#/definitions/com.github.openshift.api.operator.v1.MachineConfigurationStatus" + } + } + }, + "com.github.openshift.api.operator.v1.MachineConfigurationList": { + "description": "MachineConfigurationList is a collection of items\n\nCompatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).", + "type": "object", + "required": [ + "metadata", + "items" + ], + "properties": { + "apiVersion": { + "description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + "type": "string" + }, + "items": { + "description": "Items contains the items", + "type": "array", + "items": { + "default": {}, + "$ref": "#/definitions/com.github.openshift.api.operator.v1.MachineConfiguration" + } + }, + "kind": { + "description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + "type": "string" + }, + "metadata": { + "description": "metadata is the standard list's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + "default": {}, + "$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ListMeta" + } + } + }, + "com.github.openshift.api.operator.v1.MachineConfigurationSpec": { + "type": "object", + "required": [ + "managementState", + "forceRedeploymentReason" + ], + "properties": { + "failedRevisionLimit": { + "description": "failedRevisionLimit is the number of failed static pod installer revisions to keep on disk and in the api -1 = unlimited, 0 or unset = 5 (default)", + "type": "integer", + "format": "int32" + }, + "forceRedeploymentReason": { + "description": "forceRedeploymentReason can be used to force the redeployment of the operand by providing a unique string. This provides a mechanism to kick a previously failed deployment and provide a reason why you think it will work this time instead of failing again on the same config.", + "type": "string", + "default": "" + }, + "logLevel": { + "description": "logLevel is an intent based logging for an overall component. It does not give fine grained control, but it is a simple way to manage coarse grained logging choices that operators have to interpret for their operands.\n\nValid values are: \"Normal\", \"Debug\", \"Trace\", \"TraceAll\". Defaults to \"Normal\".", + "type": "string" + }, + "managementState": { + "description": "managementState indicates whether and how the operator should manage the component", + "type": "string", + "default": "" + }, + "observedConfig": { + "description": "observedConfig holds a sparse config that controller has observed from the cluster state. It exists in spec because it is an input to the level for the operator", + "default": {}, + "$ref": "#/definitions/io.k8s.apimachinery.pkg.runtime.RawExtension" + }, + "operatorLogLevel": { + "description": "operatorLogLevel is an intent based logging for the operator itself. It does not give fine grained control, but it is a simple way to manage coarse grained logging choices that operators have to interpret for themselves.\n\nValid values are: \"Normal\", \"Debug\", \"Trace\", \"TraceAll\". Defaults to \"Normal\".", + "type": "string" + }, + "succeededRevisionLimit": { + "description": "succeededRevisionLimit is the number of successful static pod installer revisions to keep on disk and in the api -1 = unlimited, 0 or unset = 5 (default)", + "type": "integer", + "format": "int32" + }, + "unsupportedConfigOverrides": { + "description": "unsupportedConfigOverrides overrides the final configuration that was computed by the operator. Red Hat does not support the use of this field. Misuse of this field could lead to unexpected behavior or conflict with other configuration options. Seek guidance from the Red Hat support before using this field. Use of this property blocks cluster upgrades, it must be removed before upgrading your cluster.", + "default": {}, + "$ref": "#/definitions/io.k8s.apimachinery.pkg.runtime.RawExtension" + } + } + }, + "com.github.openshift.api.operator.v1.MachineConfigurationStatus": { + "type": "object", + "required": [ + "readyReplicas" + ], + "properties": { + "conditions": { + "description": "conditions is a list of conditions and their status", + "type": "array", + "items": { + "default": {}, + "$ref": "#/definitions/com.github.openshift.api.operator.v1.OperatorCondition" + } + }, + "generations": { + "description": "generations are used to determine when an item needs to be reconciled or has changed in a way that needs a reaction.", + "type": "array", + "items": { + "default": {}, + "$ref": "#/definitions/com.github.openshift.api.operator.v1.GenerationStatus" + } + }, + "latestAvailableRevision": { + "description": "latestAvailableRevision is the deploymentID of the most recent deployment", + "type": "integer", + "format": "int32", + "default": 0 + }, + "latestAvailableRevisionReason": { + "description": "latestAvailableRevisionReason describe the detailed reason for the most recent deployment", + "type": "string", + "default": "" + }, + "nodeStatuses": { + "description": "nodeStatuses track the deployment values and errors across individual nodes", + "type": "array", + "items": { + "default": {}, + "$ref": "#/definitions/com.github.openshift.api.operator.v1.NodeStatus" + } + }, + "observedGeneration": { + "description": "observedGeneration is the last generation change you've dealt with", + "type": "integer", + "format": "int64" + }, + "readyReplicas": { + "description": "readyReplicas indicates how many replicas are ready and at the desired state", + "type": "integer", + "format": "int32", + "default": 0 + }, + "version": { + "description": "version is the level this availability applies to", + "type": "string" + } + } + }, "com.github.openshift.api.operator.v1.MyOperatorResource": { "description": "MyOperatorResource is an example operator configuration type\n\nCompatibility level 4: No compatibility is provided, the API can change at any point for any reason. These capabilities should not be used by applications needing long term support.", "type": "object", @@ -31428,93 +31428,6 @@ } } }, - "com.github.openshift.api.route.v1.RouteHTTPHeader": { - "description": "RouteHTTPHeader specifies configuration for setting or deleting an HTTP header.", - "type": "object", - "required": [ - "name", - "action" - ], - "properties": { - "action": { - "description": "action specifies actions to perform on headers, such as setting or deleting headers.", - "default": {}, - "$ref": "#/definitions/com.github.openshift.api.route.v1.RouteHTTPHeaderActionUnion" - }, - "name": { - "description": "name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header name as defined in RFC 2616 section 4.2. The name must consist only of alphanumeric and the following special characters, \"-!#$%&'*+.^_`\". The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Cookie, Set-Cookie. It must be no more than 1024 characters in length. Header name must be unique.", - "type": "string", - "default": "" - } - } - }, - "com.github.openshift.api.route.v1.RouteHTTPHeaderActionUnion": { - "description": "RouteHTTPHeaderActionUnion specifies an action to take on an HTTP header.", - "type": "object", - "required": [ - "type" - ], - "properties": { - "set": { - "description": "set defines the HTTP header that should be set: added if it doesn't exist or replaced if it does. This field is required when type is Set and forbidden otherwise.", - "$ref": "#/definitions/com.github.openshift.api.route.v1.RouteSetHTTPHeader" - }, - "type": { - "description": "type defines the type of the action to be applied on the header. Possible values are Set or Delete. Set allows you to set HTTP request and response headers. Delete allows you to delete HTTP request and response headers.", - "type": "string", - "default": "" - } - }, - "x-kubernetes-unions": [ - { - "discriminator": "type", - "fields-to-discriminateBy": { - "set": "Set" - } - } - ] - }, - "com.github.openshift.api.route.v1.RouteHTTPHeaderActions": { - "description": "RouteHTTPHeaderActions defines configuration for actions on HTTP request and response headers.", - "type": "object", - "properties": { - "request": { - "description": "request is a list of HTTP request headers to modify. Currently, actions may define to either `Set` or `Delete` headers values. Actions defined here will modify the request headers of all requests made through a route. These actions are applied to a specific Route defined within a cluster i.e. connections made through a route. Currently, actions may define to either `Set` or `Delete` headers values. Route actions will be executed after IngressController actions for request headers. Actions are applied in sequence as defined in this list. A maximum of 20 request header actions may be configured. You can use this field to specify HTTP request headers that should be set or deleted when forwarding connections from the client to your application. Sample fetchers allowed are \"req.hdr\" and \"ssl_c_der\". Converters allowed are \"lower\" and \"base64\". Example header values: \"%[req.hdr(X-target),lower]\", \"%{+Q}[ssl_c_der,base64]\". Any request header configuration applied directly via a Route resource using this API will override header configuration for a header of the same name applied via spec.httpHeaders.actions on the IngressController or route annotation. Note: This field cannot be used if your route uses TLS passthrough.", - "type": "array", - "items": { - "default": {}, - "$ref": "#/definitions/com.github.openshift.api.route.v1.RouteHTTPHeader" - }, - "x-kubernetes-list-map-keys": [ - "name" - ], - "x-kubernetes-list-type": "map" - }, - "response": { - "description": "response is a list of HTTP response headers to modify. Currently, actions may define to either `Set` or `Delete` headers values. Actions defined here will modify the response headers of all requests made through a route. These actions are applied to a specific Route defined within a cluster i.e. connections made through a route. Route actions will be executed before IngressController actions for response headers. Actions are applied in sequence as defined in this list. A maximum of 20 response header actions may be configured. You can use this field to specify HTTP response headers that should be set or deleted when forwarding responses from your application to the client. Sample fetchers allowed are \"res.hdr\" and \"ssl_c_der\". Converters allowed are \"lower\" and \"base64\". Example header values: \"%[res.hdr(X-target),lower]\", \"%{+Q}[ssl_c_der,base64]\". Note: This field cannot be used if your route uses TLS passthrough.", - "type": "array", - "items": { - "default": {}, - "$ref": "#/definitions/com.github.openshift.api.route.v1.RouteHTTPHeader" - }, - "x-kubernetes-list-map-keys": [ - "name" - ], - "x-kubernetes-list-type": "map" - } - } - }, - "com.github.openshift.api.route.v1.RouteHTTPHeaders": { - "description": "RouteHTTPHeaders defines policy for HTTP headers.", - "type": "object", - "properties": { - "actions": { - "description": "actions specifies options for modifying headers and their values. Note that this option only applies to cleartext HTTP connections and to secure HTTP connections for which the ingress controller terminates encryption (that is, edge-terminated or reencrypt connections). Headers cannot be modified for TLS passthrough connections. Setting the HSTS (`Strict-Transport-Security`) header is not supported via actions. `Strict-Transport-Security` may only be configured using the \"haproxy.router.openshift.io/hsts_header\" route annotation, and only in accordance with the policy specified in Ingress.Spec.RequiredHSTSPolicies. In case of HTTP request headers, the actions specified in spec.httpHeaders.actions on the Route will be executed after the actions specified in the IngressController's spec.httpHeaders.actions field. In case of HTTP response headers, the actions specified in spec.httpHeaders.actions on the IngressController will be executed after the actions specified in the Route's spec.httpHeaders.actions field. The headers set via this API will not appear in access logs. Any actions defined here are applied after any actions related to the following other fields: cache-control, spec.clientTLS, spec.httpHeaders.forwardedHeaderPolicy, spec.httpHeaders.uniqueId, and spec.httpHeaders.headerNameCaseAdjustments. The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Cookie, Set-Cookie. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. Please refer to the documentation for that API field for more details.", - "default": {}, - "$ref": "#/definitions/com.github.openshift.api.route.v1.RouteHTTPHeaderActions" - } - } - }, "com.github.openshift.api.route.v1.RouteIngress": { "description": "RouteIngress holds information about the places where a route is exposed.", "type": "object", @@ -31621,20 +31534,6 @@ } } }, - "com.github.openshift.api.route.v1.RouteSetHTTPHeader": { - "description": "RouteSetHTTPHeader specifies what value needs to be set on an HTTP header.", - "type": "object", - "required": [ - "value" - ], - "properties": { - "value": { - "description": "value specifies a header value. Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. The value of this field must be no more than 16384 characters in length. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController.", - "type": "string", - "default": "" - } - } - }, "com.github.openshift.api.route.v1.RouteSpec": { "description": "RouteSpec describes the hostname or path the route exposes, any security information, and one to four backends (services) the route points to. Requests are distributed among the backends depending on the weights assigned to each backend. When using roundrobin scheduling the portion of requests that go to each backend is the backend weight divided by the sum of all of the backend weights. When the backend has more than one endpoint the requests that end up on the backend are roundrobin distributed among the endpoints. Weights are between 0 and 256 with default 100. Weight 0 causes no requests to the backend. If all weights are zero the route will be considered to have no backends and return a standard 503 response.\n\nThe `tls` field is optional and allows specific certificates or behavior for the route. Routers typically configure a default certificate on a wildcard domain to terminate routes without explicit certificates, but custom hostnames usually must choose passthrough (send traffic directly to the backend via the TLS Server-Name- Indication field) or provide a certificate.", "type": "object", @@ -31654,10 +31553,6 @@ "description": "host is an alias/DNS that points to the service. Optional. If not specified a route name will typically be automatically chosen. Must follow DNS952 subdomain conventions.", "type": "string" }, - "httpHeaders": { - "description": "httpHeaders defines policy for HTTP headers.", - "$ref": "#/definitions/com.github.openshift.api.route.v1.RouteHTTPHeaders" - }, "path": { "description": "path that the router watches for, to route traffic for to the service. Optional", "type": "string" @@ -31776,7 +31671,7 @@ "type": "string" }, "termination": { - "description": "termination indicates termination type.\n\n* edge - TLS termination is done by the router and http is used to communicate with the backend (default) * passthrough - Traffic is sent straight to the destination without the router providing TLS termination * reencrypt - TLS termination is done by the router and https is used to communicate with the backend\n\nNote: passthrough termination is incompatible with httpHeader actions", + "description": "termination indicates termination type.\n\n* edge - TLS termination is done by the router and http is used to communicate with the backend (default) * passthrough - Traffic is sent straight to the destination without the router providing TLS termination * reencrypt - TLS termination is done by the router and https is used to communicate with the backend", "type": "string", "default": "" } diff --git a/vendor/github.com/openshift/api/operator/v1/0000_50_ingress-operator_00-ingresscontroller.crd.yaml b/vendor/github.com/openshift/api/operator/v1/0000_50_ingress-operator_00-ingresscontroller.crd.yaml index 7639bed094..c1374c61ff 100644 --- a/vendor/github.com/openshift/api/operator/v1/0000_50_ingress-operator_00-ingresscontroller.crd.yaml +++ b/vendor/github.com/openshift/api/operator/v1/0000_50_ingress-operator_00-ingresscontroller.crd.yaml @@ -3,6 +3,7 @@ kind: CustomResourceDefinition metadata: annotations: api-approved.openshift.io: https://github.com/openshift/api/pull/616 + capability.openshift.io/name: Ingress include.release.openshift.io/ibm-cloud-managed: "true" include.release.openshift.io/self-managed-high-availability: "true" include.release.openshift.io/single-node-developer: "true" @@ -261,130 +262,6 @@ spec: httpHeaders: description: "httpHeaders defines policy for HTTP headers. \n If this field is empty, the default values are used." properties: - actions: - description: 'actions specifies options for modifying headers and their values. Note that this option only applies to cleartext HTTP connections and to secure HTTP connections for which the ingress controller terminates encryption (that is, edge-terminated or reencrypt connections). Headers cannot be modified for TLS passthrough connections. Setting the HSTS (`Strict-Transport-Security`) header is not supported via actions. `Strict-Transport-Security` may only be configured using the "haproxy.router.openshift.io/hsts_header" route annotation, and only in accordance with the policy specified in Ingress.Spec.RequiredHSTSPolicies. Any actions defined here are applied after any actions related to the following other fields: cache-control, spec.clientTLS, spec.httpHeaders.forwardedHeaderPolicy, spec.httpHeaders.uniqueId, and spec.httpHeaders.headerNameCaseAdjustments. In case of HTTP request headers, the actions specified in spec.httpHeaders.actions on the Route will be executed after the actions specified in the IngressController''s spec.httpHeaders.actions field. In case of HTTP response headers, the actions specified in spec.httpHeaders.actions on the IngressController will be executed after the actions specified in the Route''s spec.httpHeaders.actions field. Headers set using this API cannot be captured for use in access logs. The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Host, Cookie, Set-Cookie. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. Please refer to the documentation for that API field for more details.' - properties: - request: - description: 'request is a list of HTTP request headers to modify. Actions defined here will modify the request headers of all requests passing through an ingress controller. These actions are applied to all Routes i.e. for all connections handled by the ingress controller defined within a cluster. IngressController actions for request headers will be executed before Route actions. Currently, actions may define to either `Set` or `Delete` headers values. Actions are applied in sequence as defined in this list. A maximum of 20 request header actions may be configured. Sample fetchers allowed are "req.hdr" and "ssl_c_der". Converters allowed are "lower" and "base64". Example header values: "%[req.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]".' - items: - description: IngressControllerHTTPHeader specifies configuration for setting or deleting an HTTP header. - properties: - action: - description: action specifies actions to perform on headers, such as setting or deleting headers. - properties: - set: - description: set specifies how the HTTP header should be set. This field is required when type is Set and forbidden otherwise. - properties: - value: - description: value specifies a header value. Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. The value of this field must be no more than 16384 characters in length. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. - maxLength: 16384 - minLength: 1 - type: string - required: - - value - type: object - type: - description: type defines the type of the action to be applied on the header. Possible values are Set or Delete. Set allows you to set HTTP request and response headers. Delete allows you to delete HTTP request and response headers. - enum: - - Set - - Delete - type: string - required: - - type - type: object - x-kubernetes-validations: - - message: set is required when type is Set, and forbidden otherwise - rule: 'has(self.type) && self.type == ''Set'' ? has(self.set) : !has(self.set)' - name: - description: 'name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header name as defined in RFC 2616 section 4.2. The name must consist only of alphanumeric and the following special characters, "-!#$%&''*+.^_`". The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Host, Cookie, Set-Cookie. It must be no more than 1024 characters in length. Header name must be unique.' - maxLength: 1024 - minLength: 1 - pattern: ^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$ - type: string - x-kubernetes-validations: - - message: strict-transport-security header may not be modified via header actions - rule: self.lowerAscii() != 'strict-transport-security' - - message: proxy header may not be modified via header actions - rule: self.lowerAscii() != 'proxy' - - message: host header may not be modified via header actions - rule: self.lowerAscii() != 'host' - - message: cookie header may not be modified via header actions - rule: self.lowerAscii() != 'cookie' - - message: set-cookie header may not be modified via header actions - rule: self.lowerAscii() != 'set-cookie' - required: - - action - - name - type: object - maxItems: 20 - type: array - x-kubernetes-list-map-keys: - - name - x-kubernetes-list-type: map - x-kubernetes-validations: - - message: Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64. - rule: self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:req\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$'))) - response: - description: 'response is a list of HTTP response headers to modify. Actions defined here will modify the response headers of all requests passing through an ingress controller. These actions are applied to all Routes i.e. for all connections handled by the ingress controller defined within a cluster. IngressController actions for response headers will be executed after Route actions. Currently, actions may define to either `Set` or `Delete` headers values. Actions are applied in sequence as defined in this list. A maximum of 20 response header actions may be configured. Sample fetchers allowed are "res.hdr" and "ssl_c_der". Converters allowed are "lower" and "base64". Example header values: "%[res.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]".' - items: - description: IngressControllerHTTPHeader specifies configuration for setting or deleting an HTTP header. - properties: - action: - description: action specifies actions to perform on headers, such as setting or deleting headers. - properties: - set: - description: set specifies how the HTTP header should be set. This field is required when type is Set and forbidden otherwise. - properties: - value: - description: value specifies a header value. Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. The value of this field must be no more than 16384 characters in length. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. - maxLength: 16384 - minLength: 1 - type: string - required: - - value - type: object - type: - description: type defines the type of the action to be applied on the header. Possible values are Set or Delete. Set allows you to set HTTP request and response headers. Delete allows you to delete HTTP request and response headers. - enum: - - Set - - Delete - type: string - required: - - type - type: object - x-kubernetes-validations: - - message: set is required when type is Set, and forbidden otherwise - rule: 'has(self.type) && self.type == ''Set'' ? has(self.set) : !has(self.set)' - name: - description: 'name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header name as defined in RFC 2616 section 4.2. The name must consist only of alphanumeric and the following special characters, "-!#$%&''*+.^_`". The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Host, Cookie, Set-Cookie. It must be no more than 1024 characters in length. Header name must be unique.' - maxLength: 1024 - minLength: 1 - pattern: ^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$ - type: string - x-kubernetes-validations: - - message: strict-transport-security header may not be modified via header actions - rule: self.lowerAscii() != 'strict-transport-security' - - message: proxy header may not be modified via header actions - rule: self.lowerAscii() != 'proxy' - - message: host header may not be modified via header actions - rule: self.lowerAscii() != 'host' - - message: cookie header may not be modified via header actions - rule: self.lowerAscii() != 'cookie' - - message: set-cookie header may not be modified via header actions - rule: self.lowerAscii() != 'set-cookie' - required: - - action - - name - type: object - maxItems: 20 - type: array - x-kubernetes-list-map-keys: - - name - x-kubernetes-list-type: map - x-kubernetes-validations: - - message: Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64. - rule: self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:res\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$'))) - type: object forwardedHeaderPolicy: description: "forwardedHeaderPolicy specifies when and how the IngressController sets the Forwarded, X-Forwarded-For, X-Forwarded-Host, X-Forwarded-Port, X-Forwarded-Proto, and X-Forwarded-Proto-Version HTTP headers. The value may be one of the following: \n * \"Append\", which specifies that the IngressController appends the headers, preserving existing headers. \n * \"Replace\", which specifies that the IngressController sets the headers, replacing any existing Forwarded or X-Forwarded-* headers. \n * \"IfNone\", which specifies that the IngressController sets the headers if they are not already set. \n * \"Never\", which specifies that the IngressController never sets the headers, preserving any existing headers. \n By default, the policy is \"Append\"." enum: diff --git a/vendor/github.com/openshift/api/operator/v1/00_console-operator.crd.yaml b/vendor/github.com/openshift/api/operator/v1/0000_70_console-operator.crd.yaml similarity index 100% rename from vendor/github.com/openshift/api/operator/v1/00_console-operator.crd.yaml rename to vendor/github.com/openshift/api/operator/v1/0000_70_console-operator.crd.yaml diff --git a/vendor/github.com/openshift/api/operator/v1/0000_80_machine-config-operator_01_config.crd.yaml b/vendor/github.com/openshift/api/operator/v1/0000_80_machine-config-operator_01_config.crd.yaml new file mode 100644 index 0000000000..76b8002731 --- /dev/null +++ b/vendor/github.com/openshift/api/operator/v1/0000_80_machine-config-operator_01_config.crd.yaml @@ -0,0 +1,192 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + annotations: + api-approved.openshift.io: https://github.com/openshift/api/pull/TODO(jkyros) + include.release.openshift.io/ibm-cloud-managed: "true" + include.release.openshift.io/self-managed-high-availability: "true" + include.release.openshift.io/single-node-developer: "true" + name: machineconfigurations.operator.openshift.io +spec: + group: operator.openshift.io + names: + kind: MachineConfiguration + plural: machineconfigurations + singular: machineconfiguration + scope: Cluster + versions: + - name: v1 + schema: + openAPIV3Schema: + description: "MachineConfiguration provides information to configure an operator to manage Machine Configuration. \n Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer)." + type: object + required: + - spec + properties: + apiVersion: + description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + type: string + kind: + description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + type: string + metadata: + type: object + spec: + description: spec is the specification of the desired behavior of the Machine Config Operator + type: object + properties: + failedRevisionLimit: + description: failedRevisionLimit is the number of failed static pod installer revisions to keep on disk and in the api -1 = unlimited, 0 or unset = 5 (default) + type: integer + format: int32 + forceRedeploymentReason: + description: forceRedeploymentReason can be used to force the redeployment of the operand by providing a unique string. This provides a mechanism to kick a previously failed deployment and provide a reason why you think it will work this time instead of failing again on the same config. + type: string + logLevel: + description: "logLevel is an intent based logging for an overall component. It does not give fine grained control, but it is a simple way to manage coarse grained logging choices that operators have to interpret for their operands. \n Valid values are: \"Normal\", \"Debug\", \"Trace\", \"TraceAll\". Defaults to \"Normal\"." + type: string + default: Normal + enum: + - "" + - Normal + - Debug + - Trace + - TraceAll + managementState: + description: managementState indicates whether and how the operator should manage the component + type: string + pattern: ^(Managed|Unmanaged|Force|Removed)$ + observedConfig: + description: observedConfig holds a sparse config that controller has observed from the cluster state. It exists in spec because it is an input to the level for the operator + type: object + nullable: true + x-kubernetes-preserve-unknown-fields: true + operatorLogLevel: + description: "operatorLogLevel is an intent based logging for the operator itself. It does not give fine grained control, but it is a simple way to manage coarse grained logging choices that operators have to interpret for themselves. \n Valid values are: \"Normal\", \"Debug\", \"Trace\", \"TraceAll\". Defaults to \"Normal\"." + type: string + default: Normal + enum: + - "" + - Normal + - Debug + - Trace + - TraceAll + succeededRevisionLimit: + description: succeededRevisionLimit is the number of successful static pod installer revisions to keep on disk and in the api -1 = unlimited, 0 or unset = 5 (default) + type: integer + format: int32 + unsupportedConfigOverrides: + description: unsupportedConfigOverrides overrides the final configuration that was computed by the operator. Red Hat does not support the use of this field. Misuse of this field could lead to unexpected behavior or conflict with other configuration options. Seek guidance from the Red Hat support before using this field. Use of this property blocks cluster upgrades, it must be removed before upgrading your cluster. + type: object + nullable: true + x-kubernetes-preserve-unknown-fields: true + status: + description: status is the most recently observed status of the Machine Config Operator + type: object + properties: + conditions: + description: conditions is a list of conditions and their status + type: array + items: + description: OperatorCondition is just the standard condition fields. + type: object + properties: + lastTransitionTime: + type: string + format: date-time + message: + type: string + reason: + type: string + status: + type: string + type: + type: string + generations: + description: generations are used to determine when an item needs to be reconciled or has changed in a way that needs a reaction. + type: array + items: + description: GenerationStatus keeps track of the generation for a given resource so that decisions about forced updates can be made. + type: object + properties: + group: + description: group is the group of the thing you're tracking + type: string + hash: + description: hash is an optional field set for resources without generation that are content sensitive like secrets and configmaps + type: string + lastGeneration: + description: lastGeneration is the last generation of the workload controller involved + type: integer + format: int64 + name: + description: name is the name of the thing you're tracking + type: string + namespace: + description: namespace is where the thing you're tracking is + type: string + resource: + description: resource is the resource type of the thing you're tracking + type: string + latestAvailableRevision: + description: latestAvailableRevision is the deploymentID of the most recent deployment + type: integer + format: int32 + latestAvailableRevisionReason: + description: latestAvailableRevisionReason describe the detailed reason for the most recent deployment + type: string + nodeStatuses: + description: nodeStatuses track the deployment values and errors across individual nodes + type: array + items: + description: NodeStatus provides information about the current state of a particular node managed by this operator. + type: object + properties: + currentRevision: + description: currentRevision is the generation of the most recently successful deployment + type: integer + format: int32 + lastFailedCount: + description: lastFailedCount is how often the installer pod of the last failed revision failed. + type: integer + lastFailedReason: + description: lastFailedReason is a machine readable failure reason string. + type: string + lastFailedRevision: + description: lastFailedRevision is the generation of the deployment we tried and failed to deploy. + type: integer + format: int32 + lastFailedRevisionErrors: + description: lastFailedRevisionErrors is a list of human readable errors during the failed deployment referenced in lastFailedRevision. + type: array + items: + type: string + lastFailedTime: + description: lastFailedTime is the time the last failed revision failed the last time. + type: string + format: date-time + lastFallbackCount: + description: lastFallbackCount is how often a fallback to a previous revision happened. + type: integer + nodeName: + description: nodeName is the name of the node + type: string + targetRevision: + description: targetRevision is the generation of the deployment we're trying to apply + type: integer + format: int32 + observedGeneration: + description: observedGeneration is the last generation change you've dealt with + type: integer + format: int64 + readyReplicas: + description: readyReplicas indicates how many replicas are ready and at the desired state + type: integer + format: int32 + version: + description: version is the level this availability applies to + type: string + served: true + storage: true + subresources: + status: {} diff --git a/vendor/github.com/openshift/api/operator/v1/register.go b/vendor/github.com/openshift/api/operator/v1/register.go index bd3dc420b8..21919f9a8b 100644 --- a/vendor/github.com/openshift/api/operator/v1/register.go +++ b/vendor/github.com/openshift/api/operator/v1/register.go @@ -54,6 +54,8 @@ func addKnownTypes(scheme *runtime.Scheme) error { &KubeSchedulerList{}, &KubeStorageVersionMigrator{}, &KubeStorageVersionMigratorList{}, + &MachineConfiguration{}, + &MachineConfigurationList{}, &Network{}, &NetworkList{}, &OpenShiftAPIServer{}, diff --git a/vendor/github.com/openshift/api/operator/v1/stable.console.testsuite.yaml b/vendor/github.com/openshift/api/operator/v1/stable.console.testsuite.yaml index 065d490e45..158c96ad4b 100644 --- a/vendor/github.com/openshift/api/operator/v1/stable.console.testsuite.yaml +++ b/vendor/github.com/openshift/api/operator/v1/stable.console.testsuite.yaml @@ -1,6 +1,6 @@ apiVersion: apiextensions.k8s.io/v1 # Hack because controller-gen complains if we don't have this name: "[Stable] Console" -crd: 00_console-operator.crd.yaml +crd: 0000_70_console-operator.crd.yaml tests: onCreate: - name: Should be able to create a minimal Console diff --git a/vendor/github.com/openshift/api/operator/v1/stable.ingresscontroller.testsuite.yaml b/vendor/github.com/openshift/api/operator/v1/stable.ingresscontroller.testsuite.yaml index 903d8e60c5..01d02ce096 100644 --- a/vendor/github.com/openshift/api/operator/v1/stable.ingresscontroller.testsuite.yaml +++ b/vendor/github.com/openshift/api/operator/v1/stable.ingresscontroller.testsuite.yaml @@ -13,466 +13,3 @@ tests: kind: IngressController spec: httpEmptyRequestsPolicy: Respond - - name: Should be able to create an IngressController with valid Actions - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - spec: - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - set: - value: DENY - - name: X-Cache-Info - action: - type: Set - set: - value: "not cacheable; meta data too large" - - name: X-XSS-Protection - action: - type: Delete - - name: X-Source - action: - type: Set - set: - value: "%[res.hdr(X-Value),lower]" - request: - - name: Content-Location - action: - type: Set - set: - value: /my-first-blog-post - - name: X-SSL-Client-Cert - action: - type: Set - set: - value: "%{+Q}[ssl_c_der,base64]" - - name: Content-Language - action: - type: Delete - - name: X-Target - action: - type: Set - set: - value: "%[req.hdr(host),lower]" - - name: X-Conditional - action: - type: Set - set: - value: "%[req.hdr(Host)] if foo" - - name: X-Condition - action: - type: Set - set: - value: "%[req.hdr(Host)]\ if\ foo" - expected: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - spec: - httpEmptyRequestsPolicy: Respond - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - set: - value: DENY - - name: X-Cache-Info - action: - type: Set - set: - value: "not cacheable; meta data too large" - - name: X-XSS-Protection - action: - type: Delete - - name: X-Source - action: - type: Set - set: - value: "%[res.hdr(X-Value),lower]" - request: - - name: Content-Location - action: - type: Set - set: - value: /my-first-blog-post - - name: X-SSL-Client-Cert - action: - type: Set - set: - value: "%{+Q}[ssl_c_der,base64]" - - name: Content-Language - action: - type: Delete - - name: X-Target - action: - type: Set - set: - value: "%[req.hdr(host),lower]" - - name: X-Conditional - action: - type: Set - set: - value: "%[req.hdr(Host)] if foo" - - name: X-Condition - action: - type: Set - set: - value: "%[req.hdr(Host)]\ if\ foo" - - name: Should not allow to set/delete HSTS header. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-hsts - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - set: - value: DENY - - name: Strict-Transport-Security - action: - type: Delete - request: - - name: Content-Location - action: - type: Set - set: - value: /my-first-blog-post - - name: Content-Language - action: - type: Delete - expectedError: "strict-transport-security header may not be modified via header actions" - - name: Should not allow to set/delete Proxy header. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-hsts - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - set: - value: DENY - request: - - name: Proxy - action: - type: Set - set: - value: example.xyz - - name: Content-Location - action: - type: Set - set: - value: /my-first-blog-post - - name: Content-Language - action: - type: Delete - expectedError: "proxy header may not be modified via header actions" - - name: Should not allow to set/delete Host header. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-hsts - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - set: - value: DENY - request: - - name: Host - action: - type: Set - set: - value: example.xyz - - name: Content-Location - action: - type: Set - set: - value: /my-first-blog-post - - name: Content-Language - action: - type: Delete - expectedError: "host header may not be modified via header actions" - - name: Should not allow to set/delete cookie header. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-hsts - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - set: - value: DENY - request: - - name: Cookie - action: - type: Set - set: - value: "PHPSESSID=298zf09hf012fh2; csrftoken=u32t4o3tb3gg43; _gat=1" - - name: Content-Location - action: - type: Set - set: - value: /my-first-blog-post - - name: Content-Language - action: - type: Delete - expectedError: "cookie header may not be modified via header actions" - - name: Should not allow to set/delete set-cookie header. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-hsts - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - response: - - name: Set-Cookie - action: - type: Set - set: - value: "sessionId=e8bb43229de9; Domain=foo.example.com" - request: - - name: Content-Location - action: - type: Set - set: - value: /my-first-blog-post - - name: Content-Language - action: - type: Delete - expectedError: "set-cookie header may not be modified via header actions" - - name: Should not allow to set/delete dynamic headers with unclosed braces. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-unclosed-braces - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - request: - - name: Content-Location - action: - type: Set - set: - value: /my-first-blog-post - - name: Content-Language - action: - type: Delete - - name: expires - action: - type: Set - set: - value: "%[req.hdr(host),lower" - expectedError: "Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64." - - name: Should not allow to set dynamic response header values with not allowed sample fetchers. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-not-allowed-values - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - set: - value: DENY - - name: X-Target - action: - type: Set - set: - value: "%[req.hdrs(host),lower]" - expectedError: "Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64." - - name: Should not allow empty value in response. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-not-allowed-values - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - set: - value: - expectedError: 'IngressController.operator.openshift.io "default-not-allowed-values" is invalid: [spec.httpHeaders.actions.response[0].action.set.value: Required value, : Invalid value: "null": some validation rules were not checked because the object was invalid; correct the existing errors to complete validation]' - - name: Should not allow empty value in request. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-not-allowed-values - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - request: - - name: X-Frame-Options - action: - type: Set - set: - value: - expectedError: 'IngressController.operator.openshift.io "default-not-allowed-values" is invalid: [spec.httpHeaders.actions.request[0].action.set.value: Required value, : Invalid value: "null": some validation rules were not checked because the object was invalid; correct the existing errors to complete validation]' - - name: Should not allow to set dynamic response header values with not allowed converters. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-not-allowed-values - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - set: - value: DENY - - name: X-Source - action: - type: Set - set: - value: "%{+Q}[ssl_c_der,bogus]" - expectedError: "Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64." - - name: Should not allow to set dynamic request header values containing sample fetcher res.hdr. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-not-allowed-values - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - request: - - name: X-Target - action: - type: Set - set: - value: "%[res.hdr(X-Value),lower]" - expectedError: "Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64." - - name: Should not allow to set dynamic response headers value containing sample fetcher req.hdr. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-not-allowed-values - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - response: - - name: X-Source - action: - type: Set - set: - value: "%[req.hdr(host),lower]" - expectedError: "Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64." - - name: Should not allow to set dynamic request header values with not allowed converters. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-not-allowed-values - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - request: - - name: X-SSL-Client-Cert - action: - type: Set - set: - value: "%{+Q}[ssl_c_der,hello]" - - name: Content-Language - action: - type: Delete - expectedError: "Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64." - - name: Should not allow to set dynamic request header values with not allowed sample fetchers. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-not-allowed-values - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - request: - - name: X-SSL-Client-Cert - action: - type: Set - set: - value: "%{+Q}[ssl_c_der1234,base64]" - - name: Content-Language - action: - type: Delete - expectedError: "Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64." - - name: Should be required to specify the set field when the discriminant type is Set. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - spec: - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - expectedError: "set is required when type is Set, and forbidden otherwise" - - name: Should be able to add set field only when discriminant type is Set. - initial: | - apiVersion: operator.openshift.io/v1 - kind: IngressController - metadata: - name: default-not-allowed-values - namespace: openshift-ingress-operator - spec: - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - set: - value: DENY - expectedError: 'IngressController.operator.openshift.io "default-not-allowed-values" is invalid: [spec.httpHeaders.actions.response[0].action.type: Required value, : Invalid value: "null": some validation rules were not checked because the object was invalid; correct the existing errors to complete validation]' diff --git a/vendor/github.com/openshift/api/operator/v1/stable.machineconfiguration.testsuite.yaml b/vendor/github.com/openshift/api/operator/v1/stable.machineconfiguration.testsuite.yaml new file mode 100644 index 0000000000..6992a8eaa9 --- /dev/null +++ b/vendor/github.com/openshift/api/operator/v1/stable.machineconfiguration.testsuite.yaml @@ -0,0 +1,16 @@ +apiVersion: apiextensions.k8s.io/v1 # Hack because controller-gen complains if we don't have this +name: "[Stable] MachineConfiguration" +crd: 0000_80_machine-config-operator_01_config.crd.yaml +tests: + onCreate: + - name: Should be able to create a minimal MachineConfiguration + initial: | + apiVersion: operator.openshift.io/v1 + kind: MachineConfiguration + spec: {} # No spec is required for a MachineConfiguration + expected: | + apiVersion: operator.openshift.io/v1 + kind: MachineConfiguration + spec: + logLevel: Normal + operatorLogLevel: Normal diff --git a/vendor/github.com/openshift/api/operator/v1/types_ingress.go b/vendor/github.com/openshift/api/operator/v1/types_ingress.go index 120695d14b..13d020420c 100644 --- a/vendor/github.com/openshift/api/operator/v1/types_ingress.go +++ b/vendor/github.com/openshift/api/operator/v1/types_ingress.go @@ -1399,144 +1399,6 @@ type IngressControllerHTTPHeaders struct { // +nullable // +optional HeaderNameCaseAdjustments []IngressControllerHTTPHeaderNameCaseAdjustment `json:"headerNameCaseAdjustments,omitempty"` - - // actions specifies options for modifying headers and their values. - // Note that this option only applies to cleartext HTTP connections - // and to secure HTTP connections for which the ingress controller - // terminates encryption (that is, edge-terminated or reencrypt - // connections). Headers cannot be modified for TLS passthrough - // connections. - // Setting the HSTS (`Strict-Transport-Security`) header is not supported via actions. `Strict-Transport-Security` - // may only be configured using the "haproxy.router.openshift.io/hsts_header" route annotation, and only in - // accordance with the policy specified in Ingress.Spec.RequiredHSTSPolicies. - // Any actions defined here are applied after any actions related to the following other fields: - // cache-control, spec.clientTLS, - // spec.httpHeaders.forwardedHeaderPolicy, spec.httpHeaders.uniqueId, - // and spec.httpHeaders.headerNameCaseAdjustments. - // In case of HTTP request headers, the actions specified in spec.httpHeaders.actions on the Route will be executed after - // the actions specified in the IngressController's spec.httpHeaders.actions field. - // In case of HTTP response headers, the actions specified in spec.httpHeaders.actions on the IngressController will be - // executed after the actions specified in the Route's spec.httpHeaders.actions field. - // Headers set using this API cannot be captured for use in access logs. - // The following header names are reserved and may not be modified via this API: - // Strict-Transport-Security, Proxy, Host, Cookie, Set-Cookie. - // Note that the total size of all net added headers *after* interpolating dynamic values - // must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the - // IngressController. Please refer to the documentation - // for that API field for more details. - // +optional - Actions IngressControllerHTTPHeaderActions `json:"actions,omitempty"` -} - -// IngressControllerHTTPHeaderActions defines configuration for actions on HTTP request and response headers. -type IngressControllerHTTPHeaderActions struct { - // response is a list of HTTP response headers to modify. - // Actions defined here will modify the response headers of all requests passing through an ingress controller. - // These actions are applied to all Routes i.e. for all connections handled by the ingress controller defined within a cluster. - // IngressController actions for response headers will be executed after Route actions. - // Currently, actions may define to either `Set` or `Delete` headers values. - // Actions are applied in sequence as defined in this list. - // A maximum of 20 response header actions may be configured. - // Sample fetchers allowed are "res.hdr" and "ssl_c_der". - // Converters allowed are "lower" and "base64". - // Example header values: "%[res.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]". - // +listType=map - // +listMapKey=name - // +optional - // +kubebuilder:validation:MaxItems=20 - // +kubebuilder:validation:XValidation:rule=`self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:res\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$')))`,message="Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64." - Response []IngressControllerHTTPHeader `json:"response"` - // request is a list of HTTP request headers to modify. - // Actions defined here will modify the request headers of all requests passing through an ingress controller. - // These actions are applied to all Routes i.e. for all connections handled by the ingress controller defined within a cluster. - // IngressController actions for request headers will be executed before Route actions. - // Currently, actions may define to either `Set` or `Delete` headers values. - // Actions are applied in sequence as defined in this list. - // A maximum of 20 request header actions may be configured. - // Sample fetchers allowed are "req.hdr" and "ssl_c_der". - // Converters allowed are "lower" and "base64". - // Example header values: "%[req.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]". - // + --- - // + Note: Any change to regex mentioned below must be reflected in the CRD validation of route in https://github.com/openshift/library-go/blob/master/pkg/route/validation/validation.go and vice-versa. - // +listType=map - // +listMapKey=name - // +optional - // +kubebuilder:validation:MaxItems=20 - // +kubebuilder:validation:XValidation:rule=`self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:req\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$')))`,message="Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64." - Request []IngressControllerHTTPHeader `json:"request"` -} - -// IngressControllerHTTPHeader specifies configuration for setting or deleting an HTTP header. -type IngressControllerHTTPHeader struct { - // name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header - // name as defined in RFC 2616 section 4.2. - // The name must consist only of alphanumeric and the following special characters, "-!#$%&'*+.^_`". - // The following header names are reserved and may not be modified via this API: - // Strict-Transport-Security, Proxy, Host, Cookie, Set-Cookie. - // It must be no more than 1024 characters in length. - // Header name must be unique. - // +kubebuilder:validation:Required - // +kubebuilder:validation:MinLength=1 - // +kubebuilder:validation:MaxLength=1024 - // +kubebuilder:validation:Pattern="^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$" - // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'strict-transport-security'",message="strict-transport-security header may not be modified via header actions" - // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'proxy'",message="proxy header may not be modified via header actions" - // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'host'",message="host header may not be modified via header actions" - // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'cookie'",message="cookie header may not be modified via header actions" - // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'set-cookie'",message="set-cookie header may not be modified via header actions" - Name string `json:"name"` - // action specifies actions to perform on headers, such as setting or deleting headers. - // +kubebuilder:validation:Required - Action IngressControllerHTTPHeaderActionUnion `json:"action"` -} - -// IngressControllerHTTPHeaderActionUnion specifies an action to take on an HTTP header. -// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'Set' ? has(self.set) : !has(self.set)",message="set is required when type is Set, and forbidden otherwise" -// +union -type IngressControllerHTTPHeaderActionUnion struct { - // type defines the type of the action to be applied on the header. - // Possible values are Set or Delete. - // Set allows you to set HTTP request and response headers. - // Delete allows you to delete HTTP request and response headers. - // +unionDiscriminator - // +kubebuilder:validation:Enum:=Set;Delete - // +kubebuilder:validation:Required - Type IngressControllerHTTPHeaderActionType `json:"type"` - - // set specifies how the HTTP header should be set. - // This field is required when type is Set and forbidden otherwise. - // +optional - // +unionMember - Set *IngressControllerSetHTTPHeader `json:"set,omitempty"` -} - -// IngressControllerHTTPHeaderActionType defines actions that can be performed on HTTP headers. -type IngressControllerHTTPHeaderActionType string - -const ( - // Set specifies that an HTTP header should be set. - Set IngressControllerHTTPHeaderActionType = "Set" - // Delete specifies that an HTTP header should be deleted. - Delete IngressControllerHTTPHeaderActionType = "Delete" -) - -// IngressControllerSetHTTPHeader defines the value which needs to be set on an HTTP header. -type IngressControllerSetHTTPHeader struct { - // value specifies a header value. - // Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in - // http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and - // otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. - // The value of this field must be no more than 16384 characters in length. - // Note that the total size of all net added headers *after* interpolating dynamic values - // must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the - // IngressController. - // + --- - // + Note: This limit was selected as most common web servers have a limit of 16384 characters or some lower limit. - // + See . - // +kubebuilder:validation:Required - // +kubebuilder:validation:MinLength=1 - // +kubebuilder:validation:MaxLength=16384 - Value string `json:"value"` } // IngressControllerTuningOptions specifies options for tuning the performance diff --git a/vendor/github.com/openshift/api/operator/v1/types_machineconfiguration.go b/vendor/github.com/openshift/api/operator/v1/types_machineconfiguration.go new file mode 100644 index 0000000000..054e5716bc --- /dev/null +++ b/vendor/github.com/openshift/api/operator/v1/types_machineconfiguration.go @@ -0,0 +1,59 @@ +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// +genclient +// +genclient:nonNamespaced +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// MachineConfiguration provides information to configure an operator to manage Machine Configuration. +// +// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer). +// +openshift:compatibility-gen:level=1 +type MachineConfiguration struct { + metav1.TypeMeta `json:",inline"` + + // metadata is the standard object's metadata. + // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + metav1.ObjectMeta `json:"metadata"` + + // spec is the specification of the desired behavior of the Machine Config Operator + // +kubebuilder:validation:Required + // +required + Spec MachineConfigurationSpec `json:"spec"` + + // status is the most recently observed status of the Machine Config Operator + // +optional + Status MachineConfigurationStatus `json:"status"` +} + +type MachineConfigurationSpec struct { + StaticPodOperatorSpec `json:",inline"` + + // TODO(jkyros): This is where we put our knobs and dials +} + +type MachineConfigurationStatus struct { + StaticPodOperatorStatus `json:",inline"` + + // TODO(jkyros): This is where we can put additional bespoke status fields +} + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// MachineConfigurationList is a collection of items +// +// Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer). +// +openshift:compatibility-gen:level=1 +type MachineConfigurationList struct { + metav1.TypeMeta `json:",inline"` + + // metadata is the standard list's metadata. + // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + metav1.ListMeta `json:"metadata"` + + // Items contains the items + Items []MachineConfiguration `json:"items"` +} diff --git a/vendor/github.com/openshift/api/operator/v1/zz_generated.deepcopy.go b/vendor/github.com/openshift/api/operator/v1/zz_generated.deepcopy.go index 3f47cd4416..64bbb18e96 100644 --- a/vendor/github.com/openshift/api/operator/v1/zz_generated.deepcopy.go +++ b/vendor/github.com/openshift/api/operator/v1/zz_generated.deepcopy.go @@ -1867,74 +1867,6 @@ func (in *IngressControllerCaptureHTTPHeaders) DeepCopy() *IngressControllerCapt return out } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *IngressControllerHTTPHeader) DeepCopyInto(out *IngressControllerHTTPHeader) { - *out = *in - in.Action.DeepCopyInto(&out.Action) - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IngressControllerHTTPHeader. -func (in *IngressControllerHTTPHeader) DeepCopy() *IngressControllerHTTPHeader { - if in == nil { - return nil - } - out := new(IngressControllerHTTPHeader) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *IngressControllerHTTPHeaderActionUnion) DeepCopyInto(out *IngressControllerHTTPHeaderActionUnion) { - *out = *in - if in.Set != nil { - in, out := &in.Set, &out.Set - *out = new(IngressControllerSetHTTPHeader) - **out = **in - } - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IngressControllerHTTPHeaderActionUnion. -func (in *IngressControllerHTTPHeaderActionUnion) DeepCopy() *IngressControllerHTTPHeaderActionUnion { - if in == nil { - return nil - } - out := new(IngressControllerHTTPHeaderActionUnion) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *IngressControllerHTTPHeaderActions) DeepCopyInto(out *IngressControllerHTTPHeaderActions) { - *out = *in - if in.Response != nil { - in, out := &in.Response, &out.Response - *out = make([]IngressControllerHTTPHeader, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } - if in.Request != nil { - in, out := &in.Request, &out.Request - *out = make([]IngressControllerHTTPHeader, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IngressControllerHTTPHeaderActions. -func (in *IngressControllerHTTPHeaderActions) DeepCopy() *IngressControllerHTTPHeaderActions { - if in == nil { - return nil - } - out := new(IngressControllerHTTPHeaderActions) - in.DeepCopyInto(out) - return out -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *IngressControllerHTTPHeaders) DeepCopyInto(out *IngressControllerHTTPHeaders) { *out = *in @@ -1944,7 +1876,6 @@ func (in *IngressControllerHTTPHeaders) DeepCopyInto(out *IngressControllerHTTPH *out = make([]IngressControllerHTTPHeaderNameCaseAdjustment, len(*in)) copy(*out, *in) } - in.Actions.DeepCopyInto(&out.Actions) return } @@ -2028,22 +1959,6 @@ func (in *IngressControllerLogging) DeepCopy() *IngressControllerLogging { return out } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *IngressControllerSetHTTPHeader) DeepCopyInto(out *IngressControllerSetHTTPHeader) { - *out = *in - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IngressControllerSetHTTPHeader. -func (in *IngressControllerSetHTTPHeader) DeepCopy() *IngressControllerSetHTTPHeader { - if in == nil { - return nil - } - out := new(IngressControllerSetHTTPHeader) - in.DeepCopyInto(out) - return out -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *IngressControllerSpec) DeepCopyInto(out *IngressControllerSpec) { *out = *in @@ -2856,6 +2771,101 @@ func (in *MTUMigrationValues) DeepCopy() *MTUMigrationValues { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MachineConfiguration) DeepCopyInto(out *MachineConfiguration) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MachineConfiguration. +func (in *MachineConfiguration) DeepCopy() *MachineConfiguration { + if in == nil { + return nil + } + out := new(MachineConfiguration) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *MachineConfiguration) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MachineConfigurationList) DeepCopyInto(out *MachineConfigurationList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]MachineConfiguration, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MachineConfigurationList. +func (in *MachineConfigurationList) DeepCopy() *MachineConfigurationList { + if in == nil { + return nil + } + out := new(MachineConfigurationList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *MachineConfigurationList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MachineConfigurationSpec) DeepCopyInto(out *MachineConfigurationSpec) { + *out = *in + in.StaticPodOperatorSpec.DeepCopyInto(&out.StaticPodOperatorSpec) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MachineConfigurationSpec. +func (in *MachineConfigurationSpec) DeepCopy() *MachineConfigurationSpec { + if in == nil { + return nil + } + out := new(MachineConfigurationSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MachineConfigurationStatus) DeepCopyInto(out *MachineConfigurationStatus) { + *out = *in + in.StaticPodOperatorStatus.DeepCopyInto(&out.StaticPodOperatorStatus) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MachineConfigurationStatus. +func (in *MachineConfigurationStatus) DeepCopy() *MachineConfigurationStatus { + if in == nil { + return nil + } + out := new(MachineConfigurationStatus) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *MyOperatorResource) DeepCopyInto(out *MyOperatorResource) { *out = *in diff --git a/vendor/github.com/openshift/api/operator/v1/zz_generated.swagger_doc_generated.go b/vendor/github.com/openshift/api/operator/v1/zz_generated.swagger_doc_generated.go index f3ebb503ea..b0bcb711cb 100644 --- a/vendor/github.com/openshift/api/operator/v1/zz_generated.swagger_doc_generated.go +++ b/vendor/github.com/openshift/api/operator/v1/zz_generated.swagger_doc_generated.go @@ -850,42 +850,11 @@ func (IngressControllerCaptureHTTPHeaders) SwaggerDoc() map[string]string { return map_IngressControllerCaptureHTTPHeaders } -var map_IngressControllerHTTPHeader = map[string]string{ - "": "IngressControllerHTTPHeader specifies configuration for setting or deleting an HTTP header.", - "name": "name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header name as defined in RFC 2616 section 4.2. The name must consist only of alphanumeric and the following special characters, \"-!#$%&'*+.^_`\". The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Host, Cookie, Set-Cookie. It must be no more than 1024 characters in length. Header name must be unique.", - "action": "action specifies actions to perform on headers, such as setting or deleting headers.", -} - -func (IngressControllerHTTPHeader) SwaggerDoc() map[string]string { - return map_IngressControllerHTTPHeader -} - -var map_IngressControllerHTTPHeaderActionUnion = map[string]string{ - "": "IngressControllerHTTPHeaderActionUnion specifies an action to take on an HTTP header.", - "type": "type defines the type of the action to be applied on the header. Possible values are Set or Delete. Set allows you to set HTTP request and response headers. Delete allows you to delete HTTP request and response headers.", - "set": "set specifies how the HTTP header should be set. This field is required when type is Set and forbidden otherwise.", -} - -func (IngressControllerHTTPHeaderActionUnion) SwaggerDoc() map[string]string { - return map_IngressControllerHTTPHeaderActionUnion -} - -var map_IngressControllerHTTPHeaderActions = map[string]string{ - "": "IngressControllerHTTPHeaderActions defines configuration for actions on HTTP request and response headers.", - "response": "response is a list of HTTP response headers to modify. Actions defined here will modify the response headers of all requests passing through an ingress controller. These actions are applied to all Routes i.e. for all connections handled by the ingress controller defined within a cluster. IngressController actions for response headers will be executed after Route actions. Currently, actions may define to either `Set` or `Delete` headers values. Actions are applied in sequence as defined in this list. A maximum of 20 response header actions may be configured. Sample fetchers allowed are \"res.hdr\" and \"ssl_c_der\". Converters allowed are \"lower\" and \"base64\". Example header values: \"%[res.hdr(X-target),lower]\", \"%{+Q}[ssl_c_der,base64]\".", - "request": "request is a list of HTTP request headers to modify. Actions defined here will modify the request headers of all requests passing through an ingress controller. These actions are applied to all Routes i.e. for all connections handled by the ingress controller defined within a cluster. IngressController actions for request headers will be executed before Route actions. Currently, actions may define to either `Set` or `Delete` headers values. Actions are applied in sequence as defined in this list. A maximum of 20 request header actions may be configured. Sample fetchers allowed are \"req.hdr\" and \"ssl_c_der\". Converters allowed are \"lower\" and \"base64\". Example header values: \"%[req.hdr(X-target),lower]\", \"%{+Q}[ssl_c_der,base64]\". ", -} - -func (IngressControllerHTTPHeaderActions) SwaggerDoc() map[string]string { - return map_IngressControllerHTTPHeaderActions -} - var map_IngressControllerHTTPHeaders = map[string]string{ "": "IngressControllerHTTPHeaders specifies how the IngressController handles certain HTTP headers.", "forwardedHeaderPolicy": "forwardedHeaderPolicy specifies when and how the IngressController sets the Forwarded, X-Forwarded-For, X-Forwarded-Host, X-Forwarded-Port, X-Forwarded-Proto, and X-Forwarded-Proto-Version HTTP headers. The value may be one of the following:\n\n* \"Append\", which specifies that the IngressController appends the\n headers, preserving existing headers.\n\n* \"Replace\", which specifies that the IngressController sets the\n headers, replacing any existing Forwarded or X-Forwarded-* headers.\n\n* \"IfNone\", which specifies that the IngressController sets the\n headers if they are not already set.\n\n* \"Never\", which specifies that the IngressController never sets the\n headers, preserving any existing headers.\n\nBy default, the policy is \"Append\".", "uniqueId": "uniqueId describes configuration for a custom HTTP header that the ingress controller should inject into incoming HTTP requests. Typically, this header is configured to have a value that is unique to the HTTP request. The header can be used by applications or included in access logs to facilitate tracing individual HTTP requests.\n\nIf this field is empty, no such header is injected into requests.", "headerNameCaseAdjustments": "headerNameCaseAdjustments specifies case adjustments that can be applied to HTTP header names. Each adjustment is specified as an HTTP header name with the desired capitalization. For example, specifying \"X-Forwarded-For\" indicates that the \"x-forwarded-for\" HTTP header should be adjusted to have the specified capitalization.\n\nThese adjustments are only applied to cleartext, edge-terminated, and re-encrypt routes, and only when using HTTP/1.\n\nFor request headers, these adjustments are applied only for routes that have the haproxy.router.openshift.io/h1-adjust-case=true annotation. For response headers, these adjustments are applied to all HTTP responses.\n\nIf this field is empty, no request headers are adjusted.", - "actions": "actions specifies options for modifying headers and their values. Note that this option only applies to cleartext HTTP connections and to secure HTTP connections for which the ingress controller terminates encryption (that is, edge-terminated or reencrypt connections). Headers cannot be modified for TLS passthrough connections. Setting the HSTS (`Strict-Transport-Security`) header is not supported via actions. `Strict-Transport-Security` may only be configured using the \"haproxy.router.openshift.io/hsts_header\" route annotation, and only in accordance with the policy specified in Ingress.Spec.RequiredHSTSPolicies. Any actions defined here are applied after any actions related to the following other fields: cache-control, spec.clientTLS, spec.httpHeaders.forwardedHeaderPolicy, spec.httpHeaders.uniqueId, and spec.httpHeaders.headerNameCaseAdjustments. In case of HTTP request headers, the actions specified in spec.httpHeaders.actions on the Route will be executed after the actions specified in the IngressController's spec.httpHeaders.actions field. In case of HTTP response headers, the actions specified in spec.httpHeaders.actions on the IngressController will be executed after the actions specified in the Route's spec.httpHeaders.actions field. Headers set using this API cannot be captured for use in access logs. The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Host, Cookie, Set-Cookie. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. Please refer to the documentation for that API field for more details.", } func (IngressControllerHTTPHeaders) SwaggerDoc() map[string]string { @@ -920,15 +889,6 @@ func (IngressControllerLogging) SwaggerDoc() map[string]string { return map_IngressControllerLogging } -var map_IngressControllerSetHTTPHeader = map[string]string{ - "": "IngressControllerSetHTTPHeader defines the value which needs to be set on an HTTP header.", - "value": "value specifies a header value. Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. The value of this field must be no more than 16384 characters in length. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. ", -} - -func (IngressControllerSetHTTPHeader) SwaggerDoc() map[string]string { - return map_IngressControllerSetHTTPHeader -} - var map_IngressControllerSpec = map[string]string{ "": "IngressControllerSpec is the specification of the desired behavior of the IngressController.", "domain": "domain is a DNS name serviced by the ingress controller and is used to configure multiple features:\n\n* For the LoadBalancerService endpoint publishing strategy, domain is\n used to configure DNS records. See endpointPublishingStrategy.\n\n* When using a generated default certificate, the certificate will be valid\n for domain and its subdomains. See defaultCertificate.\n\n* The value is published to individual Route statuses so that end-users\n know where to target external DNS records.\n\ndomain must be unique among all IngressControllers, and cannot be updated.\n\nIf empty, defaults to ingress.config.openshift.io/cluster .spec.domain.", @@ -1235,6 +1195,27 @@ func (KubeStorageVersionMigratorList) SwaggerDoc() map[string]string { return map_KubeStorageVersionMigratorList } +var map_MachineConfiguration = map[string]string{ + "": "MachineConfiguration provides information to configure an operator to manage Machine Configuration.\n\nCompatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).", + "metadata": "metadata is the standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + "spec": "spec is the specification of the desired behavior of the Machine Config Operator", + "status": "status is the most recently observed status of the Machine Config Operator", +} + +func (MachineConfiguration) SwaggerDoc() map[string]string { + return map_MachineConfiguration +} + +var map_MachineConfigurationList = map[string]string{ + "": "MachineConfigurationList is a collection of items\n\nCompatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer).", + "metadata": "metadata is the standard list's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + "items": "Items contains the items", +} + +func (MachineConfigurationList) SwaggerDoc() map[string]string { + return map_MachineConfigurationList +} + var map_AdditionalNetworkDefinition = map[string]string{ "": "AdditionalNetworkDefinition configures an extra network that is available but not created by default. Instead, pods must request them by name. type must be specified, along with exactly one \"Config\" that matches the type.", "type": "type is the type of network The supported values are NetworkTypeRaw, NetworkTypeSimpleMacvlan", diff --git a/vendor/github.com/openshift/api/route/v1/generated.pb.go b/vendor/github.com/openshift/api/route/v1/generated.pb.go index 2adcd1cc86..e7c3284895 100644 --- a/vendor/github.com/openshift/api/route/v1/generated.pb.go +++ b/vendor/github.com/openshift/api/route/v1/generated.pb.go @@ -86,122 +86,10 @@ func (m *Route) XXX_DiscardUnknown() { var xxx_messageInfo_Route proto.InternalMessageInfo -func (m *RouteHTTPHeader) Reset() { *m = RouteHTTPHeader{} } -func (*RouteHTTPHeader) ProtoMessage() {} -func (*RouteHTTPHeader) Descriptor() ([]byte, []int) { - return fileDescriptor_373b8fa7ff738721, []int{2} -} -func (m *RouteHTTPHeader) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *RouteHTTPHeader) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *RouteHTTPHeader) XXX_Merge(src proto.Message) { - xxx_messageInfo_RouteHTTPHeader.Merge(m, src) -} -func (m *RouteHTTPHeader) XXX_Size() int { - return m.Size() -} -func (m *RouteHTTPHeader) XXX_DiscardUnknown() { - xxx_messageInfo_RouteHTTPHeader.DiscardUnknown(m) -} - -var xxx_messageInfo_RouteHTTPHeader proto.InternalMessageInfo - -func (m *RouteHTTPHeaderActionUnion) Reset() { *m = RouteHTTPHeaderActionUnion{} } -func (*RouteHTTPHeaderActionUnion) ProtoMessage() {} -func (*RouteHTTPHeaderActionUnion) Descriptor() ([]byte, []int) { - return fileDescriptor_373b8fa7ff738721, []int{3} -} -func (m *RouteHTTPHeaderActionUnion) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *RouteHTTPHeaderActionUnion) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *RouteHTTPHeaderActionUnion) XXX_Merge(src proto.Message) { - xxx_messageInfo_RouteHTTPHeaderActionUnion.Merge(m, src) -} -func (m *RouteHTTPHeaderActionUnion) XXX_Size() int { - return m.Size() -} -func (m *RouteHTTPHeaderActionUnion) XXX_DiscardUnknown() { - xxx_messageInfo_RouteHTTPHeaderActionUnion.DiscardUnknown(m) -} - -var xxx_messageInfo_RouteHTTPHeaderActionUnion proto.InternalMessageInfo - -func (m *RouteHTTPHeaderActions) Reset() { *m = RouteHTTPHeaderActions{} } -func (*RouteHTTPHeaderActions) ProtoMessage() {} -func (*RouteHTTPHeaderActions) Descriptor() ([]byte, []int) { - return fileDescriptor_373b8fa7ff738721, []int{4} -} -func (m *RouteHTTPHeaderActions) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *RouteHTTPHeaderActions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *RouteHTTPHeaderActions) XXX_Merge(src proto.Message) { - xxx_messageInfo_RouteHTTPHeaderActions.Merge(m, src) -} -func (m *RouteHTTPHeaderActions) XXX_Size() int { - return m.Size() -} -func (m *RouteHTTPHeaderActions) XXX_DiscardUnknown() { - xxx_messageInfo_RouteHTTPHeaderActions.DiscardUnknown(m) -} - -var xxx_messageInfo_RouteHTTPHeaderActions proto.InternalMessageInfo - -func (m *RouteHTTPHeaders) Reset() { *m = RouteHTTPHeaders{} } -func (*RouteHTTPHeaders) ProtoMessage() {} -func (*RouteHTTPHeaders) Descriptor() ([]byte, []int) { - return fileDescriptor_373b8fa7ff738721, []int{5} -} -func (m *RouteHTTPHeaders) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *RouteHTTPHeaders) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *RouteHTTPHeaders) XXX_Merge(src proto.Message) { - xxx_messageInfo_RouteHTTPHeaders.Merge(m, src) -} -func (m *RouteHTTPHeaders) XXX_Size() int { - return m.Size() -} -func (m *RouteHTTPHeaders) XXX_DiscardUnknown() { - xxx_messageInfo_RouteHTTPHeaders.DiscardUnknown(m) -} - -var xxx_messageInfo_RouteHTTPHeaders proto.InternalMessageInfo - func (m *RouteIngress) Reset() { *m = RouteIngress{} } func (*RouteIngress) ProtoMessage() {} func (*RouteIngress) Descriptor() ([]byte, []int) { - return fileDescriptor_373b8fa7ff738721, []int{6} + return fileDescriptor_373b8fa7ff738721, []int{2} } func (m *RouteIngress) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -229,7 +117,7 @@ var xxx_messageInfo_RouteIngress proto.InternalMessageInfo func (m *RouteIngressCondition) Reset() { *m = RouteIngressCondition{} } func (*RouteIngressCondition) ProtoMessage() {} func (*RouteIngressCondition) Descriptor() ([]byte, []int) { - return fileDescriptor_373b8fa7ff738721, []int{7} + return fileDescriptor_373b8fa7ff738721, []int{3} } func (m *RouteIngressCondition) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -257,7 +145,7 @@ var xxx_messageInfo_RouteIngressCondition proto.InternalMessageInfo func (m *RouteList) Reset() { *m = RouteList{} } func (*RouteList) ProtoMessage() {} func (*RouteList) Descriptor() ([]byte, []int) { - return fileDescriptor_373b8fa7ff738721, []int{8} + return fileDescriptor_373b8fa7ff738721, []int{4} } func (m *RouteList) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -285,7 +173,7 @@ var xxx_messageInfo_RouteList proto.InternalMessageInfo func (m *RoutePort) Reset() { *m = RoutePort{} } func (*RoutePort) ProtoMessage() {} func (*RoutePort) Descriptor() ([]byte, []int) { - return fileDescriptor_373b8fa7ff738721, []int{9} + return fileDescriptor_373b8fa7ff738721, []int{5} } func (m *RoutePort) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -310,38 +198,10 @@ func (m *RoutePort) XXX_DiscardUnknown() { var xxx_messageInfo_RoutePort proto.InternalMessageInfo -func (m *RouteSetHTTPHeader) Reset() { *m = RouteSetHTTPHeader{} } -func (*RouteSetHTTPHeader) ProtoMessage() {} -func (*RouteSetHTTPHeader) Descriptor() ([]byte, []int) { - return fileDescriptor_373b8fa7ff738721, []int{10} -} -func (m *RouteSetHTTPHeader) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *RouteSetHTTPHeader) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *RouteSetHTTPHeader) XXX_Merge(src proto.Message) { - xxx_messageInfo_RouteSetHTTPHeader.Merge(m, src) -} -func (m *RouteSetHTTPHeader) XXX_Size() int { - return m.Size() -} -func (m *RouteSetHTTPHeader) XXX_DiscardUnknown() { - xxx_messageInfo_RouteSetHTTPHeader.DiscardUnknown(m) -} - -var xxx_messageInfo_RouteSetHTTPHeader proto.InternalMessageInfo - func (m *RouteSpec) Reset() { *m = RouteSpec{} } func (*RouteSpec) ProtoMessage() {} func (*RouteSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_373b8fa7ff738721, []int{11} + return fileDescriptor_373b8fa7ff738721, []int{6} } func (m *RouteSpec) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -369,7 +229,7 @@ var xxx_messageInfo_RouteSpec proto.InternalMessageInfo func (m *RouteStatus) Reset() { *m = RouteStatus{} } func (*RouteStatus) ProtoMessage() {} func (*RouteStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_373b8fa7ff738721, []int{12} + return fileDescriptor_373b8fa7ff738721, []int{7} } func (m *RouteStatus) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -397,7 +257,7 @@ var xxx_messageInfo_RouteStatus proto.InternalMessageInfo func (m *RouteTargetReference) Reset() { *m = RouteTargetReference{} } func (*RouteTargetReference) ProtoMessage() {} func (*RouteTargetReference) Descriptor() ([]byte, []int) { - return fileDescriptor_373b8fa7ff738721, []int{13} + return fileDescriptor_373b8fa7ff738721, []int{8} } func (m *RouteTargetReference) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -425,7 +285,7 @@ var xxx_messageInfo_RouteTargetReference proto.InternalMessageInfo func (m *RouterShard) Reset() { *m = RouterShard{} } func (*RouterShard) ProtoMessage() {} func (*RouterShard) Descriptor() ([]byte, []int) { - return fileDescriptor_373b8fa7ff738721, []int{14} + return fileDescriptor_373b8fa7ff738721, []int{9} } func (m *RouterShard) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -453,7 +313,7 @@ var xxx_messageInfo_RouterShard proto.InternalMessageInfo func (m *TLSConfig) Reset() { *m = TLSConfig{} } func (*TLSConfig) ProtoMessage() {} func (*TLSConfig) Descriptor() ([]byte, []int) { - return fileDescriptor_373b8fa7ff738721, []int{15} + return fileDescriptor_373b8fa7ff738721, []int{10} } func (m *TLSConfig) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -481,15 +341,10 @@ var xxx_messageInfo_TLSConfig proto.InternalMessageInfo func init() { proto.RegisterType((*LocalObjectReference)(nil), "github.com.openshift.api.route.v1.LocalObjectReference") proto.RegisterType((*Route)(nil), "github.com.openshift.api.route.v1.Route") - proto.RegisterType((*RouteHTTPHeader)(nil), "github.com.openshift.api.route.v1.RouteHTTPHeader") - proto.RegisterType((*RouteHTTPHeaderActionUnion)(nil), "github.com.openshift.api.route.v1.RouteHTTPHeaderActionUnion") - proto.RegisterType((*RouteHTTPHeaderActions)(nil), "github.com.openshift.api.route.v1.RouteHTTPHeaderActions") - proto.RegisterType((*RouteHTTPHeaders)(nil), "github.com.openshift.api.route.v1.RouteHTTPHeaders") proto.RegisterType((*RouteIngress)(nil), "github.com.openshift.api.route.v1.RouteIngress") proto.RegisterType((*RouteIngressCondition)(nil), "github.com.openshift.api.route.v1.RouteIngressCondition") proto.RegisterType((*RouteList)(nil), "github.com.openshift.api.route.v1.RouteList") proto.RegisterType((*RoutePort)(nil), "github.com.openshift.api.route.v1.RoutePort") - proto.RegisterType((*RouteSetHTTPHeader)(nil), "github.com.openshift.api.route.v1.RouteSetHTTPHeader") proto.RegisterType((*RouteSpec)(nil), "github.com.openshift.api.route.v1.RouteSpec") proto.RegisterType((*RouteStatus)(nil), "github.com.openshift.api.route.v1.RouteStatus") proto.RegisterType((*RouteTargetReference)(nil), "github.com.openshift.api.route.v1.RouteTargetReference") @@ -502,96 +357,84 @@ func init() { } var fileDescriptor_373b8fa7ff738721 = []byte{ - // 1420 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x58, 0xdd, 0x6e, 0x13, 0xc7, - 0x17, 0xcf, 0xc6, 0x76, 0x1c, 0x8f, 0xf9, 0x1c, 0xbe, 0x4c, 0x24, 0x6c, 0xd8, 0xbf, 0xf4, 0x17, - 0x54, 0x74, 0xdd, 0x04, 0x68, 0x41, 0x15, 0x17, 0x6c, 0x40, 0x10, 0x30, 0x21, 0x1a, 0xbb, 0xa0, - 0x22, 0x2a, 0x75, 0xb2, 0x3b, 0xb6, 0xa7, 0xb1, 0x67, 0x97, 0x99, 0x71, 0x20, 0x37, 0x15, 0x6a, - 0x5f, 0x80, 0xde, 0xf6, 0x15, 0xaa, 0xde, 0xf7, 0x11, 0xb8, 0xe4, 0x92, 0xde, 0x58, 0x8d, 0x7b, - 0xd9, 0x37, 0xc8, 0x55, 0x35, 0xb3, 0xe3, 0xdd, 0xb5, 0x63, 0x13, 0x07, 0xf5, 0xce, 0x7b, 0xce, - 0xf9, 0xfd, 0xce, 0xc7, 0x9c, 0x39, 0x67, 0x12, 0xb0, 0xdc, 0xa2, 0xb2, 0xdd, 0xdb, 0x74, 0xbc, - 0xa0, 0x5b, 0x0d, 0x42, 0xc2, 0x44, 0x9b, 0x36, 0x65, 0x15, 0x87, 0xb4, 0xca, 0x83, 0x9e, 0x24, - 0xd5, 0xed, 0xe5, 0x6a, 0x8b, 0x30, 0xc2, 0xb1, 0x24, 0xbe, 0x13, 0xf2, 0x40, 0x06, 0xf0, 0x52, - 0x02, 0x71, 0x62, 0x88, 0x83, 0x43, 0xea, 0x68, 0x88, 0xb3, 0xbd, 0xbc, 0xf4, 0x79, 0x8a, 0xb5, - 0x15, 0xb4, 0x82, 0xaa, 0x46, 0x6e, 0xf6, 0x9a, 0xfa, 0x4b, 0x7f, 0xe8, 0x5f, 0x11, 0xe3, 0x92, - 0xbd, 0x75, 0x53, 0x38, 0x34, 0xd0, 0x6e, 0xbd, 0x80, 0x4f, 0xf2, 0xba, 0x74, 0x3d, 0xb1, 0xe9, - 0x62, 0xaf, 0x4d, 0x19, 0xe1, 0x3b, 0xd5, 0x70, 0xab, 0xa5, 0x04, 0xa2, 0xda, 0x25, 0x12, 0x4f, - 0x42, 0x7d, 0x39, 0x0d, 0xc5, 0x7b, 0x4c, 0xd2, 0x2e, 0xa9, 0x0a, 0xaf, 0x4d, 0xba, 0x78, 0x1f, - 0xee, 0xda, 0x34, 0x5c, 0x4f, 0xd2, 0x4e, 0x95, 0x32, 0x29, 0x24, 0x1f, 0x07, 0xd9, 0x37, 0xc1, - 0xe9, 0x5a, 0xe0, 0xe1, 0xce, 0x93, 0xcd, 0x1f, 0x88, 0x27, 0x11, 0x69, 0x12, 0x4e, 0x98, 0x47, - 0xe0, 0x45, 0x90, 0x65, 0xb8, 0x4b, 0x4a, 0xd6, 0x45, 0xeb, 0x72, 0xc1, 0x3d, 0xf2, 0xae, 0x5f, - 0x99, 0x1b, 0xf4, 0x2b, 0xd9, 0x75, 0xdc, 0x25, 0x48, 0x6b, 0xec, 0x5f, 0xe6, 0x41, 0x0e, 0xa9, - 0xe2, 0xc1, 0xef, 0xc1, 0xa2, 0xca, 0xc5, 0xc7, 0x12, 0x6b, 0xfb, 0xe2, 0xca, 0x17, 0x4e, 0x14, - 0x8b, 0x93, 0x8e, 0xc5, 0x09, 0xb7, 0x5a, 0x4a, 0x20, 0x1c, 0x65, 0xed, 0x6c, 0x2f, 0x3b, 0x91, - 0xd3, 0xc7, 0x44, 0x62, 0x17, 0x1a, 0x0f, 0x20, 0x91, 0xa1, 0x98, 0x15, 0xae, 0x83, 0xac, 0x08, - 0x89, 0x57, 0x9a, 0xd7, 0xec, 0x57, 0x9d, 0x03, 0x4f, 0xd3, 0xd1, 0x91, 0xd5, 0x43, 0xe2, 0x25, - 0xb1, 0xab, 0x2f, 0xa4, 0x79, 0xe0, 0x53, 0xb0, 0x20, 0x24, 0x96, 0x3d, 0x51, 0xca, 0x68, 0x46, - 0x67, 0x66, 0x46, 0x8d, 0x72, 0x8f, 0x19, 0xce, 0x85, 0xe8, 0x1b, 0x19, 0x36, 0xfb, 0x57, 0x0b, - 0x1c, 0xd7, 0x76, 0x0f, 0x1a, 0x8d, 0x8d, 0x07, 0x04, 0xfb, 0x84, 0x1f, 0x5c, 0x49, 0x48, 0xc0, - 0x02, 0xf6, 0x24, 0x0d, 0x98, 0xc9, 0xef, 0xf6, 0xac, 0xd1, 0x24, 0x5e, 0xee, 0x68, 0xfc, 0x37, - 0x8c, 0x06, 0x2c, 0x09, 0x2e, 0x12, 0x22, 0x43, 0x6e, 0xff, 0x6e, 0x81, 0xa5, 0xe9, 0x30, 0x78, - 0x1b, 0x64, 0xe5, 0x4e, 0x38, 0x8c, 0xf3, 0xca, 0x30, 0xce, 0xc6, 0x4e, 0x48, 0xf6, 0xfa, 0x95, - 0xf3, 0x13, 0x91, 0x4a, 0x89, 0x34, 0x0c, 0x6e, 0x80, 0x8c, 0x20, 0xd2, 0x64, 0x70, 0x63, 0xe6, - 0x7a, 0x12, 0x99, 0x70, 0xba, 0xf9, 0x41, 0xbf, 0x92, 0xa9, 0x13, 0x89, 0x14, 0x95, 0xfd, 0xa7, - 0x05, 0xce, 0x4e, 0xf4, 0x2a, 0x54, 0xc7, 0x71, 0x22, 0xc2, 0x80, 0x09, 0x15, 0x6f, 0xe6, 0x72, - 0x71, 0x65, 0xe5, 0xf0, 0x35, 0x73, 0x4f, 0x98, 0x1c, 0x17, 0x91, 0xe1, 0x42, 0x31, 0x2b, 0xfc, - 0x0e, 0xe4, 0x39, 0x79, 0xd9, 0x23, 0x42, 0xa5, 0xf4, 0xa9, 0x0e, 0x8e, 0x1b, 0x07, 0x79, 0x14, - 0x51, 0xa1, 0x21, 0xa7, 0xfd, 0x1a, 0x9c, 0x18, 0x33, 0x16, 0xd0, 0x07, 0xf9, 0xe8, 0xa4, 0x84, - 0xb9, 0x45, 0xb7, 0x3e, 0xb5, 0x0f, 0x44, 0xe2, 0xd9, 0x08, 0xd0, 0x90, 0xda, 0xfe, 0x39, 0x03, - 0x8e, 0x68, 0xd0, 0x1a, 0x6b, 0x71, 0x22, 0x84, 0xea, 0xcf, 0x76, 0x20, 0xe4, 0x78, 0x7f, 0x3e, - 0x08, 0x84, 0x44, 0x5a, 0x03, 0x57, 0x00, 0xd0, 0xfe, 0xb8, 0xea, 0x59, 0x7d, 0xc2, 0x85, 0xe4, - 0xbe, 0xa2, 0x58, 0x83, 0x52, 0x56, 0xb0, 0x03, 0x80, 0x17, 0x30, 0x9f, 0x46, 0xf9, 0x64, 0x74, - 0x09, 0x6f, 0xce, 0x9a, 0x8f, 0x09, 0x6d, 0x75, 0x48, 0x90, 0x78, 0x8b, 0x45, 0x02, 0xa5, 0xf8, - 0x61, 0x03, 0x1c, 0x7b, 0x45, 0x3b, 0xbe, 0x87, 0xb9, 0xbf, 0x11, 0x74, 0xa8, 0xb7, 0x53, 0xca, - 0xea, 0x28, 0xaf, 0x1a, 0xdc, 0xb1, 0x67, 0x23, 0xda, 0xbd, 0x7e, 0x05, 0x8e, 0x4a, 0x74, 0x23, - 0x8f, 0x71, 0xc0, 0x6f, 0xc1, 0xb9, 0x28, 0xa3, 0x55, 0xcc, 0x02, 0x46, 0x3d, 0xdc, 0x51, 0x45, - 0xd1, 0x97, 0x39, 0xa7, 0xe9, 0x2b, 0x86, 0xfe, 0x1c, 0x9a, 0x6c, 0x86, 0xa6, 0xe1, 0xed, 0x7f, - 0xe6, 0xc1, 0x99, 0x89, 0xa9, 0xce, 0x74, 0x0d, 0xc7, 0x41, 0xa9, 0x6b, 0x58, 0x8b, 0x27, 0x5b, - 0x74, 0x4e, 0xd7, 0x47, 0x27, 0xd5, 0x5e, 0xbf, 0x32, 0x61, 0x71, 0x39, 0x31, 0xd3, 0xe8, 0x3c, - 0x83, 0xff, 0x07, 0x0b, 0x9c, 0x60, 0x11, 0x30, 0x3d, 0x27, 0x0b, 0xc9, 0x68, 0x41, 0x5a, 0x8a, - 0x8c, 0x16, 0x5e, 0x01, 0xf9, 0x2e, 0x11, 0x02, 0xb7, 0x88, 0x29, 0x7c, 0xdc, 0x7f, 0x8f, 0x23, - 0x31, 0x1a, 0xea, 0x21, 0x07, 0xb0, 0x83, 0x85, 0x6c, 0x70, 0xcc, 0x44, 0x14, 0x3c, 0x35, 0xf5, - 0x2c, 0xae, 0x7c, 0x36, 0xdb, 0xda, 0x50, 0x08, 0xf7, 0xec, 0xa0, 0x5f, 0x81, 0xb5, 0x7d, 0x4c, - 0x68, 0x02, 0xbb, 0xfd, 0x87, 0x05, 0x0a, 0xba, 0x70, 0x35, 0x2a, 0x24, 0x7c, 0xb1, 0x6f, 0x5d, - 0x39, 0xb3, 0xf9, 0x55, 0x68, 0xbd, 0xac, 0xe2, 0xc1, 0x31, 0x94, 0xa4, 0x56, 0xd5, 0x63, 0x90, - 0xa3, 0x92, 0x74, 0x85, 0x19, 0x1b, 0x97, 0x67, 0xed, 0x79, 0xf7, 0xa8, 0x21, 0xcd, 0xad, 0x29, - 0x38, 0x8a, 0x58, 0xec, 0x97, 0x26, 0xf2, 0x8d, 0x80, 0x4b, 0xe8, 0x03, 0x20, 0x31, 0x6f, 0x11, - 0xa9, 0xbe, 0x0e, 0x5c, 0xb5, 0x6a, 0xed, 0x3b, 0xd1, 0xda, 0x77, 0xd6, 0x98, 0x7c, 0xc2, 0xeb, - 0x92, 0x53, 0xd6, 0x4a, 0x2e, 0x53, 0x23, 0xe6, 0x42, 0x29, 0x5e, 0xfb, 0x16, 0x80, 0xfb, 0x67, - 0x33, 0xfc, 0x1f, 0xc8, 0x6d, 0xe3, 0x4e, 0x6f, 0xd8, 0x98, 0x71, 0xb4, 0x4f, 0x95, 0x10, 0x45, - 0x3a, 0xfb, 0xb7, 0x9c, 0x09, 0x57, 0xed, 0xda, 0x19, 0x26, 0x4b, 0x15, 0x14, 0x44, 0x6f, 0xd3, - 0x0f, 0xba, 0x98, 0xb2, 0xd2, 0xa2, 0x36, 0x3b, 0x69, 0xcc, 0x0a, 0xf5, 0xa1, 0x02, 0x25, 0x36, - 0x8a, 0x32, 0xc4, 0xb2, 0x6d, 0x9a, 0x3b, 0xa6, 0xdc, 0xc0, 0xb2, 0x8d, 0xb4, 0x06, 0xd6, 0xc1, - 0xbc, 0x0c, 0xcc, 0x5a, 0xff, 0x6a, 0xd6, 0xe2, 0x47, 0x95, 0x88, 0x5f, 0x3f, 0x2e, 0x30, 0xc4, - 0xf3, 0x8d, 0x00, 0xcd, 0xcb, 0x00, 0xbe, 0xb1, 0xc0, 0x49, 0xdc, 0x91, 0x84, 0x33, 0x2c, 0x89, - 0x8b, 0xbd, 0x2d, 0xc2, 0x7c, 0x51, 0xca, 0xea, 0x13, 0xfe, 0x64, 0x27, 0xe7, 0x8d, 0x93, 0x93, - 0x77, 0xc6, 0x99, 0xd1, 0x7e, 0x67, 0xf0, 0x21, 0xc8, 0x86, 0xea, 0xd4, 0x73, 0x87, 0x7b, 0x02, - 0xa9, 0x13, 0x75, 0x17, 0x75, 0x8d, 0xd4, 0x39, 0x6b, 0x0e, 0x78, 0x1f, 0x64, 0x64, 0x47, 0x94, - 0x16, 0x66, 0xa6, 0x6a, 0xd4, 0xea, 0xab, 0x01, 0x6b, 0xd2, 0x56, 0xb4, 0xa2, 0x1b, 0xb5, 0x3a, - 0x52, 0x0c, 0x13, 0xe6, 0x6e, 0xfe, 0x3f, 0x98, 0xbb, 0x4d, 0x50, 0x6c, 0x4b, 0x19, 0x9a, 0xbd, - 0x58, 0x2a, 0xe8, 0x30, 0xaf, 0x1d, 0x7e, 0x19, 0x0a, 0xf7, 0xf8, 0xa0, 0x5f, 0x29, 0xa6, 0x04, - 0x28, 0x4d, 0x6c, 0x53, 0x50, 0x4c, 0x3d, 0xea, 0xe0, 0x73, 0x90, 0xa7, 0xd1, 0x60, 0x35, 0x6f, - 0x8a, 0xea, 0x21, 0xf7, 0x55, 0x32, 0xf5, 0x8c, 0x00, 0x0d, 0x09, 0xed, 0x1f, 0xc1, 0xe9, 0x49, - 0x3d, 0xa0, 0xfa, 0x79, 0x8b, 0x32, 0x7f, 0xfc, 0x8a, 0x3c, 0xa2, 0xcc, 0x47, 0x5a, 0x13, 0x3f, - 0x1f, 0xe7, 0xa7, 0x3e, 0x1f, 0x6d, 0xb0, 0xf0, 0x8a, 0xd0, 0x56, 0x5b, 0xea, 0xae, 0xcf, 0xb9, - 0x40, 0x0d, 0xe8, 0x67, 0x5a, 0x82, 0x8c, 0xc6, 0x0e, 0x4c, 0xaa, 0xbc, 0xde, 0xc6, 0xdc, 0xd7, - 0xf7, 0x4e, 0xfd, 0x58, 0x4f, 0x1e, 0xa6, 0xc9, 0xbd, 0x1b, 0x2a, 0x50, 0x62, 0xa3, 0x00, 0x3e, - 0x13, 0xf5, 0x5e, 0xb3, 0x49, 0x5f, 0x9b, 0x50, 0x62, 0xc0, 0xdd, 0xf5, 0x7a, 0xa4, 0x40, 0x89, - 0x8d, 0xbd, 0x9b, 0x05, 0x85, 0xb8, 0x6b, 0xe0, 0x23, 0x50, 0x94, 0x84, 0x77, 0x29, 0xc3, 0xfa, - 0x99, 0x3b, 0xba, 0xdb, 0x8a, 0x8d, 0x44, 0xa5, 0x3a, 0xa4, 0x51, 0xab, 0xa7, 0x24, 0xba, 0x43, - 0xd2, 0x68, 0x78, 0x03, 0x14, 0x3d, 0xc2, 0x25, 0x6d, 0x52, 0x0f, 0xcb, 0x61, 0x61, 0x4e, 0x0d, - 0xc9, 0x56, 0x13, 0x15, 0x4a, 0xdb, 0xc1, 0x0b, 0x20, 0xb3, 0x45, 0x76, 0xcc, 0x22, 0x2b, 0x1a, - 0xf3, 0xcc, 0x23, 0xb2, 0x83, 0x94, 0x1c, 0x7e, 0x0d, 0x8e, 0x7a, 0x38, 0x05, 0x36, 0x8b, 0xec, - 0x8c, 0x31, 0x3c, 0xba, 0x7a, 0x27, 0xcd, 0x3c, 0x6a, 0x0b, 0x5f, 0x80, 0x92, 0x4f, 0x84, 0x34, - 0x11, 0x8e, 0x98, 0x9a, 0xa7, 0xc2, 0x45, 0xc3, 0x53, 0xba, 0x3b, 0xc5, 0x0e, 0x4d, 0x65, 0x80, - 0x6f, 0x2d, 0x70, 0x81, 0x32, 0x41, 0xbc, 0x1e, 0x27, 0xf7, 0xfc, 0x16, 0x49, 0x55, 0xc7, 0xdc, - 0xba, 0x05, 0xed, 0xe3, 0xa1, 0xf1, 0x71, 0x61, 0xed, 0x63, 0xc6, 0x7b, 0xfd, 0xca, 0xa5, 0x8f, - 0x1a, 0xe8, 0x8a, 0x7f, 0xdc, 0x21, 0xfc, 0xc9, 0x02, 0xa7, 0xc8, 0x6b, 0x3d, 0xa3, 0x3a, 0xe9, - 0x64, 0xf3, 0x33, 0xcf, 0xdd, 0x49, 0x7f, 0x75, 0xba, 0xe7, 0x06, 0xfd, 0xca, 0xa9, 0x7b, 0xfb, - 0x79, 0xd1, 0x24, 0x67, 0xee, 0xfd, 0x77, 0xbb, 0xe5, 0xb9, 0xf7, 0xbb, 0xe5, 0xb9, 0x0f, 0xbb, - 0xe5, 0xb9, 0x37, 0x83, 0xb2, 0xf5, 0x6e, 0x50, 0xb6, 0xde, 0x0f, 0xca, 0xd6, 0x87, 0x41, 0xd9, - 0xfa, 0x6b, 0x50, 0xb6, 0xde, 0xfe, 0x5d, 0x9e, 0x7b, 0x7e, 0xe9, 0xc0, 0xff, 0x16, 0xfc, 0x1b, - 0x00, 0x00, 0xff, 0xff, 0x62, 0x5d, 0xac, 0x2e, 0x51, 0x10, 0x00, 0x00, + // 1217 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x57, 0xcf, 0x92, 0xd3, 0xc6, + 0x13, 0x5e, 0xd9, 0xde, 0x3f, 0x1e, 0x03, 0xbf, 0x1f, 0x03, 0x04, 0x43, 0x15, 0x36, 0xe8, 0x90, + 0x82, 0x14, 0x91, 0xb2, 0x1b, 0x92, 0x50, 0x95, 0xca, 0x01, 0x2d, 0x14, 0x59, 0x30, 0x0b, 0x35, + 0x76, 0x85, 0x0a, 0xc5, 0x21, 0xb3, 0xd2, 0x58, 0x9e, 0xac, 0x3d, 0xa3, 0xcc, 0x8c, 0x81, 0xbd, + 0xa4, 0xa8, 0xe4, 0x05, 0xc8, 0xdb, 0xe4, 0x9e, 0x0b, 0x47, 0x8e, 0x9c, 0x5c, 0x59, 0xe7, 0x98, + 0x37, 0xd8, 0x53, 0x6a, 0x46, 0x63, 0x49, 0xf6, 0xda, 0x60, 0x92, 0x9b, 0xd5, 0xfd, 0x7d, 0x5f, + 0xf7, 0x74, 0xb7, 0x7a, 0x64, 0xb0, 0x19, 0x53, 0xd5, 0x1b, 0xee, 0x79, 0x21, 0x1f, 0xf8, 0x3c, + 0x21, 0x4c, 0xf6, 0x68, 0x57, 0xf9, 0x38, 0xa1, 0xbe, 0xe0, 0x43, 0x45, 0xfc, 0x67, 0x9b, 0x7e, + 0x4c, 0x18, 0x11, 0x58, 0x91, 0xc8, 0x4b, 0x04, 0x57, 0x1c, 0x5e, 0xc9, 0x29, 0x5e, 0x46, 0xf1, + 0x70, 0x42, 0x3d, 0x43, 0xf1, 0x9e, 0x6d, 0x5e, 0xfc, 0xb4, 0xa0, 0x1a, 0xf3, 0x98, 0xfb, 0x86, + 0xb9, 0x37, 0xec, 0x9a, 0x27, 0xf3, 0x60, 0x7e, 0xa5, 0x8a, 0x17, 0xdd, 0xfd, 0x9b, 0xd2, 0xa3, + 0xdc, 0x84, 0x0d, 0xb9, 0x98, 0x17, 0xf5, 0xe2, 0x8d, 0x1c, 0x33, 0xc0, 0x61, 0x8f, 0x32, 0x22, + 0x0e, 0xfc, 0x64, 0x3f, 0xd6, 0x06, 0xe9, 0x0f, 0x88, 0xc2, 0xf3, 0x58, 0x5f, 0x2e, 0x62, 0x89, + 0x21, 0x53, 0x74, 0x40, 0x7c, 0x19, 0xf6, 0xc8, 0x00, 0x1f, 0xe3, 0x7d, 0xbe, 0x88, 0x37, 0x54, + 0xb4, 0xef, 0x53, 0xa6, 0xa4, 0x12, 0xb3, 0x24, 0xf7, 0x26, 0x38, 0xdb, 0xe2, 0x21, 0xee, 0x3f, + 0xdc, 0xfb, 0x91, 0x84, 0x0a, 0x91, 0x2e, 0x11, 0x84, 0x85, 0x04, 0x5e, 0x06, 0x15, 0x86, 0x07, + 0xa4, 0xee, 0x5c, 0x76, 0xae, 0x56, 0x83, 0x13, 0xaf, 0x47, 0xcd, 0x95, 0xf1, 0xa8, 0x59, 0xd9, + 0xc5, 0x03, 0x82, 0x8c, 0xc7, 0xfd, 0xad, 0x04, 0x56, 0x91, 0x2e, 0x1e, 0xfc, 0x01, 0x6c, 0xe8, + 0xb3, 0x44, 0x58, 0x61, 0x83, 0xaf, 0x6d, 0x7d, 0xe6, 0xa5, 0xb9, 0x78, 0xc5, 0x5c, 0xbc, 0x64, + 0x3f, 0xd6, 0x06, 0xe9, 0x69, 0xb4, 0xf7, 0x6c, 0xd3, 0x4b, 0x83, 0x3e, 0x20, 0x0a, 0x07, 0xd0, + 0x46, 0x00, 0xb9, 0x0d, 0x65, 0xaa, 0x70, 0x17, 0x54, 0x64, 0x42, 0xc2, 0x7a, 0xc9, 0xa8, 0x5f, + 0xf7, 0xde, 0xdb, 0x4d, 0xcf, 0x64, 0xd6, 0x4e, 0x48, 0x98, 0xe7, 0xae, 0x9f, 0x90, 0xd1, 0x81, + 0xdf, 0x81, 0x35, 0xa9, 0xb0, 0x1a, 0xca, 0x7a, 0xd9, 0x28, 0x7a, 0x4b, 0x2b, 0x1a, 0x56, 0x70, + 0xca, 0x6a, 0xae, 0xa5, 0xcf, 0xc8, 0xaa, 0xb9, 0xbf, 0x96, 0xc1, 0x09, 0x83, 0xdb, 0x61, 0xb1, + 0x20, 0x52, 0xea, 0x32, 0xf6, 0xb8, 0x54, 0xb3, 0x65, 0xfc, 0x96, 0x4b, 0x85, 0x8c, 0x07, 0x6e, + 0x01, 0x60, 0x42, 0x08, 0x5d, 0x5a, 0x73, 0xc0, 0x6a, 0x5e, 0x0c, 0x94, 0x79, 0x50, 0x01, 0x05, + 0xfb, 0x00, 0x84, 0x9c, 0x45, 0x54, 0x51, 0xce, 0xf4, 0x11, 0xca, 0x57, 0x6b, 0x5b, 0x37, 0x97, + 0x3d, 0x82, 0x4d, 0x6d, 0x7b, 0x22, 0x90, 0x47, 0xcb, 0x4c, 0x12, 0x15, 0xf4, 0x61, 0x07, 0x9c, + 0x7a, 0x4e, 0xfb, 0x51, 0x88, 0x45, 0xf4, 0x88, 0xf7, 0x69, 0x78, 0x50, 0xaf, 0x98, 0x2c, 0xaf, + 0x5b, 0xde, 0xa9, 0xc7, 0x53, 0xde, 0xa3, 0x51, 0x13, 0x4e, 0x5b, 0x3a, 0x07, 0x09, 0x41, 0x33, + 0x1a, 0xf0, 0x7b, 0x70, 0x3e, 0x3d, 0xd1, 0x36, 0x66, 0x9c, 0xd1, 0x10, 0xf7, 0x75, 0x51, 0xcc, + 0xcc, 0xad, 0x1a, 0xf9, 0xa6, 0x95, 0x3f, 0x8f, 0xe6, 0xc3, 0xd0, 0x22, 0xbe, 0xfb, 0x77, 0x09, + 0x9c, 0x9b, 0x7b, 0x54, 0xf8, 0x0d, 0xa8, 0xa8, 0x83, 0x64, 0x32, 0xd5, 0xd7, 0x26, 0xed, 0xd0, + 0x09, 0x1e, 0x8d, 0x9a, 0x17, 0xe6, 0x92, 0x4c, 0xf6, 0x86, 0x06, 0x5b, 0xd9, 0xd8, 0xa4, 0x7d, + 0xba, 0x31, 0x3d, 0x06, 0x47, 0xa3, 0xe6, 0x9c, 0xad, 0xe0, 0x65, 0x4a, 0xd3, 0xc3, 0x02, 0x3f, + 0x06, 0x6b, 0x82, 0x60, 0xc9, 0x99, 0x19, 0xc2, 0x6a, 0x3e, 0x54, 0xc8, 0x58, 0x91, 0xf5, 0xc2, + 0x6b, 0x60, 0x7d, 0x40, 0xa4, 0xc4, 0x31, 0xb1, 0x85, 0xff, 0x9f, 0x05, 0xae, 0x3f, 0x48, 0xcd, + 0x68, 0xe2, 0x87, 0x02, 0xc0, 0x3e, 0x96, 0xaa, 0x23, 0x30, 0x93, 0x69, 0xf2, 0xd4, 0xd6, 0xb3, + 0xb6, 0xf5, 0xc9, 0x72, 0xef, 0xa4, 0x66, 0x04, 0x1f, 0x8d, 0x47, 0x4d, 0xd8, 0x3a, 0xa6, 0x84, + 0xe6, 0xa8, 0xbb, 0xbf, 0x3b, 0xa0, 0x6a, 0x0a, 0xd7, 0xa2, 0x52, 0xc1, 0xa7, 0xc7, 0x76, 0x81, + 0xb7, 0x5c, 0x5c, 0xcd, 0x36, 0x9b, 0xe0, 0xff, 0xf6, 0x74, 0x1b, 0x13, 0x4b, 0x61, 0x0f, 0x3c, + 0x00, 0xab, 0x54, 0x91, 0x81, 0xae, 0xbf, 0x9e, 0xf9, 0xab, 0xcb, 0xce, 0x7c, 0x70, 0xd2, 0x8a, + 0xae, 0xee, 0x68, 0x3a, 0x4a, 0x55, 0xdc, 0x9f, 0x6c, 0xe6, 0x8f, 0xb8, 0x50, 0x30, 0x02, 0x40, + 0x61, 0x11, 0x13, 0xa5, 0x9f, 0xde, 0xbb, 0xc7, 0xf4, 0x4e, 0xf5, 0xd2, 0x9d, 0xea, 0xed, 0x30, + 0xf5, 0x50, 0xb4, 0x95, 0xa0, 0x2c, 0xce, 0x5f, 0xa6, 0x4e, 0xa6, 0x85, 0x0a, 0xba, 0xee, 0x1f, + 0x15, 0x1b, 0x53, 0x6f, 0xa3, 0x25, 0xd6, 0x83, 0x0f, 0xaa, 0x72, 0xb8, 0x17, 0xf1, 0x01, 0xa6, + 0xac, 0xbe, 0x61, 0x60, 0xa7, 0x2d, 0xac, 0xda, 0x9e, 0x38, 0x50, 0x8e, 0xd1, 0x92, 0x09, 0x56, + 0x3d, 0x3b, 0xa1, 0x99, 0xe4, 0x23, 0xac, 0x7a, 0xc8, 0x78, 0x60, 0x1b, 0x94, 0x14, 0xb7, 0x8b, + 0xef, 0xab, 0x65, 0x2b, 0x98, 0x1e, 0x27, 0xbb, 0x1f, 0x02, 0x60, 0x85, 0x4b, 0x1d, 0x8e, 0x4a, + 0x8a, 0xc3, 0x97, 0x0e, 0x38, 0x8d, 0xfb, 0x8a, 0x08, 0x86, 0x15, 0x09, 0x70, 0xb8, 0x4f, 0x58, + 0x24, 0xeb, 0x15, 0xd3, 0xa6, 0x7f, 0x1d, 0xe4, 0x82, 0x0d, 0x72, 0xfa, 0xd6, 0xac, 0x32, 0x3a, + 0x1e, 0x0c, 0xde, 0x03, 0x95, 0x44, 0xb7, 0x6e, 0xf5, 0xc3, 0x2e, 0x09, 0xdd, 0x96, 0x60, 0xc3, + 0xd4, 0x48, 0x37, 0xcb, 0x68, 0xc0, 0xbb, 0xa0, 0xac, 0xfa, 0xb2, 0xbe, 0xb6, 0xb4, 0x54, 0xa7, + 0xd5, 0xde, 0xe6, 0xac, 0x4b, 0xe3, 0x60, 0x7d, 0x3c, 0x6a, 0x96, 0x3b, 0xad, 0x36, 0xd2, 0x0a, + 0x73, 0x96, 0xe7, 0xfa, 0x7f, 0x5f, 0x9e, 0x2e, 0x05, 0xb5, 0xc2, 0x75, 0x04, 0x9f, 0x80, 0x75, + 0x9a, 0x6e, 0xad, 0xba, 0x63, 0x2a, 0xee, 0x7f, 0xe0, 0x65, 0x90, 0xaf, 0x14, 0x6b, 0x40, 0x13, + 0x41, 0xf7, 0x67, 0x70, 0x76, 0x5e, 0x6f, 0xf4, 0x9c, 0xed, 0x53, 0x16, 0xcd, 0x8e, 0xee, 0x7d, + 0xca, 0x22, 0x64, 0x3c, 0xd9, 0x27, 0x44, 0x69, 0xd1, 0x27, 0x04, 0x74, 0xc1, 0xda, 0x73, 0x42, + 0xe3, 0x9e, 0x32, 0xd3, 0xb8, 0x1a, 0x00, 0xbd, 0xfd, 0x1e, 0x1b, 0x0b, 0xb2, 0x1e, 0x97, 0xdb, + 0xa3, 0x8a, 0x76, 0x0f, 0x8b, 0xc8, 0xbc, 0x0f, 0xfa, 0xc7, 0x6e, 0xfe, 0x71, 0x92, 0xbf, 0x0f, + 0x13, 0x07, 0xca, 0x31, 0x9a, 0x10, 0x31, 0xd9, 0x1e, 0x76, 0xbb, 0xf4, 0x85, 0x4d, 0x25, 0x23, + 0xdc, 0xde, 0x6d, 0xa7, 0x0e, 0x94, 0x63, 0xdc, 0xc3, 0x0a, 0xa8, 0x66, 0xdd, 0x84, 0xf7, 0x41, + 0x4d, 0x11, 0x31, 0xa0, 0x0c, 0xeb, 0x85, 0x37, 0x73, 0x71, 0xd4, 0x3a, 0xb9, 0x4b, 0x77, 0xae, + 0xd3, 0x6a, 0x17, 0x2c, 0xa6, 0x73, 0x45, 0x36, 0xfc, 0x02, 0xd4, 0x42, 0x22, 0x14, 0xed, 0xd2, + 0x10, 0xab, 0x49, 0x61, 0xce, 0x4c, 0xc4, 0xb6, 0x73, 0x17, 0x2a, 0xe2, 0xe0, 0x25, 0x50, 0xde, + 0x27, 0x07, 0xf6, 0x96, 0xa8, 0x59, 0x78, 0xf9, 0x3e, 0x39, 0x40, 0xda, 0x0e, 0xbf, 0x06, 0x27, + 0x43, 0x5c, 0x20, 0xdb, 0x5b, 0xe2, 0x9c, 0x05, 0x9e, 0xdc, 0xbe, 0x55, 0x54, 0x9e, 0xc6, 0xc2, + 0xa7, 0xa0, 0x1e, 0x11, 0xa9, 0x6c, 0x86, 0x53, 0x50, 0x7b, 0x0f, 0x5f, 0xb6, 0x3a, 0xf5, 0xdb, + 0x0b, 0x70, 0x68, 0xa1, 0x02, 0x7c, 0xe5, 0x80, 0x4b, 0x94, 0x49, 0x12, 0x0e, 0x05, 0xb9, 0x13, + 0xc5, 0xa4, 0x50, 0x1d, 0xfb, 0x36, 0xac, 0x99, 0x18, 0xf7, 0x6c, 0x8c, 0x4b, 0x3b, 0xef, 0x02, + 0x1f, 0x8d, 0x9a, 0x57, 0xde, 0x09, 0x30, 0x15, 0x7f, 0x77, 0x40, 0xf8, 0x8b, 0x03, 0xce, 0x90, + 0x17, 0x66, 0x77, 0xf4, 0x8b, 0x87, 0x5d, 0x5f, 0x7a, 0x1f, 0xce, 0xfb, 0x5e, 0x0e, 0xce, 0x8f, + 0x47, 0xcd, 0x33, 0x77, 0x8e, 0xeb, 0xa2, 0x79, 0xc1, 0x82, 0xbb, 0xaf, 0x0f, 0x1b, 0x2b, 0x6f, + 0x0e, 0x1b, 0x2b, 0x6f, 0x0f, 0x1b, 0x2b, 0x2f, 0xc7, 0x0d, 0xe7, 0xf5, 0xb8, 0xe1, 0xbc, 0x19, + 0x37, 0x9c, 0xb7, 0xe3, 0x86, 0xf3, 0xe7, 0xb8, 0xe1, 0xbc, 0xfa, 0xab, 0xb1, 0xf2, 0xe4, 0xca, + 0x7b, 0xff, 0xe7, 0xfc, 0x13, 0x00, 0x00, 0xff, 0xff, 0x0c, 0xcd, 0xe6, 0xca, 0x0b, 0x0d, 0x00, + 0x00, } func (m *LocalObjectReference) Marshal() (dAtA []byte, err error) { @@ -675,168 +518,6 @@ func (m *Route) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *RouteHTTPHeader) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *RouteHTTPHeader) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *RouteHTTPHeader) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - { - size, err := m.Action.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - i -= len(m.Name) - copy(dAtA[i:], m.Name) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} - -func (m *RouteHTTPHeaderActionUnion) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *RouteHTTPHeaderActionUnion) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *RouteHTTPHeaderActionUnion) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if m.Set != nil { - { - size, err := m.Set.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - } - i -= len(m.Type) - copy(dAtA[i:], m.Type) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} - -func (m *RouteHTTPHeaderActions) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *RouteHTTPHeaderActions) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *RouteHTTPHeaderActions) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if len(m.Request) > 0 { - for iNdEx := len(m.Request) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Request[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - } - } - if len(m.Response) > 0 { - for iNdEx := len(m.Response) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Response[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa - } - } - return len(dAtA) - i, nil -} - -func (m *RouteHTTPHeaders) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *RouteHTTPHeaders) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *RouteHTTPHeaders) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - { - size, err := m.Actions.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} - func (m *RouteIngress) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -1029,7 +710,7 @@ func (m *RoutePort) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *RouteSetHTTPHeader) Marshal() (dAtA []byte, err error) { +func (m *RouteSpec) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -1039,59 +720,19 @@ func (m *RouteSetHTTPHeader) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *RouteSetHTTPHeader) MarshalTo(dAtA []byte) (int, error) { +func (m *RouteSpec) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *RouteSetHTTPHeader) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *RouteSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - i -= len(m.Value) - copy(dAtA[i:], m.Value) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Value))) - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} - -func (m *RouteSpec) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *RouteSpec) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *RouteSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if m.HTTPHeaders != nil { - { - size, err := m.HTTPHeaders.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x4a - } - i -= len(m.Subdomain) - copy(dAtA[i:], m.Subdomain) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Subdomain))) + i -= len(m.Subdomain) + copy(dAtA[i:], m.Subdomain) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Subdomain))) i-- dAtA[i] = 0x42 i -= len(m.WildcardPolicy) @@ -1370,66 +1011,6 @@ func (m *Route) Size() (n int) { return n } -func (m *RouteHTTPHeader) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Name) - n += 1 + l + sovGenerated(uint64(l)) - l = m.Action.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *RouteHTTPHeaderActionUnion) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Type) - n += 1 + l + sovGenerated(uint64(l)) - if m.Set != nil { - l = m.Set.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - return n -} - -func (m *RouteHTTPHeaderActions) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - if len(m.Response) > 0 { - for _, e := range m.Response { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - if len(m.Request) > 0 { - for _, e := range m.Request { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *RouteHTTPHeaders) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = m.Actions.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n -} - func (m *RouteIngress) Size() (n int) { if m == nil { return 0 @@ -1502,17 +1083,6 @@ func (m *RoutePort) Size() (n int) { return n } -func (m *RouteSetHTTPHeader) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Value) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - func (m *RouteSpec) Size() (n int) { if m == nil { return 0 @@ -1543,10 +1113,6 @@ func (m *RouteSpec) Size() (n int) { n += 1 + l + sovGenerated(uint64(l)) l = len(m.Subdomain) n += 1 + l + sovGenerated(uint64(l)) - if m.HTTPHeaders != nil { - l = m.HTTPHeaders.Size() - n += 1 + l + sovGenerated(uint64(l)) - } return n } @@ -1647,59 +1213,6 @@ func (this *Route) String() string { }, "") return s } -func (this *RouteHTTPHeader) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&RouteHTTPHeader{`, - `Name:` + fmt.Sprintf("%v", this.Name) + `,`, - `Action:` + strings.Replace(strings.Replace(this.Action.String(), "RouteHTTPHeaderActionUnion", "RouteHTTPHeaderActionUnion", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *RouteHTTPHeaderActionUnion) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&RouteHTTPHeaderActionUnion{`, - `Type:` + fmt.Sprintf("%v", this.Type) + `,`, - `Set:` + strings.Replace(this.Set.String(), "RouteSetHTTPHeader", "RouteSetHTTPHeader", 1) + `,`, - `}`, - }, "") - return s -} -func (this *RouteHTTPHeaderActions) String() string { - if this == nil { - return "nil" - } - repeatedStringForResponse := "[]RouteHTTPHeader{" - for _, f := range this.Response { - repeatedStringForResponse += strings.Replace(strings.Replace(f.String(), "RouteHTTPHeader", "RouteHTTPHeader", 1), `&`, ``, 1) + "," - } - repeatedStringForResponse += "}" - repeatedStringForRequest := "[]RouteHTTPHeader{" - for _, f := range this.Request { - repeatedStringForRequest += strings.Replace(strings.Replace(f.String(), "RouteHTTPHeader", "RouteHTTPHeader", 1), `&`, ``, 1) + "," - } - repeatedStringForRequest += "}" - s := strings.Join([]string{`&RouteHTTPHeaderActions{`, - `Response:` + repeatedStringForResponse + `,`, - `Request:` + repeatedStringForRequest + `,`, - `}`, - }, "") - return s -} -func (this *RouteHTTPHeaders) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&RouteHTTPHeaders{`, - `Actions:` + strings.Replace(strings.Replace(this.Actions.String(), "RouteHTTPHeaderActions", "RouteHTTPHeaderActions", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} func (this *RouteIngress) String() string { if this == nil { return "nil" @@ -1759,16 +1272,6 @@ func (this *RoutePort) String() string { }, "") return s } -func (this *RouteSetHTTPHeader) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&RouteSetHTTPHeader{`, - `Value:` + fmt.Sprintf("%v", this.Value) + `,`, - `}`, - }, "") - return s -} func (this *RouteSpec) String() string { if this == nil { return "nil" @@ -1787,7 +1290,6 @@ func (this *RouteSpec) String() string { `TLS:` + strings.Replace(this.TLS.String(), "TLSConfig", "TLSConfig", 1) + `,`, `WildcardPolicy:` + fmt.Sprintf("%v", this.WildcardPolicy) + `,`, `Subdomain:` + fmt.Sprintf("%v", this.Subdomain) + `,`, - `HTTPHeaders:` + strings.Replace(this.HTTPHeaders.String(), "RouteHTTPHeaders", "RouteHTTPHeaders", 1) + `,`, `}`, }, "") return s @@ -1803,404 +1305,58 @@ func (this *RouteStatus) String() string { repeatedStringForIngress += "}" s := strings.Join([]string{`&RouteStatus{`, `Ingress:` + repeatedStringForIngress + `,`, - `}`, - }, "") - return s -} -func (this *RouteTargetReference) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&RouteTargetReference{`, - `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, - `Name:` + fmt.Sprintf("%v", this.Name) + `,`, - `Weight:` + valueToStringGenerated(this.Weight) + `,`, - `}`, - }, "") - return s -} -func (this *RouterShard) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&RouterShard{`, - `ShardName:` + fmt.Sprintf("%v", this.ShardName) + `,`, - `DNSSuffix:` + fmt.Sprintf("%v", this.DNSSuffix) + `,`, - `}`, - }, "") - return s -} -func (this *TLSConfig) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&TLSConfig{`, - `Termination:` + fmt.Sprintf("%v", this.Termination) + `,`, - `Certificate:` + fmt.Sprintf("%v", this.Certificate) + `,`, - `Key:` + fmt.Sprintf("%v", this.Key) + `,`, - `CACertificate:` + fmt.Sprintf("%v", this.CACertificate) + `,`, - `DestinationCACertificate:` + fmt.Sprintf("%v", this.DestinationCACertificate) + `,`, - `InsecureEdgeTerminationPolicy:` + fmt.Sprintf("%v", this.InsecureEdgeTerminationPolicy) + `,`, - `ExternalCertificate:` + strings.Replace(this.ExternalCertificate.String(), "LocalObjectReference", "LocalObjectReference", 1) + `,`, - `}`, - }, "") - return s -} -func valueToStringGenerated(v interface{}) string { - rv := reflect.ValueOf(v) - if rv.IsNil() { - return "nil" - } - pv := reflect.Indirect(rv).Interface() - return fmt.Sprintf("*%v", pv) -} -func (m *LocalObjectReference) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: LocalObjectReference: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: LocalObjectReference: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Name = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *Route) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: Route: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Route: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *RouteHTTPHeader) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: RouteHTTPHeader: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: RouteHTTPHeader: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Name = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Action", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Action.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } + `}`, + }, "") + return s +} +func (this *RouteTargetReference) String() string { + if this == nil { + return "nil" } - - if iNdEx > l { - return io.ErrUnexpectedEOF + s := strings.Join([]string{`&RouteTargetReference{`, + `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `Weight:` + valueToStringGenerated(this.Weight) + `,`, + `}`, + }, "") + return s +} +func (this *RouterShard) String() string { + if this == nil { + return "nil" } - return nil + s := strings.Join([]string{`&RouterShard{`, + `ShardName:` + fmt.Sprintf("%v", this.ShardName) + `,`, + `DNSSuffix:` + fmt.Sprintf("%v", this.DNSSuffix) + `,`, + `}`, + }, "") + return s +} +func (this *TLSConfig) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&TLSConfig{`, + `Termination:` + fmt.Sprintf("%v", this.Termination) + `,`, + `Certificate:` + fmt.Sprintf("%v", this.Certificate) + `,`, + `Key:` + fmt.Sprintf("%v", this.Key) + `,`, + `CACertificate:` + fmt.Sprintf("%v", this.CACertificate) + `,`, + `DestinationCACertificate:` + fmt.Sprintf("%v", this.DestinationCACertificate) + `,`, + `InsecureEdgeTerminationPolicy:` + fmt.Sprintf("%v", this.InsecureEdgeTerminationPolicy) + `,`, + `ExternalCertificate:` + strings.Replace(this.ExternalCertificate.String(), "LocalObjectReference", "LocalObjectReference", 1) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) } -func (m *RouteHTTPHeaderActionUnion) Unmarshal(dAtA []byte) error { +func (m *LocalObjectReference) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -2223,15 +1379,15 @@ func (m *RouteHTTPHeaderActionUnion) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: RouteHTTPHeaderActionUnion: wiretype end group for non-group") + return fmt.Errorf("proto: LocalObjectReference: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: RouteHTTPHeaderActionUnion: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: LocalObjectReference: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -2259,43 +1415,7 @@ func (m *RouteHTTPHeaderActionUnion) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = RouteHTTPHeaderActionType(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Set", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Set == nil { - m.Set = &RouteSetHTTPHeader{} - } - if err := m.Set.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -2318,7 +1438,7 @@ func (m *RouteHTTPHeaderActionUnion) Unmarshal(dAtA []byte) error { } return nil } -func (m *RouteHTTPHeaderActions) Unmarshal(dAtA []byte) error { +func (m *Route) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -2341,15 +1461,15 @@ func (m *RouteHTTPHeaderActions) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: RouteHTTPHeaderActions: wiretype end group for non-group") + return fmt.Errorf("proto: Route: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: RouteHTTPHeaderActions: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: Route: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Response", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -2376,14 +1496,13 @@ func (m *RouteHTTPHeaderActions) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Response = append(m.Response, RouteHTTPHeader{}) - if err := m.Response[len(m.Response)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Request", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -2410,64 +1529,13 @@ func (m *RouteHTTPHeaderActions) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Request = append(m.Request, RouteHTTPHeader{}) - if err := m.Request[len(m.Request)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *RouteHTTPHeaders) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: RouteHTTPHeaders: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: RouteHTTPHeaders: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Actions", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -2494,7 +1562,7 @@ func (m *RouteHTTPHeaders) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Actions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -3145,88 +2213,6 @@ func (m *RoutePort) Unmarshal(dAtA []byte) error { } return nil } -func (m *RouteSetHTTPHeader) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: RouteSetHTTPHeader: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: RouteSetHTTPHeader: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Value = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} func (m *RouteSpec) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 @@ -3523,42 +2509,6 @@ func (m *RouteSpec) Unmarshal(dAtA []byte) error { } m.Subdomain = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 9: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field HTTPHeaders", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.HTTPHeaders == nil { - m.HTTPHeaders = &RouteHTTPHeaders{} - } - if err := m.HTTPHeaders.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) diff --git a/vendor/github.com/openshift/api/route/v1/generated.proto b/vendor/github.com/openshift/api/route/v1/generated.proto index bec5208c57..93d78bf19e 100644 --- a/vendor/github.com/openshift/api/route/v1/generated.proto +++ b/vendor/github.com/openshift/api/route/v1/generated.proto @@ -57,7 +57,6 @@ message Route { optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // spec is the desired state of the route - // +kubebuilder:validation:XValidation:rule="!has(self.tls) || self.tls.termination != 'passthrough' || !has(self.httpHeaders)",message="header actions are not permitted when tls termination is passthrough." optional RouteSpec spec = 2; // status is the current state of the route @@ -65,131 +64,6 @@ message Route { optional RouteStatus status = 3; } -// RouteHTTPHeader specifies configuration for setting or deleting an HTTP header. -message RouteHTTPHeader { - // name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header - // name as defined in RFC 2616 section 4.2. - // The name must consist only of alphanumeric and the following special characters, "-!#$%&'*+.^_`". - // The following header names are reserved and may not be modified via this API: - // Strict-Transport-Security, Proxy, Cookie, Set-Cookie. - // It must be no more than 1024 characters in length. - // Header name must be unique. - // +kubebuilder:validation:Required - // +kubebuilder:validation:MinLength=1 - // +kubebuilder:validation:MaxLength=1024 - // +kubebuilder:validation:Pattern="^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$" - // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'strict-transport-security'",message="strict-transport-security header may not be modified via header actions" - // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'proxy'",message="proxy header may not be modified via header actions" - // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'cookie'",message="cookie header may not be modified via header actions" - // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'set-cookie'",message="set-cookie header may not be modified via header actions" - optional string name = 1; - - // action specifies actions to perform on headers, such as setting or deleting headers. - // +kubebuilder:validation:Required - optional RouteHTTPHeaderActionUnion action = 2; -} - -// RouteHTTPHeaderActionUnion specifies an action to take on an HTTP header. -// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'Set' ? has(self.set) : !has(self.set)",message="set is required when type is Set, and forbidden otherwise" -// +union -message RouteHTTPHeaderActionUnion { - // type defines the type of the action to be applied on the header. - // Possible values are Set or Delete. - // Set allows you to set HTTP request and response headers. - // Delete allows you to delete HTTP request and response headers. - // +unionDiscriminator - // +kubebuilder:validation:Enum:=Set;Delete - // +kubebuilder:validation:Required - optional string type = 1; - - // set defines the HTTP header that should be set: added if it doesn't exist or replaced if it does. - // This field is required when type is Set and forbidden otherwise. - // +optional - // +unionMember - optional RouteSetHTTPHeader set = 2; -} - -// RouteHTTPHeaderActions defines configuration for actions on HTTP request and response headers. -message RouteHTTPHeaderActions { - // response is a list of HTTP response headers to modify. - // Currently, actions may define to either `Set` or `Delete` headers values. - // Actions defined here will modify the response headers of all requests made through a route. - // These actions are applied to a specific Route defined within a cluster i.e. connections made through a route. - // Route actions will be executed before IngressController actions for response headers. - // Actions are applied in sequence as defined in this list. - // A maximum of 20 response header actions may be configured. - // You can use this field to specify HTTP response headers that should be set or deleted - // when forwarding responses from your application to the client. - // Sample fetchers allowed are "res.hdr" and "ssl_c_der". - // Converters allowed are "lower" and "base64". - // Example header values: "%[res.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]". - // Note: This field cannot be used if your route uses TLS passthrough. - // + --- - // + Note: Any change to regex mentioned below must be reflected in the CRD validation of route in https://github.com/openshift/library-go/blob/master/pkg/route/validation/validation.go and vice-versa. - // +listType=map - // +listMapKey=name - // +optional - // +kubebuilder:validation:MaxItems=20 - // +kubebuilder:validation:XValidation:rule=`self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:res\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$')))`,message="Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64." - repeated RouteHTTPHeader response = 1; - - // request is a list of HTTP request headers to modify. - // Currently, actions may define to either `Set` or `Delete` headers values. - // Actions defined here will modify the request headers of all requests made through a route. - // These actions are applied to a specific Route defined within a cluster i.e. connections made through a route. - // Currently, actions may define to either `Set` or `Delete` headers values. - // Route actions will be executed after IngressController actions for request headers. - // Actions are applied in sequence as defined in this list. - // A maximum of 20 request header actions may be configured. - // You can use this field to specify HTTP request headers that should be set or deleted - // when forwarding connections from the client to your application. - // Sample fetchers allowed are "req.hdr" and "ssl_c_der". - // Converters allowed are "lower" and "base64". - // Example header values: "%[req.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]". - // Any request header configuration applied directly via a Route resource using this API - // will override header configuration for a header of the same name applied via - // spec.httpHeaders.actions on the IngressController or route annotation. - // Note: This field cannot be used if your route uses TLS passthrough. - // + --- - // + Note: Any change to regex mentioned below must be reflected in the CRD validation of route in https://github.com/openshift/library-go/blob/master/pkg/route/validation/validation.go and vice-versa. - // +listType=map - // +listMapKey=name - // +optional - // +kubebuilder:validation:MaxItems=20 - // +kubebuilder:validation:XValidation:rule=`self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:req\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$')))`,message="Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64." - repeated RouteHTTPHeader request = 2; -} - -// RouteHTTPHeaders defines policy for HTTP headers. -message RouteHTTPHeaders { - // actions specifies options for modifying headers and their values. - // Note that this option only applies to cleartext HTTP connections - // and to secure HTTP connections for which the ingress controller - // terminates encryption (that is, edge-terminated or reencrypt - // connections). Headers cannot be modified for TLS passthrough - // connections. - // Setting the HSTS (`Strict-Transport-Security`) header is not supported via actions. - // `Strict-Transport-Security` may only be configured using the "haproxy.router.openshift.io/hsts_header" - // route annotation, and only in accordance with the policy specified in Ingress.Spec.RequiredHSTSPolicies. - // In case of HTTP request headers, the actions specified in spec.httpHeaders.actions on the Route will be executed after - // the actions specified in the IngressController's spec.httpHeaders.actions field. - // In case of HTTP response headers, the actions specified in spec.httpHeaders.actions on the IngressController will be - // executed after the actions specified in the Route's spec.httpHeaders.actions field. - // The headers set via this API will not appear in access logs. - // Any actions defined here are applied after any actions related to the following other fields: - // cache-control, spec.clientTLS, - // spec.httpHeaders.forwardedHeaderPolicy, spec.httpHeaders.uniqueId, - // and spec.httpHeaders.headerNameCaseAdjustments. - // The following header names are reserved and may not be modified via this API: - // Strict-Transport-Security, Proxy, Cookie, Set-Cookie. - // Note that the total size of all net added headers *after* interpolating dynamic values - // must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the - // IngressController. Please refer to the documentation - // for that API field for more details. - // +optional - optional RouteHTTPHeaderActions actions = 1; -} - // RouteIngress holds information about the places where a route is exposed. message RouteIngress { // Host is the host string under which the route is exposed; this value is required @@ -252,25 +126,6 @@ message RoutePort { optional k8s.io.apimachinery.pkg.util.intstr.IntOrString targetPort = 1; } -// RouteSetHTTPHeader specifies what value needs to be set on an HTTP header. -message RouteSetHTTPHeader { - // value specifies a header value. - // Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in - // http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and - // otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. - // The value of this field must be no more than 16384 characters in length. - // Note that the total size of all net added headers *after* interpolating dynamic values - // must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the - // IngressController. - // + --- - // + Note: This limit was selected as most common web servers have a limit of 16384 characters or some lower limit. - // + See . - // +kubebuilder:validation:Required - // +kubebuilder:validation:MinLength=1 - // +kubebuilder:validation:MaxLength=16384 - optional string value = 1; -} - // RouteSpec describes the hostname or path the route exposes, any security information, // and one to four backends (services) the route points to. Requests are distributed // among the backends depending on the weights assigned to each backend. When using @@ -347,11 +202,6 @@ message RouteSpec { // +kubebuilder:validation:Enum=None;Subdomain;"" // +kubebuilder:default=None optional string wildcardPolicy = 7; - - // httpHeaders defines policy for HTTP headers. - // - // +optional - optional RouteHTTPHeaders httpHeaders = 9; } // RouteStatus provides relevant info about the status of a route, including which routers @@ -412,7 +262,6 @@ message TLSConfig { // * passthrough - Traffic is sent straight to the destination without the router providing TLS termination // * reencrypt - TLS termination is done by the router and https is used to communicate with the backend // - // Note: passthrough termination is incompatible with httpHeader actions // +kubebuilder:validation:Enum=edge;reencrypt;passthrough optional string termination = 1; diff --git a/vendor/github.com/openshift/api/route/v1/route-CustomNoUpgrade.crd.yaml b/vendor/github.com/openshift/api/route/v1/route-CustomNoUpgrade.crd.yaml index 5c0f9c75ab..360d60053b 100644 --- a/vendor/github.com/openshift/api/route/v1/route-CustomNoUpgrade.crd.yaml +++ b/vendor/github.com/openshift/api/route/v1/route-CustomNoUpgrade.crd.yaml @@ -82,130 +82,6 @@ spec: type: string maxLength: 253 pattern: ^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])(\.([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9]))*$ - httpHeaders: - description: httpHeaders defines policy for HTTP headers. - type: object - properties: - actions: - description: 'actions specifies options for modifying headers and their values. Note that this option only applies to cleartext HTTP connections and to secure HTTP connections for which the ingress controller terminates encryption (that is, edge-terminated or reencrypt connections). Headers cannot be modified for TLS passthrough connections. Setting the HSTS (`Strict-Transport-Security`) header is not supported via actions. `Strict-Transport-Security` may only be configured using the "haproxy.router.openshift.io/hsts_header" route annotation, and only in accordance with the policy specified in Ingress.Spec.RequiredHSTSPolicies. In case of HTTP request headers, the actions specified in spec.httpHeaders.actions on the Route will be executed after the actions specified in the IngressController''s spec.httpHeaders.actions field. In case of HTTP response headers, the actions specified in spec.httpHeaders.actions on the IngressController will be executed after the actions specified in the Route''s spec.httpHeaders.actions field. The headers set via this API will not appear in access logs. Any actions defined here are applied after any actions related to the following other fields: cache-control, spec.clientTLS, spec.httpHeaders.forwardedHeaderPolicy, spec.httpHeaders.uniqueId, and spec.httpHeaders.headerNameCaseAdjustments. The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Cookie, Set-Cookie. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. Please refer to the documentation for that API field for more details.' - type: object - properties: - request: - description: 'request is a list of HTTP request headers to modify. Currently, actions may define to either `Set` or `Delete` headers values. Actions defined here will modify the request headers of all requests made through a route. These actions are applied to a specific Route defined within a cluster i.e. connections made through a route. Currently, actions may define to either `Set` or `Delete` headers values. Route actions will be executed after IngressController actions for request headers. Actions are applied in sequence as defined in this list. A maximum of 20 request header actions may be configured. You can use this field to specify HTTP request headers that should be set or deleted when forwarding connections from the client to your application. Sample fetchers allowed are "req.hdr" and "ssl_c_der". Converters allowed are "lower" and "base64". Example header values: "%[req.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]". Any request header configuration applied directly via a Route resource using this API will override header configuration for a header of the same name applied via spec.httpHeaders.actions on the IngressController or route annotation. Note: This field cannot be used if your route uses TLS passthrough.' - type: array - maxItems: 20 - items: - description: RouteHTTPHeader specifies configuration for setting or deleting an HTTP header. - type: object - required: - - action - - name - properties: - action: - description: action specifies actions to perform on headers, such as setting or deleting headers. - type: object - required: - - type - properties: - set: - description: 'set defines the HTTP header that should be set: added if it doesn''t exist or replaced if it does. This field is required when type is Set and forbidden otherwise.' - type: object - required: - - value - properties: - value: - description: value specifies a header value. Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. The value of this field must be no more than 16384 characters in length. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. - type: string - maxLength: 16384 - minLength: 1 - type: - description: type defines the type of the action to be applied on the header. Possible values are Set or Delete. Set allows you to set HTTP request and response headers. Delete allows you to delete HTTP request and response headers. - type: string - enum: - - Set - - Delete - x-kubernetes-validations: - - rule: 'has(self.type) && self.type == ''Set'' ? has(self.set) : !has(self.set)' - message: set is required when type is Set, and forbidden otherwise - name: - description: 'name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header name as defined in RFC 2616 section 4.2. The name must consist only of alphanumeric and the following special characters, "-!#$%&''*+.^_`". The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Cookie, Set-Cookie. It must be no more than 1024 characters in length. Header name must be unique.' - type: string - maxLength: 1024 - minLength: 1 - pattern: ^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$ - x-kubernetes-validations: - - rule: self.lowerAscii() != 'strict-transport-security' - message: strict-transport-security header may not be modified via header actions - - rule: self.lowerAscii() != 'proxy' - message: proxy header may not be modified via header actions - - rule: self.lowerAscii() != 'cookie' - message: cookie header may not be modified via header actions - - rule: self.lowerAscii() != 'set-cookie' - message: set-cookie header may not be modified via header actions - x-kubernetes-list-map-keys: - - name - x-kubernetes-list-type: map - x-kubernetes-validations: - - rule: self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:req\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$'))) - message: Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64. - response: - description: 'response is a list of HTTP response headers to modify. Currently, actions may define to either `Set` or `Delete` headers values. Actions defined here will modify the response headers of all requests made through a route. These actions are applied to a specific Route defined within a cluster i.e. connections made through a route. Route actions will be executed before IngressController actions for response headers. Actions are applied in sequence as defined in this list. A maximum of 20 response header actions may be configured. You can use this field to specify HTTP response headers that should be set or deleted when forwarding responses from your application to the client. Sample fetchers allowed are "res.hdr" and "ssl_c_der". Converters allowed are "lower" and "base64". Example header values: "%[res.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]". Note: This field cannot be used if your route uses TLS passthrough.' - type: array - maxItems: 20 - items: - description: RouteHTTPHeader specifies configuration for setting or deleting an HTTP header. - type: object - required: - - action - - name - properties: - action: - description: action specifies actions to perform on headers, such as setting or deleting headers. - type: object - required: - - type - properties: - set: - description: 'set defines the HTTP header that should be set: added if it doesn''t exist or replaced if it does. This field is required when type is Set and forbidden otherwise.' - type: object - required: - - value - properties: - value: - description: value specifies a header value. Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. The value of this field must be no more than 16384 characters in length. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. - type: string - maxLength: 16384 - minLength: 1 - type: - description: type defines the type of the action to be applied on the header. Possible values are Set or Delete. Set allows you to set HTTP request and response headers. Delete allows you to delete HTTP request and response headers. - type: string - enum: - - Set - - Delete - x-kubernetes-validations: - - rule: 'has(self.type) && self.type == ''Set'' ? has(self.set) : !has(self.set)' - message: set is required when type is Set, and forbidden otherwise - name: - description: 'name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header name as defined in RFC 2616 section 4.2. The name must consist only of alphanumeric and the following special characters, "-!#$%&''*+.^_`". The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Cookie, Set-Cookie. It must be no more than 1024 characters in length. Header name must be unique.' - type: string - maxLength: 1024 - minLength: 1 - pattern: ^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$ - x-kubernetes-validations: - - rule: self.lowerAscii() != 'strict-transport-security' - message: strict-transport-security header may not be modified via header actions - - rule: self.lowerAscii() != 'proxy' - message: proxy header may not be modified via header actions - - rule: self.lowerAscii() != 'cookie' - message: cookie header may not be modified via header actions - - rule: self.lowerAscii() != 'set-cookie' - message: set-cookie header may not be modified via header actions - x-kubernetes-list-map-keys: - - name - x-kubernetes-list-type: map - x-kubernetes-validations: - - rule: self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:res\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$'))) - message: Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64. path: description: path that the router watches for, to route traffic for to the service. Optional type: string @@ -262,7 +138,7 @@ spec: description: key provides key file contents type: string termination: - description: "termination indicates termination type. \n * edge - TLS termination is done by the router and http is used to communicate with the backend (default) * passthrough - Traffic is sent straight to the destination without the router providing TLS termination * reencrypt - TLS termination is done by the router and https is used to communicate with the backend \n Note: passthrough termination is incompatible with httpHeader actions" + description: "termination indicates termination type. \n * edge - TLS termination is done by the router and http is used to communicate with the backend (default) * passthrough - Traffic is sent straight to the destination without the router providing TLS termination * reencrypt - TLS termination is done by the router and https is used to communicate with the backend" type: string enum: - edge @@ -306,9 +182,6 @@ spec: - None - Subdomain - "" - x-kubernetes-validations: - - rule: '!has(self.tls) || self.tls.termination != ''passthrough'' || !has(self.httpHeaders)' - message: header actions are not permitted when tls termination is passthrough. status: description: status is the current state of the route type: object diff --git a/vendor/github.com/openshift/api/route/v1/route-TechPreviewNoUpgrade.crd.yaml b/vendor/github.com/openshift/api/route/v1/route-TechPreviewNoUpgrade.crd.yaml index cc7533fee4..fd6678f44d 100644 --- a/vendor/github.com/openshift/api/route/v1/route-TechPreviewNoUpgrade.crd.yaml +++ b/vendor/github.com/openshift/api/route/v1/route-TechPreviewNoUpgrade.crd.yaml @@ -82,130 +82,6 @@ spec: type: string maxLength: 253 pattern: ^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])(\.([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9]))*$ - httpHeaders: - description: httpHeaders defines policy for HTTP headers. - type: object - properties: - actions: - description: 'actions specifies options for modifying headers and their values. Note that this option only applies to cleartext HTTP connections and to secure HTTP connections for which the ingress controller terminates encryption (that is, edge-terminated or reencrypt connections). Headers cannot be modified for TLS passthrough connections. Setting the HSTS (`Strict-Transport-Security`) header is not supported via actions. `Strict-Transport-Security` may only be configured using the "haproxy.router.openshift.io/hsts_header" route annotation, and only in accordance with the policy specified in Ingress.Spec.RequiredHSTSPolicies. In case of HTTP request headers, the actions specified in spec.httpHeaders.actions on the Route will be executed after the actions specified in the IngressController''s spec.httpHeaders.actions field. In case of HTTP response headers, the actions specified in spec.httpHeaders.actions on the IngressController will be executed after the actions specified in the Route''s spec.httpHeaders.actions field. The headers set via this API will not appear in access logs. Any actions defined here are applied after any actions related to the following other fields: cache-control, spec.clientTLS, spec.httpHeaders.forwardedHeaderPolicy, spec.httpHeaders.uniqueId, and spec.httpHeaders.headerNameCaseAdjustments. The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Cookie, Set-Cookie. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. Please refer to the documentation for that API field for more details.' - type: object - properties: - request: - description: 'request is a list of HTTP request headers to modify. Currently, actions may define to either `Set` or `Delete` headers values. Actions defined here will modify the request headers of all requests made through a route. These actions are applied to a specific Route defined within a cluster i.e. connections made through a route. Currently, actions may define to either `Set` or `Delete` headers values. Route actions will be executed after IngressController actions for request headers. Actions are applied in sequence as defined in this list. A maximum of 20 request header actions may be configured. You can use this field to specify HTTP request headers that should be set or deleted when forwarding connections from the client to your application. Sample fetchers allowed are "req.hdr" and "ssl_c_der". Converters allowed are "lower" and "base64". Example header values: "%[req.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]". Any request header configuration applied directly via a Route resource using this API will override header configuration for a header of the same name applied via spec.httpHeaders.actions on the IngressController or route annotation. Note: This field cannot be used if your route uses TLS passthrough.' - type: array - maxItems: 20 - items: - description: RouteHTTPHeader specifies configuration for setting or deleting an HTTP header. - type: object - required: - - action - - name - properties: - action: - description: action specifies actions to perform on headers, such as setting or deleting headers. - type: object - required: - - type - properties: - set: - description: 'set defines the HTTP header that should be set: added if it doesn''t exist or replaced if it does. This field is required when type is Set and forbidden otherwise.' - type: object - required: - - value - properties: - value: - description: value specifies a header value. Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. The value of this field must be no more than 16384 characters in length. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. - type: string - maxLength: 16384 - minLength: 1 - type: - description: type defines the type of the action to be applied on the header. Possible values are Set or Delete. Set allows you to set HTTP request and response headers. Delete allows you to delete HTTP request and response headers. - type: string - enum: - - Set - - Delete - x-kubernetes-validations: - - rule: 'has(self.type) && self.type == ''Set'' ? has(self.set) : !has(self.set)' - message: set is required when type is Set, and forbidden otherwise - name: - description: 'name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header name as defined in RFC 2616 section 4.2. The name must consist only of alphanumeric and the following special characters, "-!#$%&''*+.^_`". The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Cookie, Set-Cookie. It must be no more than 1024 characters in length. Header name must be unique.' - type: string - maxLength: 1024 - minLength: 1 - pattern: ^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$ - x-kubernetes-validations: - - rule: self.lowerAscii() != 'strict-transport-security' - message: strict-transport-security header may not be modified via header actions - - rule: self.lowerAscii() != 'proxy' - message: proxy header may not be modified via header actions - - rule: self.lowerAscii() != 'cookie' - message: cookie header may not be modified via header actions - - rule: self.lowerAscii() != 'set-cookie' - message: set-cookie header may not be modified via header actions - x-kubernetes-list-map-keys: - - name - x-kubernetes-list-type: map - x-kubernetes-validations: - - rule: self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:req\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$'))) - message: Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64. - response: - description: 'response is a list of HTTP response headers to modify. Currently, actions may define to either `Set` or `Delete` headers values. Actions defined here will modify the response headers of all requests made through a route. These actions are applied to a specific Route defined within a cluster i.e. connections made through a route. Route actions will be executed before IngressController actions for response headers. Actions are applied in sequence as defined in this list. A maximum of 20 response header actions may be configured. You can use this field to specify HTTP response headers that should be set or deleted when forwarding responses from your application to the client. Sample fetchers allowed are "res.hdr" and "ssl_c_der". Converters allowed are "lower" and "base64". Example header values: "%[res.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]". Note: This field cannot be used if your route uses TLS passthrough.' - type: array - maxItems: 20 - items: - description: RouteHTTPHeader specifies configuration for setting or deleting an HTTP header. - type: object - required: - - action - - name - properties: - action: - description: action specifies actions to perform on headers, such as setting or deleting headers. - type: object - required: - - type - properties: - set: - description: 'set defines the HTTP header that should be set: added if it doesn''t exist or replaced if it does. This field is required when type is Set and forbidden otherwise.' - type: object - required: - - value - properties: - value: - description: value specifies a header value. Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. The value of this field must be no more than 16384 characters in length. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. - type: string - maxLength: 16384 - minLength: 1 - type: - description: type defines the type of the action to be applied on the header. Possible values are Set or Delete. Set allows you to set HTTP request and response headers. Delete allows you to delete HTTP request and response headers. - type: string - enum: - - Set - - Delete - x-kubernetes-validations: - - rule: 'has(self.type) && self.type == ''Set'' ? has(self.set) : !has(self.set)' - message: set is required when type is Set, and forbidden otherwise - name: - description: 'name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header name as defined in RFC 2616 section 4.2. The name must consist only of alphanumeric and the following special characters, "-!#$%&''*+.^_`". The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Cookie, Set-Cookie. It must be no more than 1024 characters in length. Header name must be unique.' - type: string - maxLength: 1024 - minLength: 1 - pattern: ^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$ - x-kubernetes-validations: - - rule: self.lowerAscii() != 'strict-transport-security' - message: strict-transport-security header may not be modified via header actions - - rule: self.lowerAscii() != 'proxy' - message: proxy header may not be modified via header actions - - rule: self.lowerAscii() != 'cookie' - message: cookie header may not be modified via header actions - - rule: self.lowerAscii() != 'set-cookie' - message: set-cookie header may not be modified via header actions - x-kubernetes-list-map-keys: - - name - x-kubernetes-list-type: map - x-kubernetes-validations: - - rule: self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:res\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$'))) - message: Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64. path: description: path that the router watches for, to route traffic for to the service. Optional type: string @@ -262,7 +138,7 @@ spec: description: key provides key file contents type: string termination: - description: "termination indicates termination type. \n * edge - TLS termination is done by the router and http is used to communicate with the backend (default) * passthrough - Traffic is sent straight to the destination without the router providing TLS termination * reencrypt - TLS termination is done by the router and https is used to communicate with the backend \n Note: passthrough termination is incompatible with httpHeader actions" + description: "termination indicates termination type. \n * edge - TLS termination is done by the router and http is used to communicate with the backend (default) * passthrough - Traffic is sent straight to the destination without the router providing TLS termination * reencrypt - TLS termination is done by the router and https is used to communicate with the backend" type: string enum: - edge @@ -306,9 +182,6 @@ spec: - None - Subdomain - "" - x-kubernetes-validations: - - rule: '!has(self.tls) || self.tls.termination != ''passthrough'' || !has(self.httpHeaders)' - message: header actions are not permitted when tls termination is passthrough. status: description: status is the current state of the route type: object diff --git a/vendor/github.com/openshift/api/route/v1/route.crd.yaml b/vendor/github.com/openshift/api/route/v1/route.crd.yaml index d3b169669d..d4a7dfcf83 100644 --- a/vendor/github.com/openshift/api/route/v1/route.crd.yaml +++ b/vendor/github.com/openshift/api/route/v1/route.crd.yaml @@ -101,130 +101,6 @@ spec: maxLength: 253 pattern: ^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])(\.([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]{0,61}[a-zA-Z0-9]))*$ type: string - httpHeaders: - description: httpHeaders defines policy for HTTP headers. - properties: - actions: - description: 'actions specifies options for modifying headers and their values. Note that this option only applies to cleartext HTTP connections and to secure HTTP connections for which the ingress controller terminates encryption (that is, edge-terminated or reencrypt connections). Headers cannot be modified for TLS passthrough connections. Setting the HSTS (`Strict-Transport-Security`) header is not supported via actions. `Strict-Transport-Security` may only be configured using the "haproxy.router.openshift.io/hsts_header" route annotation, and only in accordance with the policy specified in Ingress.Spec.RequiredHSTSPolicies. In case of HTTP request headers, the actions specified in spec.httpHeaders.actions on the Route will be executed after the actions specified in the IngressController''s spec.httpHeaders.actions field. In case of HTTP response headers, the actions specified in spec.httpHeaders.actions on the IngressController will be executed after the actions specified in the Route''s spec.httpHeaders.actions field. The headers set via this API will not appear in access logs. Any actions defined here are applied after any actions related to the following other fields: cache-control, spec.clientTLS, spec.httpHeaders.forwardedHeaderPolicy, spec.httpHeaders.uniqueId, and spec.httpHeaders.headerNameCaseAdjustments. The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Cookie, Set-Cookie. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. Please refer to the documentation for that API field for more details.' - properties: - request: - description: 'request is a list of HTTP request headers to modify. Currently, actions may define to either `Set` or `Delete` headers values. Actions defined here will modify the request headers of all requests made through a route. These actions are applied to a specific Route defined within a cluster i.e. connections made through a route. Currently, actions may define to either `Set` or `Delete` headers values. Route actions will be executed after IngressController actions for request headers. Actions are applied in sequence as defined in this list. A maximum of 20 request header actions may be configured. You can use this field to specify HTTP request headers that should be set or deleted when forwarding connections from the client to your application. Sample fetchers allowed are "req.hdr" and "ssl_c_der". Converters allowed are "lower" and "base64". Example header values: "%[req.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]". Any request header configuration applied directly via a Route resource using this API will override header configuration for a header of the same name applied via spec.httpHeaders.actions on the IngressController or route annotation. Note: This field cannot be used if your route uses TLS passthrough.' - items: - description: RouteHTTPHeader specifies configuration for setting or deleting an HTTP header. - properties: - action: - description: action specifies actions to perform on headers, such as setting or deleting headers. - properties: - set: - description: 'set defines the HTTP header that should be set: added if it doesn''t exist or replaced if it does. This field is required when type is Set and forbidden otherwise.' - properties: - value: - description: value specifies a header value. Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. The value of this field must be no more than 16384 characters in length. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. - maxLength: 16384 - minLength: 1 - type: string - required: - - value - type: object - type: - description: type defines the type of the action to be applied on the header. Possible values are Set or Delete. Set allows you to set HTTP request and response headers. Delete allows you to delete HTTP request and response headers. - enum: - - Set - - Delete - type: string - required: - - type - type: object - x-kubernetes-validations: - - message: set is required when type is Set, and forbidden otherwise - rule: 'has(self.type) && self.type == ''Set'' ? has(self.set) : !has(self.set)' - name: - description: 'name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header name as defined in RFC 2616 section 4.2. The name must consist only of alphanumeric and the following special characters, "-!#$%&''*+.^_`". The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Cookie, Set-Cookie. It must be no more than 1024 characters in length. Header name must be unique.' - maxLength: 1024 - minLength: 1 - pattern: ^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$ - type: string - x-kubernetes-validations: - - message: strict-transport-security header may not be modified via header actions - rule: self.lowerAscii() != 'strict-transport-security' - - message: proxy header may not be modified via header actions - rule: self.lowerAscii() != 'proxy' - - message: cookie header may not be modified via header actions - rule: self.lowerAscii() != 'cookie' - - message: set-cookie header may not be modified via header actions - rule: self.lowerAscii() != 'set-cookie' - required: - - action - - name - type: object - maxItems: 20 - type: array - x-kubernetes-list-map-keys: - - name - x-kubernetes-list-type: map - x-kubernetes-validations: - - message: Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64. - rule: self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:req\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$'))) - response: - description: 'response is a list of HTTP response headers to modify. Currently, actions may define to either `Set` or `Delete` headers values. Actions defined here will modify the response headers of all requests made through a route. These actions are applied to a specific Route defined within a cluster i.e. connections made through a route. Route actions will be executed before IngressController actions for response headers. Actions are applied in sequence as defined in this list. A maximum of 20 response header actions may be configured. You can use this field to specify HTTP response headers that should be set or deleted when forwarding responses from your application to the client. Sample fetchers allowed are "res.hdr" and "ssl_c_der". Converters allowed are "lower" and "base64". Example header values: "%[res.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]". Note: This field cannot be used if your route uses TLS passthrough.' - items: - description: RouteHTTPHeader specifies configuration for setting or deleting an HTTP header. - properties: - action: - description: action specifies actions to perform on headers, such as setting or deleting headers. - properties: - set: - description: 'set defines the HTTP header that should be set: added if it doesn''t exist or replaced if it does. This field is required when type is Set and forbidden otherwise.' - properties: - value: - description: value specifies a header value. Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. The value of this field must be no more than 16384 characters in length. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. - maxLength: 16384 - minLength: 1 - type: string - required: - - value - type: object - type: - description: type defines the type of the action to be applied on the header. Possible values are Set or Delete. Set allows you to set HTTP request and response headers. Delete allows you to delete HTTP request and response headers. - enum: - - Set - - Delete - type: string - required: - - type - type: object - x-kubernetes-validations: - - message: set is required when type is Set, and forbidden otherwise - rule: 'has(self.type) && self.type == ''Set'' ? has(self.set) : !has(self.set)' - name: - description: 'name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header name as defined in RFC 2616 section 4.2. The name must consist only of alphanumeric and the following special characters, "-!#$%&''*+.^_`". The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Cookie, Set-Cookie. It must be no more than 1024 characters in length. Header name must be unique.' - maxLength: 1024 - minLength: 1 - pattern: ^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$ - type: string - x-kubernetes-validations: - - message: strict-transport-security header may not be modified via header actions - rule: self.lowerAscii() != 'strict-transport-security' - - message: proxy header may not be modified via header actions - rule: self.lowerAscii() != 'proxy' - - message: cookie header may not be modified via header actions - rule: self.lowerAscii() != 'cookie' - - message: set-cookie header may not be modified via header actions - rule: self.lowerAscii() != 'set-cookie' - required: - - action - - name - type: object - maxItems: 20 - type: array - x-kubernetes-list-map-keys: - - name - x-kubernetes-list-type: map - x-kubernetes-validations: - - message: Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64. - rule: self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:res\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$'))) - type: object - type: object path: description: path that the router watches for, to route traffic for to the service. Optional pattern: ^/ @@ -298,7 +174,7 @@ spec: description: key provides key file contents type: string termination: - description: "termination indicates termination type. \n * edge - TLS termination is done by the router and http is used to communicate with the backend (default) * passthrough - Traffic is sent straight to the destination without the router providing TLS termination * reencrypt - TLS termination is done by the router and https is used to communicate with the backend \n Note: passthrough termination is incompatible with httpHeader actions" + description: "termination indicates termination type. \n * edge - TLS termination is done by the router and http is used to communicate with the backend (default) * passthrough - Traffic is sent straight to the destination without the router providing TLS termination * reencrypt - TLS termination is done by the router and https is used to communicate with the backend" enum: - edge - reencrypt @@ -346,9 +222,6 @@ spec: required: - to type: object - x-kubernetes-validations: - - message: header actions are not permitted when tls termination is passthrough. - rule: '!has(self.tls) || self.tls.termination != ''passthrough'' || !has(self.httpHeaders)' status: description: status is the current state of the route properties: diff --git a/vendor/github.com/openshift/api/route/v1/stable.route.testsuite.yaml b/vendor/github.com/openshift/api/route/v1/stable.route.testsuite.yaml index d1e4766735..0031afdb5b 100644 --- a/vendor/github.com/openshift/api/route/v1/stable.route.testsuite.yaml +++ b/vendor/github.com/openshift/api/route/v1/stable.route.testsuite.yaml @@ -82,594 +82,3 @@ tests: termination: passthrough insecureEdgeTerminationPolicy: None wildcardPolicy: None - - name: Should be able to create a Route with valid actions - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-actions - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - set: - value: DENY - - name: X-Cache-Info - action: - type: Set - set: - value: "not cacheable; meta data too large" - - name: X-XSS-Protection - action: - type: Delete - - name: X-Source - action: - type: Set - set: - value: "%[res.hdr(X-Value),lower]" - request: - - name: Content-Location - action: - type: Set - set: - value: /my-first-blog-post - - name: X-SSL-Client-Cert - action: - type: Set - set: - value: "%{+Q}[ssl_c_der,base64]" - - name: Content-Language - action: - type: Delete - - name: X-Target - action: - type: Set - set: - value: "%[req.hdr(host),lower]" - - name: X-Conditional - action: - type: Set - set: - value: "%[req.hdr(Host)] if foo" - - name: X-Condition - action: - type: Set - set: - value: "%[req.hdr(Host)]\ if\ foo" - expected: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-actions - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - weight: 100 - wildcardPolicy: None - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - set: - value: DENY - - name: X-Cache-Info - action: - type: Set - set: - value: "not cacheable; meta data too large" - - name: X-XSS-Protection - action: - type: Delete - - name: X-Source - action: - type: Set - set: - value: "%[res.hdr(X-Value),lower]" - request: - - name: Content-Location - action: - type: Set - set: - value: /my-first-blog-post - - name: X-SSL-Client-Cert - action: - type: Set - set: - value: "%{+Q}[ssl_c_der,base64]" - - name: Content-Language - action: - type: Delete - - name: X-Target - action: - type: Set - set: - value: "%[req.hdr(host),lower]" - - name: X-Conditional - action: - type: Set - set: - value: "%[req.hdr(Host)] if foo" - - name: X-Condition - action: - type: Set - set: - value: "%[req.hdr(Host)]\ if\ foo" - - name: "Should not allow response header actions if tls termination is set to passthrough" - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-passthrough - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: passthrough - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - set: - value: DENY - - name: X-XSS-Protection - action: - type: Delete - expectedError: "header actions are not permitted when tls termination is passthrough." - - name: "Should not allow request header actions if tls termination is set to passthrough" - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-passthrough - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: passthrough - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - request: - - name: Content-Location - action: - type: Set - set: - value: /my-first-blog-post - - name: X-SSL-Client-Cert - action: - type: Set - set: - value: "%{+Q}[ssl_c_der,base64]" - - name: Content-Language - action: - type: Delete - - name: X-Target - action: - type: Set - set: - value: "%[req.hdr(host),lower]" - expectedError: "header actions are not permitted when tls termination is passthrough." - - name: Should not allow to set/delete HSTS header. - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-edge-hsts - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - set: - value: DENY - - name: Strict-Transport-Security - action: - type: Delete - request: - - name: Content-Location - action: - type: Set - set: - value: /my-first-blog-post - - name: Content-Language - action: - type: Delete - expectedError: "strict-transport-security header may not be modified via header actions" - - name: Should not allow to set proxy request header. - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - name: hello-openshift-edge-proxy - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - request: - - name: Proxy - action: - type: Set - set: - value: example.xyz - expectedError: "proxy header may not be modified via header actions" - - name: Should not allow to set cookie header. - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - name: hello-openshift-edge-proxy - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - request: - - name: Cookie - action: - type: Set - set: - value: "PHPSESSID=298zf09hf012fh2; csrftoken=u32t4o3tb3gg43; _gat=1" - expectedError: "cookie header may not be modified via header actions" - - name: Should not allow to set set-cookie header. - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - name: hello-openshift-edge-proxy - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - response: - - name: Set-Cookie - action: - type: Set - set: - value: "sessionId=e8bb43229de9; Domain=foo.example.com" - expectedError: "set-cookie header may not be modified via header actions" - - name: Should not allow to set/delete dynamic headers with unclosed braces. - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-edge-unclosed-braces - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - request: - - name: Content-Location - action: - type: Set - set: - value: /my-first-blog-post - - name: Content-Language - action: - type: Delete - - name: expires - action: - type: Set - set: - value: "%[req.hdr(host),lower" - expectedError: "Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64." - - name: Should not allow to set dynamic response header values with not allowed sample fetchers. - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-edge-not-allowed-values - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - response: - - name: X-Target - action: - type: Set - set: - value: "%{+Q}[ssl_c_der1,base64]" - expectedError: "Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64." - - name: Should not allow to set/delete dynamic response header values with not allowed converters. - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-edge-not-allowed-values - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - response: - - name: X-Target - action: - type: Set - set: - value: "%{+Q}[ssl_c_der,bogus]" - expectedError: "Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64." - - name: Should not allow to set/delete dynamic response header values containing req.hdr fetcher. - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-edge-not-allowed-values - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - response: - - name: X-Target - action: - type: Set - set: - value: "%[req.hdr(host),lower]" - expectedError: "Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64." - - name: Should not allow to set/delete dynamic response header values containing req.hdr fetcher. - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-edge-not-allowed-values - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - request: - - name: X-Source - action: - type: Set - set: - value: "%[res.hdr(X-Value),lower]" - expectedError: "Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64." - - name: Should not allow to set/delete dynamic request header values with not allowed converters. - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-edge-not-allowed-values - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - request: - - name: X-SSL-Client-Cert - action: - type: Set - set: - value: "%{+Q}[ssl_c_der,bogus]" - - name: Content-Language - action: - type: Delete - expectedError: "Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64." - - name: Should not allow to set dynamic request header values with not allowed sample fetchers. - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-edge-not-allowed-values - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - request: - - name: X-SSL-Client-Cert - action: - type: Set - set: - value: "%{+Q}[ssl_c_der1122,base64]" - - name: Content-Language - action: - type: Delete - expectedError: "Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64." - - name: Should not allow empty value in request - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-edge-not-allowed-values - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - request: - - name: X-SSL-Client-Cert - action: - type: Set - set: - value: - expectedError: 'Route.route.openshift.io "hello-openshift-edge-not-allowed-values" is invalid: [spec.httpHeaders.actions.request[0].action.set.value: Required value, : Invalid value: "null": some validation rules were not checked because the object was invalid; correct the existing errors to complete validation]' - - name: Should not allow empty value in response - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-edge-not-allowed-values - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - response: - - name: X-SSL-Client-Cert - action: - type: Set - set: - value: - expectedError: 'Route.route.openshift.io "hello-openshift-edge-not-allowed-values" is invalid: [spec.httpHeaders.actions.response[0].action.set.value: Required value, : Invalid value: "null": some validation rules were not checked because the object was invalid; correct the existing errors to complete validation]' - - name: Should be required to specify the set field when the discriminant type is Set. - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-actions - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - type: Set - expectedError: "set is required when type is Set, and forbidden otherwise" - - name: Should be required to specify the set field when the discriminant type is Set. - initial: | - apiVersion: route.openshift.io/v1 - kind: Route - metadata: - labels: - type: sharded - name: hello-openshift-actions - namespace: hello-openshift - spec: - subdomain: hello-openshift - tls: - termination: edge - to: - kind: Service - name: hello-openshift - httpHeaders: - actions: - response: - - name: X-Frame-Options - action: - set: - value: DENY - expectedError: 'Route.route.openshift.io "hello-openshift-actions" is invalid: [spec.httpHeaders.actions.response[0].action.type: Required value, : Invalid value: "null": some validation rules were not checked because the object was invalid; correct the existing errors to complete validation]' diff --git a/vendor/github.com/openshift/api/route/v1/types.go b/vendor/github.com/openshift/api/route/v1/types.go index 2f195a6a6b..fb356bdd65 100644 --- a/vendor/github.com/openshift/api/route/v1/types.go +++ b/vendor/github.com/openshift/api/route/v1/types.go @@ -47,7 +47,6 @@ type Route struct { metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // spec is the desired state of the route - // +kubebuilder:validation:XValidation:rule="!has(self.tls) || self.tls.termination != 'passthrough' || !has(self.httpHeaders)",message="header actions are not permitted when tls termination is passthrough." Spec RouteSpec `json:"spec" protobuf:"bytes,2,opt,name=spec"` // status is the current state of the route // +optional @@ -146,166 +145,8 @@ type RouteSpec struct { // +kubebuilder:validation:Enum=None;Subdomain;"" // +kubebuilder:default=None WildcardPolicy WildcardPolicyType `json:"wildcardPolicy,omitempty" protobuf:"bytes,7,opt,name=wildcardPolicy"` - - // httpHeaders defines policy for HTTP headers. - // - // +optional - HTTPHeaders *RouteHTTPHeaders `json:"httpHeaders,omitempty" protobuf:"bytes,9,opt,name=httpHeaders"` -} - -// RouteHTTPHeaders defines policy for HTTP headers. -type RouteHTTPHeaders struct { - // actions specifies options for modifying headers and their values. - // Note that this option only applies to cleartext HTTP connections - // and to secure HTTP connections for which the ingress controller - // terminates encryption (that is, edge-terminated or reencrypt - // connections). Headers cannot be modified for TLS passthrough - // connections. - // Setting the HSTS (`Strict-Transport-Security`) header is not supported via actions. - // `Strict-Transport-Security` may only be configured using the "haproxy.router.openshift.io/hsts_header" - // route annotation, and only in accordance with the policy specified in Ingress.Spec.RequiredHSTSPolicies. - // In case of HTTP request headers, the actions specified in spec.httpHeaders.actions on the Route will be executed after - // the actions specified in the IngressController's spec.httpHeaders.actions field. - // In case of HTTP response headers, the actions specified in spec.httpHeaders.actions on the IngressController will be - // executed after the actions specified in the Route's spec.httpHeaders.actions field. - // The headers set via this API will not appear in access logs. - // Any actions defined here are applied after any actions related to the following other fields: - // cache-control, spec.clientTLS, - // spec.httpHeaders.forwardedHeaderPolicy, spec.httpHeaders.uniqueId, - // and spec.httpHeaders.headerNameCaseAdjustments. - // The following header names are reserved and may not be modified via this API: - // Strict-Transport-Security, Proxy, Cookie, Set-Cookie. - // Note that the total size of all net added headers *after* interpolating dynamic values - // must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the - // IngressController. Please refer to the documentation - // for that API field for more details. - // +optional - Actions RouteHTTPHeaderActions `json:"actions,omitempty" protobuf:"bytes,1,opt,name=actions"` } -// RouteHTTPHeaderActions defines configuration for actions on HTTP request and response headers. -type RouteHTTPHeaderActions struct { - // response is a list of HTTP response headers to modify. - // Currently, actions may define to either `Set` or `Delete` headers values. - // Actions defined here will modify the response headers of all requests made through a route. - // These actions are applied to a specific Route defined within a cluster i.e. connections made through a route. - // Route actions will be executed before IngressController actions for response headers. - // Actions are applied in sequence as defined in this list. - // A maximum of 20 response header actions may be configured. - // You can use this field to specify HTTP response headers that should be set or deleted - // when forwarding responses from your application to the client. - // Sample fetchers allowed are "res.hdr" and "ssl_c_der". - // Converters allowed are "lower" and "base64". - // Example header values: "%[res.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]". - // Note: This field cannot be used if your route uses TLS passthrough. - // + --- - // + Note: Any change to regex mentioned below must be reflected in the CRD validation of route in https://github.com/openshift/library-go/blob/master/pkg/route/validation/validation.go and vice-versa. - // +listType=map - // +listMapKey=name - // +optional - // +kubebuilder:validation:MaxItems=20 - // +kubebuilder:validation:XValidation:rule=`self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:res\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$')))`,message="Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are res.hdr, ssl_c_der. Converters allowed are lower, base64." - Response []RouteHTTPHeader `json:"response" protobuf:"bytes,1,rep,name=response"` - // request is a list of HTTP request headers to modify. - // Currently, actions may define to either `Set` or `Delete` headers values. - // Actions defined here will modify the request headers of all requests made through a route. - // These actions are applied to a specific Route defined within a cluster i.e. connections made through a route. - // Currently, actions may define to either `Set` or `Delete` headers values. - // Route actions will be executed after IngressController actions for request headers. - // Actions are applied in sequence as defined in this list. - // A maximum of 20 request header actions may be configured. - // You can use this field to specify HTTP request headers that should be set or deleted - // when forwarding connections from the client to your application. - // Sample fetchers allowed are "req.hdr" and "ssl_c_der". - // Converters allowed are "lower" and "base64". - // Example header values: "%[req.hdr(X-target),lower]", "%{+Q}[ssl_c_der,base64]". - // Any request header configuration applied directly via a Route resource using this API - // will override header configuration for a header of the same name applied via - // spec.httpHeaders.actions on the IngressController or route annotation. - // Note: This field cannot be used if your route uses TLS passthrough. - // + --- - // + Note: Any change to regex mentioned below must be reflected in the CRD validation of route in https://github.com/openshift/library-go/blob/master/pkg/route/validation/validation.go and vice-versa. - // +listType=map - // +listMapKey=name - // +optional - // +kubebuilder:validation:MaxItems=20 - // +kubebuilder:validation:XValidation:rule=`self.all(key, key.action.type == "Delete" || (has(key.action.set) && key.action.set.value.matches('^(?:%(?:%|(?:\\{[-+]?[QXE](?:,[-+]?[QXE])*\\})?\\[(?:req\\.hdr\\([0-9A-Za-z-]+\\)|ssl_c_der)(?:,(?:lower|base64))*\\])|[^%[:cntrl:]])+$')))`,message="Either the header value provided is not in correct format or the sample fetcher/converter specified is not allowed. The dynamic header value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. Sample fetchers allowed are req.hdr, ssl_c_der. Converters allowed are lower, base64." - Request []RouteHTTPHeader `json:"request" protobuf:"bytes,2,rep,name=request"` -} - -// RouteHTTPHeader specifies configuration for setting or deleting an HTTP header. -type RouteHTTPHeader struct { - // name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header - // name as defined in RFC 2616 section 4.2. - // The name must consist only of alphanumeric and the following special characters, "-!#$%&'*+.^_`". - // The following header names are reserved and may not be modified via this API: - // Strict-Transport-Security, Proxy, Cookie, Set-Cookie. - // It must be no more than 1024 characters in length. - // Header name must be unique. - // +kubebuilder:validation:Required - // +kubebuilder:validation:MinLength=1 - // +kubebuilder:validation:MaxLength=1024 - // +kubebuilder:validation:Pattern="^[-!#$%&'*+.0-9A-Z^_`a-z|~]+$" - // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'strict-transport-security'",message="strict-transport-security header may not be modified via header actions" - // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'proxy'",message="proxy header may not be modified via header actions" - // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'cookie'",message="cookie header may not be modified via header actions" - // +kubebuilder:validation:XValidation:rule="self.lowerAscii() != 'set-cookie'",message="set-cookie header may not be modified via header actions" - Name string `json:"name" protobuf:"bytes,1,opt,name=name"` - - // action specifies actions to perform on headers, such as setting or deleting headers. - // +kubebuilder:validation:Required - Action RouteHTTPHeaderActionUnion `json:"action" protobuf:"bytes,2,opt,name=action"` -} - -// RouteHTTPHeaderActionUnion specifies an action to take on an HTTP header. -// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'Set' ? has(self.set) : !has(self.set)",message="set is required when type is Set, and forbidden otherwise" -// +union -type RouteHTTPHeaderActionUnion struct { - // type defines the type of the action to be applied on the header. - // Possible values are Set or Delete. - // Set allows you to set HTTP request and response headers. - // Delete allows you to delete HTTP request and response headers. - // +unionDiscriminator - // +kubebuilder:validation:Enum:=Set;Delete - // +kubebuilder:validation:Required - Type RouteHTTPHeaderActionType `json:"type" protobuf:"bytes,1,opt,name=type,casttype=RouteHTTPHeaderActionType"` - - // set defines the HTTP header that should be set: added if it doesn't exist or replaced if it does. - // This field is required when type is Set and forbidden otherwise. - // +optional - // +unionMember - Set *RouteSetHTTPHeader `json:"set,omitempty" protobuf:"bytes,2,opt,name=set"` -} - -// RouteSetHTTPHeader specifies what value needs to be set on an HTTP header. -type RouteSetHTTPHeader struct { - // value specifies a header value. - // Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in - // http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and - // otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. - // The value of this field must be no more than 16384 characters in length. - // Note that the total size of all net added headers *after* interpolating dynamic values - // must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the - // IngressController. - // + --- - // + Note: This limit was selected as most common web servers have a limit of 16384 characters or some lower limit. - // + See . - // +kubebuilder:validation:Required - // +kubebuilder:validation:MinLength=1 - // +kubebuilder:validation:MaxLength=16384 - Value string `json:"value" protobuf:"bytes,1,opt,name=value"` -} - -// RouteHTTPHeaderActionType defines actions that can be performed on HTTP headers. -type RouteHTTPHeaderActionType string - -const ( - // Set specifies that an HTTP header should be set. - Set RouteHTTPHeaderActionType = "Set" - // Delete specifies that an HTTP header should be deleted. - Delete RouteHTTPHeaderActionType = "Delete" -) - // RouteTargetReference specifies the target that resolve into endpoints. Only the 'Service' // kind is allowed. Use 'weight' field to emphasize one over others. type RouteTargetReference struct { @@ -415,7 +256,6 @@ type TLSConfig struct { // * passthrough - Traffic is sent straight to the destination without the router providing TLS termination // * reencrypt - TLS termination is done by the router and https is used to communicate with the backend // - // Note: passthrough termination is incompatible with httpHeader actions // +kubebuilder:validation:Enum=edge;reencrypt;passthrough Termination TLSTerminationType `json:"termination" protobuf:"bytes,1,opt,name=termination,casttype=TLSTerminationType"` diff --git a/vendor/github.com/openshift/api/route/v1/zz_generated.deepcopy.go b/vendor/github.com/openshift/api/route/v1/zz_generated.deepcopy.go index 23a2edd423..113c2f0708 100644 --- a/vendor/github.com/openshift/api/route/v1/zz_generated.deepcopy.go +++ b/vendor/github.com/openshift/api/route/v1/zz_generated.deepcopy.go @@ -53,91 +53,6 @@ func (in *Route) DeepCopyObject() runtime.Object { return nil } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *RouteHTTPHeader) DeepCopyInto(out *RouteHTTPHeader) { - *out = *in - in.Action.DeepCopyInto(&out.Action) - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RouteHTTPHeader. -func (in *RouteHTTPHeader) DeepCopy() *RouteHTTPHeader { - if in == nil { - return nil - } - out := new(RouteHTTPHeader) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *RouteHTTPHeaderActionUnion) DeepCopyInto(out *RouteHTTPHeaderActionUnion) { - *out = *in - if in.Set != nil { - in, out := &in.Set, &out.Set - *out = new(RouteSetHTTPHeader) - **out = **in - } - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RouteHTTPHeaderActionUnion. -func (in *RouteHTTPHeaderActionUnion) DeepCopy() *RouteHTTPHeaderActionUnion { - if in == nil { - return nil - } - out := new(RouteHTTPHeaderActionUnion) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *RouteHTTPHeaderActions) DeepCopyInto(out *RouteHTTPHeaderActions) { - *out = *in - if in.Response != nil { - in, out := &in.Response, &out.Response - *out = make([]RouteHTTPHeader, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } - if in.Request != nil { - in, out := &in.Request, &out.Request - *out = make([]RouteHTTPHeader, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RouteHTTPHeaderActions. -func (in *RouteHTTPHeaderActions) DeepCopy() *RouteHTTPHeaderActions { - if in == nil { - return nil - } - out := new(RouteHTTPHeaderActions) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *RouteHTTPHeaders) DeepCopyInto(out *RouteHTTPHeaders) { - *out = *in - in.Actions.DeepCopyInto(&out.Actions) - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RouteHTTPHeaders. -func (in *RouteHTTPHeaders) DeepCopy() *RouteHTTPHeaders { - if in == nil { - return nil - } - out := new(RouteHTTPHeaders) - in.DeepCopyInto(out) - return out -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *RouteIngress) DeepCopyInto(out *RouteIngress) { *out = *in @@ -231,22 +146,6 @@ func (in *RoutePort) DeepCopy() *RoutePort { return out } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *RouteSetHTTPHeader) DeepCopyInto(out *RouteSetHTTPHeader) { - *out = *in - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RouteSetHTTPHeader. -func (in *RouteSetHTTPHeader) DeepCopy() *RouteSetHTTPHeader { - if in == nil { - return nil - } - out := new(RouteSetHTTPHeader) - in.DeepCopyInto(out) - return out -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *RouteSpec) DeepCopyInto(out *RouteSpec) { *out = *in @@ -268,11 +167,6 @@ func (in *RouteSpec) DeepCopyInto(out *RouteSpec) { *out = new(TLSConfig) (*in).DeepCopyInto(*out) } - if in.HTTPHeaders != nil { - in, out := &in.HTTPHeaders, &out.HTTPHeaders - *out = new(RouteHTTPHeaders) - (*in).DeepCopyInto(*out) - } return } diff --git a/vendor/github.com/openshift/api/route/v1/zz_generated.swagger_doc_generated.go b/vendor/github.com/openshift/api/route/v1/zz_generated.swagger_doc_generated.go index abcec62cd6..621b5d69bc 100644 --- a/vendor/github.com/openshift/api/route/v1/zz_generated.swagger_doc_generated.go +++ b/vendor/github.com/openshift/api/route/v1/zz_generated.swagger_doc_generated.go @@ -31,45 +31,6 @@ func (Route) SwaggerDoc() map[string]string { return map_Route } -var map_RouteHTTPHeader = map[string]string{ - "": "RouteHTTPHeader specifies configuration for setting or deleting an HTTP header.", - "name": "name specifies the name of a header on which to perform an action. Its value must be a valid HTTP header name as defined in RFC 2616 section 4.2. The name must consist only of alphanumeric and the following special characters, \"-!#$%&'*+.^_`\". The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Cookie, Set-Cookie. It must be no more than 1024 characters in length. Header name must be unique.", - "action": "action specifies actions to perform on headers, such as setting or deleting headers.", -} - -func (RouteHTTPHeader) SwaggerDoc() map[string]string { - return map_RouteHTTPHeader -} - -var map_RouteHTTPHeaderActionUnion = map[string]string{ - "": "RouteHTTPHeaderActionUnion specifies an action to take on an HTTP header.", - "type": "type defines the type of the action to be applied on the header. Possible values are Set or Delete. Set allows you to set HTTP request and response headers. Delete allows you to delete HTTP request and response headers.", - "set": "set defines the HTTP header that should be set: added if it doesn't exist or replaced if it does. This field is required when type is Set and forbidden otherwise.", -} - -func (RouteHTTPHeaderActionUnion) SwaggerDoc() map[string]string { - return map_RouteHTTPHeaderActionUnion -} - -var map_RouteHTTPHeaderActions = map[string]string{ - "": "RouteHTTPHeaderActions defines configuration for actions on HTTP request and response headers.", - "response": "response is a list of HTTP response headers to modify. Currently, actions may define to either `Set` or `Delete` headers values. Actions defined here will modify the response headers of all requests made through a route. These actions are applied to a specific Route defined within a cluster i.e. connections made through a route. Route actions will be executed before IngressController actions for response headers. Actions are applied in sequence as defined in this list. A maximum of 20 response header actions may be configured. You can use this field to specify HTTP response headers that should be set or deleted when forwarding responses from your application to the client. Sample fetchers allowed are \"res.hdr\" and \"ssl_c_der\". Converters allowed are \"lower\" and \"base64\". Example header values: \"%[res.hdr(X-target),lower]\", \"%{+Q}[ssl_c_der,base64]\". Note: This field cannot be used if your route uses TLS passthrough. ", - "request": "request is a list of HTTP request headers to modify. Currently, actions may define to either `Set` or `Delete` headers values. Actions defined here will modify the request headers of all requests made through a route. These actions are applied to a specific Route defined within a cluster i.e. connections made through a route. Currently, actions may define to either `Set` or `Delete` headers values. Route actions will be executed after IngressController actions for request headers. Actions are applied in sequence as defined in this list. A maximum of 20 request header actions may be configured. You can use this field to specify HTTP request headers that should be set or deleted when forwarding connections from the client to your application. Sample fetchers allowed are \"req.hdr\" and \"ssl_c_der\". Converters allowed are \"lower\" and \"base64\". Example header values: \"%[req.hdr(X-target),lower]\", \"%{+Q}[ssl_c_der,base64]\". Any request header configuration applied directly via a Route resource using this API will override header configuration for a header of the same name applied via spec.httpHeaders.actions on the IngressController or route annotation. Note: This field cannot be used if your route uses TLS passthrough. ", -} - -func (RouteHTTPHeaderActions) SwaggerDoc() map[string]string { - return map_RouteHTTPHeaderActions -} - -var map_RouteHTTPHeaders = map[string]string{ - "": "RouteHTTPHeaders defines policy for HTTP headers.", - "actions": "actions specifies options for modifying headers and their values. Note that this option only applies to cleartext HTTP connections and to secure HTTP connections for which the ingress controller terminates encryption (that is, edge-terminated or reencrypt connections). Headers cannot be modified for TLS passthrough connections. Setting the HSTS (`Strict-Transport-Security`) header is not supported via actions. `Strict-Transport-Security` may only be configured using the \"haproxy.router.openshift.io/hsts_header\" route annotation, and only in accordance with the policy specified in Ingress.Spec.RequiredHSTSPolicies. In case of HTTP request headers, the actions specified in spec.httpHeaders.actions on the Route will be executed after the actions specified in the IngressController's spec.httpHeaders.actions field. In case of HTTP response headers, the actions specified in spec.httpHeaders.actions on the IngressController will be executed after the actions specified in the Route's spec.httpHeaders.actions field. The headers set via this API will not appear in access logs. Any actions defined here are applied after any actions related to the following other fields: cache-control, spec.clientTLS, spec.httpHeaders.forwardedHeaderPolicy, spec.httpHeaders.uniqueId, and spec.httpHeaders.headerNameCaseAdjustments. The following header names are reserved and may not be modified via this API: Strict-Transport-Security, Proxy, Cookie, Set-Cookie. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. Please refer to the documentation for that API field for more details.", -} - -func (RouteHTTPHeaders) SwaggerDoc() map[string]string { - return map_RouteHTTPHeaders -} - var map_RouteIngress = map[string]string{ "": "RouteIngress holds information about the places where a route is exposed.", "host": "Host is the host string under which the route is exposed; this value is required", @@ -115,15 +76,6 @@ func (RoutePort) SwaggerDoc() map[string]string { return map_RoutePort } -var map_RouteSetHTTPHeader = map[string]string{ - "": "RouteSetHTTPHeader specifies what value needs to be set on an HTTP header.", - "value": "value specifies a header value. Dynamic values can be added. The value will be interpreted as an HAProxy format string as defined in http://cbonte.github.io/haproxy-dconv/2.6/configuration.html#8.2.6 and may use HAProxy's %[] syntax and otherwise must be a valid HTTP header value as defined in https://datatracker.ietf.org/doc/html/rfc7230#section-3.2. The value of this field must be no more than 16384 characters in length. Note that the total size of all net added headers *after* interpolating dynamic values must not exceed the value of spec.tuningOptions.headerBufferMaxRewriteBytes on the IngressController. ", -} - -func (RouteSetHTTPHeader) SwaggerDoc() map[string]string { - return map_RouteSetHTTPHeader -} - var map_RouteSpec = map[string]string{ "": "RouteSpec describes the hostname or path the route exposes, any security information, and one to four backends (services) the route points to. Requests are distributed among the backends depending on the weights assigned to each backend. When using roundrobin scheduling the portion of requests that go to each backend is the backend weight divided by the sum of all of the backend weights. When the backend has more than one endpoint the requests that end up on the backend are roundrobin distributed among the endpoints. Weights are between 0 and 256 with default 100. Weight 0 causes no requests to the backend. If all weights are zero the route will be considered to have no backends and return a standard 503 response.\n\nThe `tls` field is optional and allows specific certificates or behavior for the route. Routers typically configure a default certificate on a wildcard domain to terminate routes without explicit certificates, but custom hostnames usually must choose passthrough (send traffic directly to the backend via the TLS Server-Name- Indication field) or provide a certificate.", "host": "host is an alias/DNS that points to the service. Optional. If not specified a route name will typically be automatically chosen. Must follow DNS952 subdomain conventions.", @@ -134,7 +86,6 @@ var map_RouteSpec = map[string]string{ "port": "If specified, the port to be used by the router. Most routers will use all endpoints exposed by the service by default - set this value to instruct routers which port to use.", "tls": "The tls field provides the ability to configure certificates and termination for the route.", "wildcardPolicy": "Wildcard policy if any for the route. Currently only 'Subdomain' or 'None' is allowed.", - "httpHeaders": "httpHeaders defines policy for HTTP headers.", } func (RouteSpec) SwaggerDoc() map[string]string { @@ -173,7 +124,7 @@ func (RouterShard) SwaggerDoc() map[string]string { var map_TLSConfig = map[string]string{ "": "TLSConfig defines config used to secure a route and provide termination", - "termination": "termination indicates termination type.\n\n* edge - TLS termination is done by the router and http is used to communicate with the backend (default) * passthrough - Traffic is sent straight to the destination without the router providing TLS termination * reencrypt - TLS termination is done by the router and https is used to communicate with the backend\n\nNote: passthrough termination is incompatible with httpHeader actions", + "termination": "termination indicates termination type.\n\n* edge - TLS termination is done by the router and http is used to communicate with the backend (default) * passthrough - Traffic is sent straight to the destination without the router providing TLS termination * reencrypt - TLS termination is done by the router and https is used to communicate with the backend", "certificate": "certificate provides certificate contents. This should be a single serving certificate, not a certificate chain. Do not include a CA certificate.", "key": "key provides key file contents", "caCertificate": "caCertificate provides the cert authority certificate contents", diff --git a/vendor/github.com/openshift/api/samples/v1/00_samplesconfig.crd.yaml b/vendor/github.com/openshift/api/samples/v1/0000_10_samplesconfig.crd.yaml similarity index 100% rename from vendor/github.com/openshift/api/samples/v1/00_samplesconfig.crd.yaml rename to vendor/github.com/openshift/api/samples/v1/0000_10_samplesconfig.crd.yaml diff --git a/vendor/github.com/openshift/api/samples/v1/stable.config.testsuite.yaml b/vendor/github.com/openshift/api/samples/v1/stable.config.testsuite.yaml index dbb8e14a48..34026a86ae 100644 --- a/vendor/github.com/openshift/api/samples/v1/stable.config.testsuite.yaml +++ b/vendor/github.com/openshift/api/samples/v1/stable.config.testsuite.yaml @@ -1,6 +1,6 @@ apiVersion: apiextensions.k8s.io/v1 # Hack because controller-gen complains if we don't have this name: "[Stable] Config" -crd: 00_samplesconfig.crd.yaml +crd: 0000_10_samplesconfig.crd.yaml tests: onCreate: - name: Should be able to create a minimal Config diff --git a/vendor/modules.txt b/vendor/modules.txt index 71d20060f0..7702e67f82 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -76,7 +76,7 @@ github.com/modern-go/reflect2 # github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 ## explicit github.com/munnerz/goautoneg -# github.com/openshift/api v0.0.0-20230807121159-a81c3efc8824 +# github.com/openshift/api v0.0.0-20230807121159-a81c3efc8824 => github.com/jkyros/api v0.0.0-20230804193108-c3f001422ebe ## explicit; go 1.20 github.com/openshift/api/apiserver/v1 github.com/openshift/api/apps/v1 @@ -475,3 +475,4 @@ sigs.k8s.io/structured-merge-diff/v4/value sigs.k8s.io/yaml # k8s.io/code-generator => github.com/openshift/kubernetes-code-generator v0.0.0-20220822200235-042483082c5e # k8s.io/kube-openapi => github.com/openshift/kube-openapi v0.0.0-20230324164143-98c122c21a89 +# github.com/openshift/api => github.com/jkyros/api v0.0.0-20230804193108-c3f001422ebe