diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 6f22aaea72..19eb9ba1ce 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -69,7 +69,7 @@ updates: commit-message: prefix: "NO-JIRA" labels: - - "area/api" + - "area/ci-tooling" - "ok-to-test" groups: github-dependencies: diff --git a/Makefile b/Makefile index ebaa3e9a10..77150b6b74 100644 --- a/Makefile +++ b/Makefile @@ -20,7 +20,6 @@ PROMTOOL=$(abspath $(TOOLS_BIN_DIR)/promtool) GO_GCFLAGS ?= -gcflags=all='-N -l' GO=GO111MODULE=on GOFLAGS=-mod=vendor go -GO_NO_VENDOR=GO111MODULE=on GOFLAGS=-mod=mod go GO_BUILD_RECIPE=CGO_ENABLED=1 $(GO) build $(GO_GCFLAGS) GO_E2E_RECIPE=CGO_ENABLED=1 $(GO) test $(GO_GCFLAGS) -tags e2e -c @@ -95,9 +94,9 @@ api: hypershift-api cluster-api cluster-api-provider-aws cluster-api-provider-ib .PHONY: hypershift-api hypershift-api: $(CONTROLLER_GEN) - $(CONTROLLER_GEN) object:headerFile="hack/boilerplate.go.txt" paths="./api/types/..." + $(CONTROLLER_GEN) object:headerFile="hack/boilerplate.go.txt" paths="./api/..." rm -rf cmd/install/assets/hypershift-operator/*.yaml - $(CONTROLLER_GEN) $(CRD_OPTIONS) paths="./api/types/..." output:crd:artifacts:config=cmd/install/assets/hypershift-operator + $(CONTROLLER_GEN) $(CRD_OPTIONS) paths="./api/..." output:crd:artifacts:config=cmd/install/assets/hypershift-operator .PHONY: cluster-api cluster-api: $(CONTROLLER_GEN) diff --git a/api/types/certificates/register.go b/api/certificates/register.go similarity index 100% rename from api/types/certificates/register.go rename to api/certificates/register.go diff --git a/vendor/github.com/openshift/hypershift/api/types/certificates/v1alpha1/certificaterevocationrequest_types.go b/api/certificates/v1alpha1/certificaterevocationrequest_types.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/certificates/v1alpha1/certificaterevocationrequest_types.go rename to api/certificates/v1alpha1/certificaterevocationrequest_types.go diff --git a/api/types/certificates/v1alpha1/certificatesigningrequestapproval_types.go b/api/certificates/v1alpha1/certificatesigningrequestapproval_types.go similarity index 100% rename from api/types/certificates/v1alpha1/certificatesigningrequestapproval_types.go rename to api/certificates/v1alpha1/certificatesigningrequestapproval_types.go diff --git a/api/types/certificates/v1alpha1/doc.go b/api/certificates/v1alpha1/doc.go similarity index 100% rename from api/types/certificates/v1alpha1/doc.go rename to api/certificates/v1alpha1/doc.go diff --git a/vendor/github.com/openshift/hypershift/api/types/certificates/v1alpha1/register.go b/api/certificates/v1alpha1/register.go similarity index 95% rename from vendor/github.com/openshift/hypershift/api/types/certificates/v1alpha1/register.go rename to api/certificates/v1alpha1/register.go index f23139b0bb..558235401e 100644 --- a/vendor/github.com/openshift/hypershift/api/types/certificates/v1alpha1/register.go +++ b/api/certificates/v1alpha1/register.go @@ -5,7 +5,7 @@ import ( "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" - "github.com/openshift/hypershift/api/types/certificates" + "github.com/openshift/hypershift/api/certificates" ) // SchemeGroupVersion is group version used to register these objects. diff --git a/vendor/github.com/openshift/hypershift/api/types/certificates/v1alpha1/zz_generated.deepcopy.go b/api/certificates/v1alpha1/zz_generated.deepcopy.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/certificates/v1alpha1/zz_generated.deepcopy.go rename to api/certificates/v1alpha1/zz_generated.deepcopy.go diff --git a/api/types/hypershift/register.go b/api/hypershift/register.go similarity index 100% rename from api/types/hypershift/register.go rename to api/hypershift/register.go diff --git a/api/types/hypershift/v1alpha1/clusterconfig.go b/api/hypershift/v1alpha1/clusterconfig.go similarity index 100% rename from api/types/hypershift/v1alpha1/clusterconfig.go rename to api/hypershift/v1alpha1/clusterconfig.go diff --git a/api/types/hypershift/v1alpha1/conditions.go b/api/hypershift/v1alpha1/conditions.go similarity index 100% rename from api/types/hypershift/v1alpha1/conditions.go rename to api/hypershift/v1alpha1/conditions.go diff --git a/api/types/hypershift/v1alpha1/doc.go b/api/hypershift/v1alpha1/doc.go similarity index 100% rename from api/types/hypershift/v1alpha1/doc.go rename to api/hypershift/v1alpha1/doc.go diff --git a/api/types/hypershift/v1alpha1/endpointservice_types.go b/api/hypershift/v1alpha1/endpointservice_types.go similarity index 100% rename from api/types/hypershift/v1alpha1/endpointservice_types.go rename to api/hypershift/v1alpha1/endpointservice_types.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/groupversion_info.go b/api/hypershift/v1alpha1/groupversion_info.go similarity index 96% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/groupversion_info.go rename to api/hypershift/v1alpha1/groupversion_info.go index 96343de32b..b63c943eaa 100644 --- a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/groupversion_info.go +++ b/api/hypershift/v1alpha1/groupversion_info.go @@ -4,7 +4,7 @@ package v1alpha1 import ( - "github.com/openshift/hypershift/api/types/hypershift" + "github.com/openshift/hypershift/api/hypershift" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/hosted_controlplane.go b/api/hypershift/v1alpha1/hosted_controlplane.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/hosted_controlplane.go rename to api/hypershift/v1alpha1/hosted_controlplane.go diff --git a/api/types/hypershift/v1alpha1/hostedcluster_types.go b/api/hypershift/v1alpha1/hostedcluster_types.go similarity index 100% rename from api/types/hypershift/v1alpha1/hostedcluster_types.go rename to api/hypershift/v1alpha1/hostedcluster_types.go diff --git a/api/types/hypershift/v1alpha1/nodepool_types.go b/api/hypershift/v1alpha1/nodepool_types.go similarity index 99% rename from api/types/hypershift/v1alpha1/nodepool_types.go rename to api/hypershift/v1alpha1/nodepool_types.go index 9f4100f6df..4cd22a1a79 100644 --- a/api/types/hypershift/v1alpha1/nodepool_types.go +++ b/api/hypershift/v1alpha1/nodepool_types.go @@ -9,7 +9,7 @@ import ( "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/util/intstr" - "github.com/openshift/hypershift/api/types/ibmcapi" + "github.com/openshift/hypershift/api/ibmcapi" ) const ( diff --git a/api/types/hypershift/v1alpha1/zz_generated.deepcopy.go b/api/hypershift/v1alpha1/zz_generated.deepcopy.go similarity index 100% rename from api/types/hypershift/v1alpha1/zz_generated.deepcopy.go rename to api/hypershift/v1alpha1/zz_generated.deepcopy.go diff --git a/api/types/hypershift/v1beta1/certificatesigningrequestapproval_types.go b/api/hypershift/v1beta1/certificatesigningrequestapproval_types.go similarity index 100% rename from api/types/hypershift/v1beta1/certificatesigningrequestapproval_types.go rename to api/hypershift/v1beta1/certificatesigningrequestapproval_types.go diff --git a/api/types/hypershift/v1beta1/clusterconfig.go b/api/hypershift/v1beta1/clusterconfig.go similarity index 100% rename from api/types/hypershift/v1beta1/clusterconfig.go rename to api/hypershift/v1beta1/clusterconfig.go diff --git a/api/types/hypershift/v1beta1/doc.go b/api/hypershift/v1beta1/doc.go similarity index 100% rename from api/types/hypershift/v1beta1/doc.go rename to api/hypershift/v1beta1/doc.go diff --git a/api/types/hypershift/v1beta1/endpointservice_types.go b/api/hypershift/v1beta1/endpointservice_types.go similarity index 100% rename from api/types/hypershift/v1beta1/endpointservice_types.go rename to api/hypershift/v1beta1/endpointservice_types.go diff --git a/api/types/hypershift/v1beta1/groupversion_info.go b/api/hypershift/v1beta1/groupversion_info.go similarity index 96% rename from api/types/hypershift/v1beta1/groupversion_info.go rename to api/hypershift/v1beta1/groupversion_info.go index 337ad40871..4fc32d35c6 100644 --- a/api/types/hypershift/v1beta1/groupversion_info.go +++ b/api/hypershift/v1beta1/groupversion_info.go @@ -4,7 +4,7 @@ package v1beta1 import ( - "github.com/openshift/hypershift/api/types/hypershift" + "github.com/openshift/hypershift/api/hypershift" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/hosted_controlplane.go b/api/hypershift/v1beta1/hosted_controlplane.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/hosted_controlplane.go rename to api/hypershift/v1beta1/hosted_controlplane.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/hostedcluster_conditions.go b/api/hypershift/v1beta1/hostedcluster_conditions.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/hostedcluster_conditions.go rename to api/hypershift/v1beta1/hostedcluster_conditions.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/hostedcluster_types.go b/api/hypershift/v1beta1/hostedcluster_types.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/hostedcluster_types.go rename to api/hypershift/v1beta1/hostedcluster_types.go diff --git a/api/types/hypershift/v1beta1/nodepool_conditions.go b/api/hypershift/v1beta1/nodepool_conditions.go similarity index 100% rename from api/types/hypershift/v1beta1/nodepool_conditions.go rename to api/hypershift/v1beta1/nodepool_conditions.go diff --git a/api/types/hypershift/v1beta1/nodepool_types.go b/api/hypershift/v1beta1/nodepool_types.go similarity index 99% rename from api/types/hypershift/v1beta1/nodepool_types.go rename to api/hypershift/v1beta1/nodepool_types.go index d80d1b93e0..1e4fc648e0 100644 --- a/api/types/hypershift/v1beta1/nodepool_types.go +++ b/api/hypershift/v1beta1/nodepool_types.go @@ -4,7 +4,7 @@ import ( "fmt" "strings" - "github.com/openshift/hypershift/api/types/ibmcapi" + "github.com/openshift/hypershift/api/ibmcapi" corev1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/api/resource" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/api/types/hypershift/v1beta1/zz_generated.deepcopy.go b/api/hypershift/v1beta1/zz_generated.deepcopy.go similarity index 100% rename from api/types/hypershift/v1beta1/zz_generated.deepcopy.go rename to api/hypershift/v1beta1/zz_generated.deepcopy.go diff --git a/api/types/ibmcapi/types.go b/api/ibmcapi/types.go similarity index 100% rename from api/types/ibmcapi/types.go rename to api/ibmcapi/types.go diff --git a/api/types/hypershift/v1beta1/conversion.go b/api/types/hypershift/v1beta1/conversion.go deleted file mode 100644 index 01f3a38f98..0000000000 --- a/api/types/hypershift/v1beta1/conversion.go +++ /dev/null @@ -1,7 +0,0 @@ -package v1beta1 - -// Declare the types in this version as the Hub -func (*HostedCluster) Hub() {} -func (*NodePool) Hub() {} -func (*AWSEndpointService) Hub() {} -func (*HostedControlPlane) Hub() {} diff --git a/api/util/configrefs/refs_test.go b/api/util/configrefs/refs_test.go index 4bf0ac77a1..1d66307f97 100644 --- a/api/util/configrefs/refs_test.go +++ b/api/util/configrefs/refs_test.go @@ -7,7 +7,7 @@ import ( "k8s.io/apimachinery/pkg/util/sets" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // Be sure to update *ConfigMapRefs in refs.go to include new configmap refs diff --git a/client/applyconfiguration/certificates/v1alpha1/certificatesigningrequestapproval.go b/client/applyconfiguration/certificates/v1alpha1/certificatesigningrequestapproval.go index 671a147a16..54131691c6 100644 --- a/client/applyconfiguration/certificates/v1alpha1/certificatesigningrequestapproval.go +++ b/client/applyconfiguration/certificates/v1alpha1/certificatesigningrequestapproval.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/certificates/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/certificates/v1alpha1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" types "k8s.io/apimachinery/pkg/types" v1 "k8s.io/client-go/applyconfigurations/meta/v1" diff --git a/client/applyconfiguration/hypershift/v1alpha1/apiservernetworking.go b/client/applyconfiguration/hypershift/v1alpha1/apiservernetworking.go index 4899e7344e..e16742e4d5 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/apiservernetworking.go +++ b/client/applyconfiguration/hypershift/v1alpha1/apiservernetworking.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // APIServerNetworkingApplyConfiguration represents an declarative configuration of the APIServerNetworking type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/awsplatformspec.go b/client/applyconfiguration/hypershift/v1alpha1/awsplatformspec.go index 8f078d401f..ad1a75ab76 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/awsplatformspec.go +++ b/client/applyconfiguration/hypershift/v1alpha1/awsplatformspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - hypershiftv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + hypershiftv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" v1 "k8s.io/api/core/v1" ) diff --git a/client/applyconfiguration/hypershift/v1alpha1/clusternetworking.go b/client/applyconfiguration/hypershift/v1alpha1/clusternetworking.go index 8af2f853dd..2e7d3ed9d8 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/clusternetworking.go +++ b/client/applyconfiguration/hypershift/v1alpha1/clusternetworking.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - hypershiftv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + hypershiftv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // ClusterNetworkingApplyConfiguration represents an declarative configuration of the ClusterNetworking type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/etcdspec.go b/client/applyconfiguration/hypershift/v1alpha1/etcdspec.go index 0e8596a508..55981cc5d9 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/etcdspec.go +++ b/client/applyconfiguration/hypershift/v1alpha1/etcdspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // EtcdSpecApplyConfiguration represents an declarative configuration of the EtcdSpec type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/hostedclusterspec.go b/client/applyconfiguration/hypershift/v1alpha1/hostedclusterspec.go index 5ca9c4a5e0..328caa03b0 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/hostedclusterspec.go +++ b/client/applyconfiguration/hypershift/v1alpha1/hostedclusterspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - hypershiftv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + hypershiftv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" v1 "k8s.io/api/core/v1" ) diff --git a/client/applyconfiguration/hypershift/v1alpha1/ibmcloudkmsauthspec.go b/client/applyconfiguration/hypershift/v1alpha1/ibmcloudkmsauthspec.go index 47e72fb893..ddaf5c5b11 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/ibmcloudkmsauthspec.go +++ b/client/applyconfiguration/hypershift/v1alpha1/ibmcloudkmsauthspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // IBMCloudKMSAuthSpecApplyConfiguration represents an declarative configuration of the IBMCloudKMSAuthSpec type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/kmsspec.go b/client/applyconfiguration/hypershift/v1alpha1/kmsspec.go index dc984cb696..8181aeaf2d 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/kmsspec.go +++ b/client/applyconfiguration/hypershift/v1alpha1/kmsspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // KMSSpecApplyConfiguration represents an declarative configuration of the KMSSpec type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/kubevirtcachingstrategy.go b/client/applyconfiguration/hypershift/v1alpha1/kubevirtcachingstrategy.go index f0aefa67cf..f2b6695037 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/kubevirtcachingstrategy.go +++ b/client/applyconfiguration/hypershift/v1alpha1/kubevirtcachingstrategy.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // KubevirtCachingStrategyApplyConfiguration represents an declarative configuration of the KubevirtCachingStrategy type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/kubevirtcompute.go b/client/applyconfiguration/hypershift/v1alpha1/kubevirtcompute.go index db194e8fd8..fdb4835b81 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/kubevirtcompute.go +++ b/client/applyconfiguration/hypershift/v1alpha1/kubevirtcompute.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" resource "k8s.io/apimachinery/pkg/api/resource" ) diff --git a/client/applyconfiguration/hypershift/v1alpha1/kubevirtnodepoolplatform.go b/client/applyconfiguration/hypershift/v1alpha1/kubevirtnodepoolplatform.go index df72ffe53b..f5ae52ccfd 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/kubevirtnodepoolplatform.go +++ b/client/applyconfiguration/hypershift/v1alpha1/kubevirtnodepoolplatform.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - hypershiftv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + hypershiftv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // KubevirtNodePoolPlatformApplyConfiguration represents an declarative configuration of the KubevirtNodePoolPlatform type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/kubevirtpersistentvolume.go b/client/applyconfiguration/hypershift/v1alpha1/kubevirtpersistentvolume.go index c086509ed6..67b2cbe350 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/kubevirtpersistentvolume.go +++ b/client/applyconfiguration/hypershift/v1alpha1/kubevirtpersistentvolume.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" v1 "k8s.io/api/core/v1" resource "k8s.io/apimachinery/pkg/api/resource" ) diff --git a/client/applyconfiguration/hypershift/v1alpha1/kubevirtrootvolume.go b/client/applyconfiguration/hypershift/v1alpha1/kubevirtrootvolume.go index d5936f40ea..56f4487d9d 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/kubevirtrootvolume.go +++ b/client/applyconfiguration/hypershift/v1alpha1/kubevirtrootvolume.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - hypershiftv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + hypershiftv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // KubevirtRootVolumeApplyConfiguration represents an declarative configuration of the KubevirtRootVolume type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/kubevirtstoragedriverspec.go b/client/applyconfiguration/hypershift/v1alpha1/kubevirtstoragedriverspec.go index c3f8f623da..f41c65f8b0 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/kubevirtstoragedriverspec.go +++ b/client/applyconfiguration/hypershift/v1alpha1/kubevirtstoragedriverspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // KubevirtStorageDriverSpecApplyConfiguration represents an declarative configuration of the KubevirtStorageDriverSpec type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/kubevirtvolume.go b/client/applyconfiguration/hypershift/v1alpha1/kubevirtvolume.go index 8a2053fb52..0d637b967d 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/kubevirtvolume.go +++ b/client/applyconfiguration/hypershift/v1alpha1/kubevirtvolume.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // KubevirtVolumeApplyConfiguration represents an declarative configuration of the KubevirtVolume type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/managedetcdstoragespec.go b/client/applyconfiguration/hypershift/v1alpha1/managedetcdstoragespec.go index 8de8133212..3499d67a83 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/managedetcdstoragespec.go +++ b/client/applyconfiguration/hypershift/v1alpha1/managedetcdstoragespec.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // ManagedEtcdStorageSpecApplyConfiguration represents an declarative configuration of the ManagedEtcdStorageSpec type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/nodepoolmanagement.go b/client/applyconfiguration/hypershift/v1alpha1/nodepoolmanagement.go index b77144f2cd..6b3a4d8276 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/nodepoolmanagement.go +++ b/client/applyconfiguration/hypershift/v1alpha1/nodepoolmanagement.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // NodePoolManagementApplyConfiguration represents an declarative configuration of the NodePoolManagement type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/nodepoolplatform.go b/client/applyconfiguration/hypershift/v1alpha1/nodepoolplatform.go index bc87c68fe5..295890b6d5 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/nodepoolplatform.go +++ b/client/applyconfiguration/hypershift/v1alpha1/nodepoolplatform.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // NodePoolPlatformApplyConfiguration represents an declarative configuration of the NodePoolPlatform type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/platformspec.go b/client/applyconfiguration/hypershift/v1alpha1/platformspec.go index 876ba6b1ba..9c31376287 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/platformspec.go +++ b/client/applyconfiguration/hypershift/v1alpha1/platformspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // PlatformSpecApplyConfiguration represents an declarative configuration of the PlatformSpec type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/powervsnodepoolplatform.go b/client/applyconfiguration/hypershift/v1alpha1/powervsnodepoolplatform.go index 024ad1b8b8..bbd5620025 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/powervsnodepoolplatform.go +++ b/client/applyconfiguration/hypershift/v1alpha1/powervsnodepoolplatform.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" intstr "k8s.io/apimachinery/pkg/util/intstr" ) diff --git a/client/applyconfiguration/hypershift/v1alpha1/replaceupgrade.go b/client/applyconfiguration/hypershift/v1alpha1/replaceupgrade.go index 291e8be06b..f48a538dd0 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/replaceupgrade.go +++ b/client/applyconfiguration/hypershift/v1alpha1/replaceupgrade.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // ReplaceUpgradeApplyConfiguration represents an declarative configuration of the ReplaceUpgrade type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/secretencryptionspec.go b/client/applyconfiguration/hypershift/v1alpha1/secretencryptionspec.go index 55ea91a179..f385954263 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/secretencryptionspec.go +++ b/client/applyconfiguration/hypershift/v1alpha1/secretencryptionspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // SecretEncryptionSpecApplyConfiguration represents an declarative configuration of the SecretEncryptionSpec type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/servicepublishingstrategy.go b/client/applyconfiguration/hypershift/v1alpha1/servicepublishingstrategy.go index 67ca8b8b60..6140a9dc6a 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/servicepublishingstrategy.go +++ b/client/applyconfiguration/hypershift/v1alpha1/servicepublishingstrategy.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // ServicePublishingStrategyApplyConfiguration represents an declarative configuration of the ServicePublishingStrategy type for use diff --git a/client/applyconfiguration/hypershift/v1alpha1/servicepublishingstrategymapping.go b/client/applyconfiguration/hypershift/v1alpha1/servicepublishingstrategymapping.go index 84adc89ae3..8d36a43e8f 100644 --- a/client/applyconfiguration/hypershift/v1alpha1/servicepublishingstrategymapping.go +++ b/client/applyconfiguration/hypershift/v1alpha1/servicepublishingstrategymapping.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" ) // ServicePublishingStrategyMappingApplyConfiguration represents an declarative configuration of the ServicePublishingStrategyMapping type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/apiservernetworking.go b/client/applyconfiguration/hypershift/v1beta1/apiservernetworking.go index 9d7dade5ab..064bf8b6bf 100644 --- a/client/applyconfiguration/hypershift/v1beta1/apiservernetworking.go +++ b/client/applyconfiguration/hypershift/v1beta1/apiservernetworking.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // APIServerNetworkingApplyConfiguration represents an declarative configuration of the APIServerNetworking type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/awsplatformspec.go b/client/applyconfiguration/hypershift/v1beta1/awsplatformspec.go index b2481234da..ac0d32e771 100644 --- a/client/applyconfiguration/hypershift/v1beta1/awsplatformspec.go +++ b/client/applyconfiguration/hypershift/v1beta1/awsplatformspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // AWSPlatformSpecApplyConfiguration represents an declarative configuration of the AWSPlatformSpec type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/certificatesigningrequestapproval.go b/client/applyconfiguration/hypershift/v1beta1/certificatesigningrequestapproval.go index c2749c5a83..5798fbf9ad 100644 --- a/client/applyconfiguration/hypershift/v1beta1/certificatesigningrequestapproval.go +++ b/client/applyconfiguration/hypershift/v1beta1/certificatesigningrequestapproval.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" types "k8s.io/apimachinery/pkg/types" v1 "k8s.io/client-go/applyconfigurations/meta/v1" diff --git a/client/applyconfiguration/hypershift/v1beta1/clusternetworking.go b/client/applyconfiguration/hypershift/v1beta1/clusternetworking.go index 109806683a..5051f97cdc 100644 --- a/client/applyconfiguration/hypershift/v1beta1/clusternetworking.go +++ b/client/applyconfiguration/hypershift/v1beta1/clusternetworking.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // ClusterNetworkingApplyConfiguration represents an declarative configuration of the ClusterNetworking type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/etcdspec.go b/client/applyconfiguration/hypershift/v1beta1/etcdspec.go index a7b1b4d4c0..840435e400 100644 --- a/client/applyconfiguration/hypershift/v1beta1/etcdspec.go +++ b/client/applyconfiguration/hypershift/v1beta1/etcdspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // EtcdSpecApplyConfiguration represents an declarative configuration of the EtcdSpec type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/hostedclusterspec.go b/client/applyconfiguration/hypershift/v1beta1/hostedclusterspec.go index 92399afa23..818c191834 100644 --- a/client/applyconfiguration/hypershift/v1beta1/hostedclusterspec.go +++ b/client/applyconfiguration/hypershift/v1beta1/hostedclusterspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" v1 "k8s.io/api/core/v1" ) diff --git a/client/applyconfiguration/hypershift/v1beta1/hostedcontrolplanespec.go b/client/applyconfiguration/hypershift/v1beta1/hostedcontrolplanespec.go index 65fa3b385f..98fa1c3d9f 100644 --- a/client/applyconfiguration/hypershift/v1beta1/hostedcontrolplanespec.go +++ b/client/applyconfiguration/hypershift/v1beta1/hostedcontrolplanespec.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" v1 "k8s.io/api/core/v1" ) diff --git a/client/applyconfiguration/hypershift/v1beta1/ibmcloudkmsauthspec.go b/client/applyconfiguration/hypershift/v1beta1/ibmcloudkmsauthspec.go index 7f15ad66a6..e9aaa9d44f 100644 --- a/client/applyconfiguration/hypershift/v1beta1/ibmcloudkmsauthspec.go +++ b/client/applyconfiguration/hypershift/v1beta1/ibmcloudkmsauthspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // IBMCloudKMSAuthSpecApplyConfiguration represents an declarative configuration of the IBMCloudKMSAuthSpec type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/kmsspec.go b/client/applyconfiguration/hypershift/v1beta1/kmsspec.go index 55a6148d69..eece69f45e 100644 --- a/client/applyconfiguration/hypershift/v1beta1/kmsspec.go +++ b/client/applyconfiguration/hypershift/v1beta1/kmsspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // KMSSpecApplyConfiguration represents an declarative configuration of the KMSSpec type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/kubevirtcachingstrategy.go b/client/applyconfiguration/hypershift/v1beta1/kubevirtcachingstrategy.go index 67044a230f..bda768c03b 100644 --- a/client/applyconfiguration/hypershift/v1beta1/kubevirtcachingstrategy.go +++ b/client/applyconfiguration/hypershift/v1beta1/kubevirtcachingstrategy.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // KubevirtCachingStrategyApplyConfiguration represents an declarative configuration of the KubevirtCachingStrategy type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/kubevirtcompute.go b/client/applyconfiguration/hypershift/v1beta1/kubevirtcompute.go index 854ade631f..ac2a9d4ece 100644 --- a/client/applyconfiguration/hypershift/v1beta1/kubevirtcompute.go +++ b/client/applyconfiguration/hypershift/v1beta1/kubevirtcompute.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" resource "k8s.io/apimachinery/pkg/api/resource" ) diff --git a/client/applyconfiguration/hypershift/v1beta1/kubevirtnodepoolplatform.go b/client/applyconfiguration/hypershift/v1beta1/kubevirtnodepoolplatform.go index 14f1cfac4b..421cac736f 100644 --- a/client/applyconfiguration/hypershift/v1beta1/kubevirtnodepoolplatform.go +++ b/client/applyconfiguration/hypershift/v1beta1/kubevirtnodepoolplatform.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // KubevirtNodePoolPlatformApplyConfiguration represents an declarative configuration of the KubevirtNodePoolPlatform type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/kubevirtpersistentvolume.go b/client/applyconfiguration/hypershift/v1beta1/kubevirtpersistentvolume.go index e1b0cac64b..420165798b 100644 --- a/client/applyconfiguration/hypershift/v1beta1/kubevirtpersistentvolume.go +++ b/client/applyconfiguration/hypershift/v1beta1/kubevirtpersistentvolume.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" v1 "k8s.io/api/core/v1" resource "k8s.io/apimachinery/pkg/api/resource" ) diff --git a/client/applyconfiguration/hypershift/v1beta1/kubevirtrootvolume.go b/client/applyconfiguration/hypershift/v1beta1/kubevirtrootvolume.go index e2f5c83210..bda9105ba8 100644 --- a/client/applyconfiguration/hypershift/v1beta1/kubevirtrootvolume.go +++ b/client/applyconfiguration/hypershift/v1beta1/kubevirtrootvolume.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // KubevirtRootVolumeApplyConfiguration represents an declarative configuration of the KubevirtRootVolume type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/kubevirtstoragedriverspec.go b/client/applyconfiguration/hypershift/v1beta1/kubevirtstoragedriverspec.go index 3b1f64a23e..974490912d 100644 --- a/client/applyconfiguration/hypershift/v1beta1/kubevirtstoragedriverspec.go +++ b/client/applyconfiguration/hypershift/v1beta1/kubevirtstoragedriverspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // KubevirtStorageDriverSpecApplyConfiguration represents an declarative configuration of the KubevirtStorageDriverSpec type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/kubevirtvolume.go b/client/applyconfiguration/hypershift/v1beta1/kubevirtvolume.go index fd905d0264..78fa0dcedb 100644 --- a/client/applyconfiguration/hypershift/v1beta1/kubevirtvolume.go +++ b/client/applyconfiguration/hypershift/v1beta1/kubevirtvolume.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // KubevirtVolumeApplyConfiguration represents an declarative configuration of the KubevirtVolume type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/managedetcdstoragespec.go b/client/applyconfiguration/hypershift/v1beta1/managedetcdstoragespec.go index b66e4e4463..8c632ef1f7 100644 --- a/client/applyconfiguration/hypershift/v1beta1/managedetcdstoragespec.go +++ b/client/applyconfiguration/hypershift/v1beta1/managedetcdstoragespec.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // ManagedEtcdStorageSpecApplyConfiguration represents an declarative configuration of the ManagedEtcdStorageSpec type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/nodepoolmanagement.go b/client/applyconfiguration/hypershift/v1beta1/nodepoolmanagement.go index bb99708bc8..a23475b359 100644 --- a/client/applyconfiguration/hypershift/v1beta1/nodepoolmanagement.go +++ b/client/applyconfiguration/hypershift/v1beta1/nodepoolmanagement.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // NodePoolManagementApplyConfiguration represents an declarative configuration of the NodePoolManagement type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/nodepoolplatform.go b/client/applyconfiguration/hypershift/v1beta1/nodepoolplatform.go index 04ced93ca0..79393c74ab 100644 --- a/client/applyconfiguration/hypershift/v1beta1/nodepoolplatform.go +++ b/client/applyconfiguration/hypershift/v1beta1/nodepoolplatform.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // NodePoolPlatformApplyConfiguration represents an declarative configuration of the NodePoolPlatform type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/platformspec.go b/client/applyconfiguration/hypershift/v1beta1/platformspec.go index 64e12a8c1f..efc7f9d349 100644 --- a/client/applyconfiguration/hypershift/v1beta1/platformspec.go +++ b/client/applyconfiguration/hypershift/v1beta1/platformspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // PlatformSpecApplyConfiguration represents an declarative configuration of the PlatformSpec type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/powervsnodepoolplatform.go b/client/applyconfiguration/hypershift/v1beta1/powervsnodepoolplatform.go index b3a8e100e0..1e248bfe5e 100644 --- a/client/applyconfiguration/hypershift/v1beta1/powervsnodepoolplatform.go +++ b/client/applyconfiguration/hypershift/v1beta1/powervsnodepoolplatform.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" intstr "k8s.io/apimachinery/pkg/util/intstr" ) diff --git a/client/applyconfiguration/hypershift/v1beta1/replaceupgrade.go b/client/applyconfiguration/hypershift/v1beta1/replaceupgrade.go index 55a46f3118..4411fe53f2 100644 --- a/client/applyconfiguration/hypershift/v1beta1/replaceupgrade.go +++ b/client/applyconfiguration/hypershift/v1beta1/replaceupgrade.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // ReplaceUpgradeApplyConfiguration represents an declarative configuration of the ReplaceUpgrade type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/secretencryptionspec.go b/client/applyconfiguration/hypershift/v1beta1/secretencryptionspec.go index 2c29b60f29..558e494826 100644 --- a/client/applyconfiguration/hypershift/v1beta1/secretencryptionspec.go +++ b/client/applyconfiguration/hypershift/v1beta1/secretencryptionspec.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // SecretEncryptionSpecApplyConfiguration represents an declarative configuration of the SecretEncryptionSpec type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/servicepublishingstrategy.go b/client/applyconfiguration/hypershift/v1beta1/servicepublishingstrategy.go index 8b7db30454..6f47aa7726 100644 --- a/client/applyconfiguration/hypershift/v1beta1/servicepublishingstrategy.go +++ b/client/applyconfiguration/hypershift/v1beta1/servicepublishingstrategy.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // ServicePublishingStrategyApplyConfiguration represents an declarative configuration of the ServicePublishingStrategy type for use diff --git a/client/applyconfiguration/hypershift/v1beta1/servicepublishingstrategymapping.go b/client/applyconfiguration/hypershift/v1beta1/servicepublishingstrategymapping.go index 96e5d258d1..22bfe60303 100644 --- a/client/applyconfiguration/hypershift/v1beta1/servicepublishingstrategymapping.go +++ b/client/applyconfiguration/hypershift/v1beta1/servicepublishingstrategymapping.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // ServicePublishingStrategyMappingApplyConfiguration represents an declarative configuration of the ServicePublishingStrategyMapping type for use diff --git a/client/applyconfiguration/utils.go b/client/applyconfiguration/utils.go index 3f481c48f8..9253101045 100644 --- a/client/applyconfiguration/utils.go +++ b/client/applyconfiguration/utils.go @@ -18,9 +18,9 @@ limitations under the License. package applyconfiguration import ( - v1alpha1 "github.com/openshift/hypershift/api/types/certificates/v1alpha1" - hypershiftv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1alpha1 "github.com/openshift/hypershift/api/certificates/v1alpha1" + hypershiftv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" certificatesv1alpha1 "github.com/openshift/hypershift/client/applyconfiguration/certificates/v1alpha1" applyconfigurationhypershiftv1alpha1 "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1alpha1" hypershiftv1beta1 "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1beta1" diff --git a/client/clientset/clientset/fake/register.go b/client/clientset/clientset/fake/register.go index 2712718c29..056c332d88 100644 --- a/client/clientset/clientset/fake/register.go +++ b/client/clientset/clientset/fake/register.go @@ -18,9 +18,9 @@ limitations under the License. package fake import ( - certificatesv1alpha1 "github.com/openshift/hypershift/api/types/certificates/v1alpha1" - hypershiftv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + certificatesv1alpha1 "github.com/openshift/hypershift/api/certificates/v1alpha1" + hypershiftv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" runtime "k8s.io/apimachinery/pkg/runtime" schema "k8s.io/apimachinery/pkg/runtime/schema" diff --git a/client/clientset/clientset/scheme/register.go b/client/clientset/clientset/scheme/register.go index d5dda67315..92f1e1295a 100644 --- a/client/clientset/clientset/scheme/register.go +++ b/client/clientset/clientset/scheme/register.go @@ -18,9 +18,9 @@ limitations under the License. package scheme import ( - certificatesv1alpha1 "github.com/openshift/hypershift/api/types/certificates/v1alpha1" - hypershiftv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + certificatesv1alpha1 "github.com/openshift/hypershift/api/certificates/v1alpha1" + hypershiftv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" runtime "k8s.io/apimachinery/pkg/runtime" schema "k8s.io/apimachinery/pkg/runtime/schema" diff --git a/client/clientset/clientset/typed/certificates/v1alpha1/certificates_client.go b/client/clientset/clientset/typed/certificates/v1alpha1/certificates_client.go index 8f353dce8e..6fca6b0654 100644 --- a/client/clientset/clientset/typed/certificates/v1alpha1/certificates_client.go +++ b/client/clientset/clientset/typed/certificates/v1alpha1/certificates_client.go @@ -20,7 +20,7 @@ package v1alpha1 import ( "net/http" - v1alpha1 "github.com/openshift/hypershift/api/types/certificates/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/certificates/v1alpha1" "github.com/openshift/hypershift/client/clientset/clientset/scheme" rest "k8s.io/client-go/rest" ) diff --git a/client/clientset/clientset/typed/certificates/v1alpha1/certificatesigningrequestapproval.go b/client/clientset/clientset/typed/certificates/v1alpha1/certificatesigningrequestapproval.go index 45a29147e0..e71feed455 100644 --- a/client/clientset/clientset/typed/certificates/v1alpha1/certificatesigningrequestapproval.go +++ b/client/clientset/clientset/typed/certificates/v1alpha1/certificatesigningrequestapproval.go @@ -23,7 +23,7 @@ import ( "fmt" "time" - v1alpha1 "github.com/openshift/hypershift/api/types/certificates/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/certificates/v1alpha1" certificatesv1alpha1 "github.com/openshift/hypershift/client/applyconfiguration/certificates/v1alpha1" scheme "github.com/openshift/hypershift/client/clientset/clientset/scheme" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/client/clientset/clientset/typed/certificates/v1alpha1/fake/fake_certificatesigningrequestapproval.go b/client/clientset/clientset/typed/certificates/v1alpha1/fake/fake_certificatesigningrequestapproval.go index e9bc5d4ee2..fd365c96c3 100644 --- a/client/clientset/clientset/typed/certificates/v1alpha1/fake/fake_certificatesigningrequestapproval.go +++ b/client/clientset/clientset/typed/certificates/v1alpha1/fake/fake_certificatesigningrequestapproval.go @@ -22,7 +22,7 @@ import ( json "encoding/json" "fmt" - v1alpha1 "github.com/openshift/hypershift/api/types/certificates/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/certificates/v1alpha1" certificatesv1alpha1 "github.com/openshift/hypershift/client/applyconfiguration/certificates/v1alpha1" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" labels "k8s.io/apimachinery/pkg/labels" diff --git a/client/clientset/clientset/typed/hypershift/v1alpha1/fake/fake_hostedcluster.go b/client/clientset/clientset/typed/hypershift/v1alpha1/fake/fake_hostedcluster.go index c74294be9b..5a0eced126 100644 --- a/client/clientset/clientset/typed/hypershift/v1alpha1/fake/fake_hostedcluster.go +++ b/client/clientset/clientset/typed/hypershift/v1alpha1/fake/fake_hostedcluster.go @@ -22,7 +22,7 @@ import ( json "encoding/json" "fmt" - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" hypershiftv1alpha1 "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1alpha1" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" labels "k8s.io/apimachinery/pkg/labels" diff --git a/client/clientset/clientset/typed/hypershift/v1alpha1/fake/fake_nodepool.go b/client/clientset/clientset/typed/hypershift/v1alpha1/fake/fake_nodepool.go index ed814116de..566677cd65 100644 --- a/client/clientset/clientset/typed/hypershift/v1alpha1/fake/fake_nodepool.go +++ b/client/clientset/clientset/typed/hypershift/v1alpha1/fake/fake_nodepool.go @@ -22,7 +22,7 @@ import ( json "encoding/json" "fmt" - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" hypershiftv1alpha1 "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1alpha1" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" labels "k8s.io/apimachinery/pkg/labels" diff --git a/client/clientset/clientset/typed/hypershift/v1alpha1/hostedcluster.go b/client/clientset/clientset/typed/hypershift/v1alpha1/hostedcluster.go index 60af35e788..eb3fd5bdf5 100644 --- a/client/clientset/clientset/typed/hypershift/v1alpha1/hostedcluster.go +++ b/client/clientset/clientset/typed/hypershift/v1alpha1/hostedcluster.go @@ -23,7 +23,7 @@ import ( "fmt" "time" - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" hypershiftv1alpha1 "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1alpha1" scheme "github.com/openshift/hypershift/client/clientset/clientset/scheme" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/client/clientset/clientset/typed/hypershift/v1alpha1/hypershift_client.go b/client/clientset/clientset/typed/hypershift/v1alpha1/hypershift_client.go index 779df39017..6b97d687ae 100644 --- a/client/clientset/clientset/typed/hypershift/v1alpha1/hypershift_client.go +++ b/client/clientset/clientset/typed/hypershift/v1alpha1/hypershift_client.go @@ -20,7 +20,7 @@ package v1alpha1 import ( "net/http" - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" "github.com/openshift/hypershift/client/clientset/clientset/scheme" rest "k8s.io/client-go/rest" ) diff --git a/client/clientset/clientset/typed/hypershift/v1alpha1/nodepool.go b/client/clientset/clientset/typed/hypershift/v1alpha1/nodepool.go index 63f6b569a0..9ed18edc51 100644 --- a/client/clientset/clientset/typed/hypershift/v1alpha1/nodepool.go +++ b/client/clientset/clientset/typed/hypershift/v1alpha1/nodepool.go @@ -23,7 +23,7 @@ import ( "fmt" "time" - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" hypershiftv1alpha1 "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1alpha1" scheme "github.com/openshift/hypershift/client/clientset/clientset/scheme" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/client/clientset/clientset/typed/hypershift/v1beta1/certificatesigningrequestapproval.go b/client/clientset/clientset/typed/hypershift/v1beta1/certificatesigningrequestapproval.go index 76e94af1a1..313ecdd31c 100644 --- a/client/clientset/clientset/typed/hypershift/v1beta1/certificatesigningrequestapproval.go +++ b/client/clientset/clientset/typed/hypershift/v1beta1/certificatesigningrequestapproval.go @@ -23,7 +23,7 @@ import ( "fmt" "time" - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hypershiftv1beta1 "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1beta1" scheme "github.com/openshift/hypershift/client/clientset/clientset/scheme" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_certificatesigningrequestapproval.go b/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_certificatesigningrequestapproval.go index 574b857f58..6d9e62e34d 100644 --- a/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_certificatesigningrequestapproval.go +++ b/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_certificatesigningrequestapproval.go @@ -22,7 +22,7 @@ import ( json "encoding/json" "fmt" - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hypershiftv1beta1 "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1beta1" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" labels "k8s.io/apimachinery/pkg/labels" diff --git a/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_hostedcluster.go b/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_hostedcluster.go index d1be480c9c..569c9acf28 100644 --- a/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_hostedcluster.go +++ b/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_hostedcluster.go @@ -22,7 +22,7 @@ import ( json "encoding/json" "fmt" - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hypershiftv1beta1 "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1beta1" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" labels "k8s.io/apimachinery/pkg/labels" diff --git a/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_hostedcontrolplane.go b/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_hostedcontrolplane.go index 6666b8b66d..2f381b4d3a 100644 --- a/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_hostedcontrolplane.go +++ b/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_hostedcontrolplane.go @@ -22,7 +22,7 @@ import ( json "encoding/json" "fmt" - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hypershiftv1beta1 "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1beta1" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" labels "k8s.io/apimachinery/pkg/labels" diff --git a/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_nodepool.go b/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_nodepool.go index 257abf290e..4d15f10169 100644 --- a/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_nodepool.go +++ b/client/clientset/clientset/typed/hypershift/v1beta1/fake/fake_nodepool.go @@ -22,7 +22,7 @@ import ( json "encoding/json" "fmt" - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hypershiftv1beta1 "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1beta1" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" labels "k8s.io/apimachinery/pkg/labels" diff --git a/client/clientset/clientset/typed/hypershift/v1beta1/hostedcluster.go b/client/clientset/clientset/typed/hypershift/v1beta1/hostedcluster.go index 22d2e0ce1c..e4eff190c0 100644 --- a/client/clientset/clientset/typed/hypershift/v1beta1/hostedcluster.go +++ b/client/clientset/clientset/typed/hypershift/v1beta1/hostedcluster.go @@ -23,7 +23,7 @@ import ( "fmt" "time" - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hypershiftv1beta1 "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1beta1" scheme "github.com/openshift/hypershift/client/clientset/clientset/scheme" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/client/clientset/clientset/typed/hypershift/v1beta1/hostedcontrolplane.go b/client/clientset/clientset/typed/hypershift/v1beta1/hostedcontrolplane.go index e5903ef396..d838e1e960 100644 --- a/client/clientset/clientset/typed/hypershift/v1beta1/hostedcontrolplane.go +++ b/client/clientset/clientset/typed/hypershift/v1beta1/hostedcontrolplane.go @@ -23,7 +23,7 @@ import ( "fmt" "time" - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hypershiftv1beta1 "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1beta1" scheme "github.com/openshift/hypershift/client/clientset/clientset/scheme" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/client/clientset/clientset/typed/hypershift/v1beta1/hypershift_client.go b/client/clientset/clientset/typed/hypershift/v1beta1/hypershift_client.go index fb21c4de5d..7ce2da0f94 100644 --- a/client/clientset/clientset/typed/hypershift/v1beta1/hypershift_client.go +++ b/client/clientset/clientset/typed/hypershift/v1beta1/hypershift_client.go @@ -20,7 +20,7 @@ package v1beta1 import ( "net/http" - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/client/clientset/clientset/scheme" rest "k8s.io/client-go/rest" ) diff --git a/client/clientset/clientset/typed/hypershift/v1beta1/nodepool.go b/client/clientset/clientset/typed/hypershift/v1beta1/nodepool.go index 6c0d338997..d8dc3b5f9e 100644 --- a/client/clientset/clientset/typed/hypershift/v1beta1/nodepool.go +++ b/client/clientset/clientset/typed/hypershift/v1beta1/nodepool.go @@ -23,7 +23,7 @@ import ( "fmt" "time" - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hypershiftv1beta1 "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1beta1" scheme "github.com/openshift/hypershift/client/clientset/clientset/scheme" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/client/informers/externalversions/certificates/v1alpha1/certificatesigningrequestapproval.go b/client/informers/externalversions/certificates/v1alpha1/certificatesigningrequestapproval.go index 30340a0363..98eda861a8 100644 --- a/client/informers/externalversions/certificates/v1alpha1/certificatesigningrequestapproval.go +++ b/client/informers/externalversions/certificates/v1alpha1/certificatesigningrequestapproval.go @@ -21,7 +21,7 @@ import ( "context" time "time" - certificatesv1alpha1 "github.com/openshift/hypershift/api/types/certificates/v1alpha1" + certificatesv1alpha1 "github.com/openshift/hypershift/api/certificates/v1alpha1" clientset "github.com/openshift/hypershift/client/clientset/clientset" internalinterfaces "github.com/openshift/hypershift/client/informers/externalversions/internalinterfaces" v1alpha1 "github.com/openshift/hypershift/client/listers/certificates/v1alpha1" diff --git a/client/informers/externalversions/generic.go b/client/informers/externalversions/generic.go index dc8ab99c38..4d00511a41 100644 --- a/client/informers/externalversions/generic.go +++ b/client/informers/externalversions/generic.go @@ -20,9 +20,9 @@ package externalversions import ( "fmt" - v1alpha1 "github.com/openshift/hypershift/api/types/certificates/v1alpha1" - hypershiftv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1alpha1 "github.com/openshift/hypershift/api/certificates/v1alpha1" + hypershiftv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" schema "k8s.io/apimachinery/pkg/runtime/schema" cache "k8s.io/client-go/tools/cache" ) diff --git a/client/informers/externalversions/hypershift/v1alpha1/hostedcluster.go b/client/informers/externalversions/hypershift/v1alpha1/hostedcluster.go index 48307ba675..c4d4221dfd 100644 --- a/client/informers/externalversions/hypershift/v1alpha1/hostedcluster.go +++ b/client/informers/externalversions/hypershift/v1alpha1/hostedcluster.go @@ -21,7 +21,7 @@ import ( "context" time "time" - hypershiftv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + hypershiftv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" clientset "github.com/openshift/hypershift/client/clientset/clientset" internalinterfaces "github.com/openshift/hypershift/client/informers/externalversions/internalinterfaces" v1alpha1 "github.com/openshift/hypershift/client/listers/hypershift/v1alpha1" diff --git a/client/informers/externalversions/hypershift/v1alpha1/nodepool.go b/client/informers/externalversions/hypershift/v1alpha1/nodepool.go index f40a6fe307..8f9f3dc2ab 100644 --- a/client/informers/externalversions/hypershift/v1alpha1/nodepool.go +++ b/client/informers/externalversions/hypershift/v1alpha1/nodepool.go @@ -21,7 +21,7 @@ import ( "context" time "time" - hypershiftv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + hypershiftv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" clientset "github.com/openshift/hypershift/client/clientset/clientset" internalinterfaces "github.com/openshift/hypershift/client/informers/externalversions/internalinterfaces" v1alpha1 "github.com/openshift/hypershift/client/listers/hypershift/v1alpha1" diff --git a/client/informers/externalversions/hypershift/v1beta1/certificatesigningrequestapproval.go b/client/informers/externalversions/hypershift/v1beta1/certificatesigningrequestapproval.go index bad1d0df5f..bd82a48460 100644 --- a/client/informers/externalversions/hypershift/v1beta1/certificatesigningrequestapproval.go +++ b/client/informers/externalversions/hypershift/v1beta1/certificatesigningrequestapproval.go @@ -21,7 +21,7 @@ import ( "context" time "time" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" clientset "github.com/openshift/hypershift/client/clientset/clientset" internalinterfaces "github.com/openshift/hypershift/client/informers/externalversions/internalinterfaces" v1beta1 "github.com/openshift/hypershift/client/listers/hypershift/v1beta1" diff --git a/client/informers/externalversions/hypershift/v1beta1/hostedcluster.go b/client/informers/externalversions/hypershift/v1beta1/hostedcluster.go index e4200679a8..1432ad978a 100644 --- a/client/informers/externalversions/hypershift/v1beta1/hostedcluster.go +++ b/client/informers/externalversions/hypershift/v1beta1/hostedcluster.go @@ -21,7 +21,7 @@ import ( "context" time "time" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" clientset "github.com/openshift/hypershift/client/clientset/clientset" internalinterfaces "github.com/openshift/hypershift/client/informers/externalversions/internalinterfaces" v1beta1 "github.com/openshift/hypershift/client/listers/hypershift/v1beta1" diff --git a/client/informers/externalversions/hypershift/v1beta1/hostedcontrolplane.go b/client/informers/externalversions/hypershift/v1beta1/hostedcontrolplane.go index 34f51c398e..2da1f3feab 100644 --- a/client/informers/externalversions/hypershift/v1beta1/hostedcontrolplane.go +++ b/client/informers/externalversions/hypershift/v1beta1/hostedcontrolplane.go @@ -21,7 +21,7 @@ import ( "context" time "time" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" clientset "github.com/openshift/hypershift/client/clientset/clientset" internalinterfaces "github.com/openshift/hypershift/client/informers/externalversions/internalinterfaces" v1beta1 "github.com/openshift/hypershift/client/listers/hypershift/v1beta1" diff --git a/client/informers/externalversions/hypershift/v1beta1/nodepool.go b/client/informers/externalversions/hypershift/v1beta1/nodepool.go index 5466d818cb..9572114de8 100644 --- a/client/informers/externalversions/hypershift/v1beta1/nodepool.go +++ b/client/informers/externalversions/hypershift/v1beta1/nodepool.go @@ -21,7 +21,7 @@ import ( "context" time "time" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" clientset "github.com/openshift/hypershift/client/clientset/clientset" internalinterfaces "github.com/openshift/hypershift/client/informers/externalversions/internalinterfaces" v1beta1 "github.com/openshift/hypershift/client/listers/hypershift/v1beta1" diff --git a/client/listers/certificates/v1alpha1/certificatesigningrequestapproval.go b/client/listers/certificates/v1alpha1/certificatesigningrequestapproval.go index aa5bb0d0b5..97f0325de1 100644 --- a/client/listers/certificates/v1alpha1/certificatesigningrequestapproval.go +++ b/client/listers/certificates/v1alpha1/certificatesigningrequestapproval.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/certificates/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/certificates/v1alpha1" "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/labels" "k8s.io/client-go/tools/cache" diff --git a/client/listers/hypershift/v1alpha1/hostedcluster.go b/client/listers/hypershift/v1alpha1/hostedcluster.go index 2e359b8c0e..be00b44340 100644 --- a/client/listers/hypershift/v1alpha1/hostedcluster.go +++ b/client/listers/hypershift/v1alpha1/hostedcluster.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/labels" "k8s.io/client-go/tools/cache" diff --git a/client/listers/hypershift/v1alpha1/nodepool.go b/client/listers/hypershift/v1alpha1/nodepool.go index 489b8a9268..5298d2fab5 100644 --- a/client/listers/hypershift/v1alpha1/nodepool.go +++ b/client/listers/hypershift/v1alpha1/nodepool.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - v1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + v1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/labels" "k8s.io/client-go/tools/cache" diff --git a/client/listers/hypershift/v1beta1/certificatesigningrequestapproval.go b/client/listers/hypershift/v1beta1/certificatesigningrequestapproval.go index 1c8a14fc08..2a1ca77486 100644 --- a/client/listers/hypershift/v1beta1/certificatesigningrequestapproval.go +++ b/client/listers/hypershift/v1beta1/certificatesigningrequestapproval.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/labels" "k8s.io/client-go/tools/cache" diff --git a/client/listers/hypershift/v1beta1/hostedcluster.go b/client/listers/hypershift/v1beta1/hostedcluster.go index 2c14c3c842..4c5be8485e 100644 --- a/client/listers/hypershift/v1beta1/hostedcluster.go +++ b/client/listers/hypershift/v1beta1/hostedcluster.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/labels" "k8s.io/client-go/tools/cache" diff --git a/client/listers/hypershift/v1beta1/hostedcontrolplane.go b/client/listers/hypershift/v1beta1/hostedcontrolplane.go index d8fd2e2f98..fdc1e71c47 100644 --- a/client/listers/hypershift/v1beta1/hostedcontrolplane.go +++ b/client/listers/hypershift/v1beta1/hostedcontrolplane.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/labels" "k8s.io/client-go/tools/cache" diff --git a/client/listers/hypershift/v1beta1/nodepool.go b/client/listers/hypershift/v1beta1/nodepool.go index e6e8c788c4..315aa049d3 100644 --- a/client/listers/hypershift/v1beta1/nodepool.go +++ b/client/listers/hypershift/v1beta1/nodepool.go @@ -18,7 +18,7 @@ limitations under the License. package v1beta1 import ( - v1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + v1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/labels" "k8s.io/client-go/tools/cache" diff --git a/cmd/bastion/aws/create.go b/cmd/bastion/aws/create.go index 49f1d80410..42db86b75f 100644 --- a/cmd/bastion/aws/create.go +++ b/cmd/bastion/aws/create.go @@ -17,7 +17,7 @@ import ( "k8s.io/apimachinery/pkg/util/wait" "k8s.io/client-go/util/retry" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" awsutil "github.com/openshift/hypershift/cmd/infra/aws/util" "github.com/openshift/hypershift/cmd/util" ) diff --git a/cmd/bastion/aws/destroy.go b/cmd/bastion/aws/destroy.go index fee242dc7c..eafc411564 100644 --- a/cmd/bastion/aws/destroy.go +++ b/cmd/bastion/aws/destroy.go @@ -12,7 +12,7 @@ import ( "k8s.io/apimachinery/pkg/types" "k8s.io/apimachinery/pkg/util/wait" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" awsutil "github.com/openshift/hypershift/cmd/infra/aws/util" "github.com/openshift/hypershift/cmd/util" ) diff --git a/cmd/cluster/aws/create.go b/cmd/cluster/aws/create.go index e91f98e0b3..3bab999313 100644 --- a/cmd/cluster/aws/create.go +++ b/cmd/cluster/aws/create.go @@ -6,7 +6,7 @@ import ( "fmt" "os" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" awsinfra "github.com/openshift/hypershift/cmd/infra/aws" "github.com/openshift/hypershift/cmd/util" diff --git a/cmd/cluster/azure/create.go b/cmd/cluster/azure/create.go index 367ea955e5..ab7cda5469 100644 --- a/cmd/cluster/azure/create.go +++ b/cmd/cluster/azure/create.go @@ -7,7 +7,7 @@ import ( "os" "strings" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" azureinfra "github.com/openshift/hypershift/cmd/infra/azure" apifixtures "github.com/openshift/hypershift/examples/fixtures" diff --git a/cmd/cluster/cluster.go b/cmd/cluster/cluster.go index fe2b6d0b65..2184e5d81c 100644 --- a/cmd/cluster/cluster.go +++ b/cmd/cluster/cluster.go @@ -3,7 +3,7 @@ package cluster import ( "time" - "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/spf13/cobra" diff --git a/cmd/cluster/core/create.go b/cmd/cluster/core/create.go index 267d52f763..92ad5fdbe7 100644 --- a/cmd/cluster/core/create.go +++ b/cmd/cluster/core/create.go @@ -25,7 +25,7 @@ import ( "github.com/blang/semver" "github.com/go-logr/logr" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/util" "github.com/openshift/hypershift/cmd/version" apifixtures "github.com/openshift/hypershift/examples/fixtures" diff --git a/cmd/cluster/core/destroy.go b/cmd/cluster/core/destroy.go index 84116e2c32..0ee4ceeadb 100644 --- a/cmd/cluster/core/destroy.go +++ b/cmd/cluster/core/destroy.go @@ -7,7 +7,7 @@ import ( "time" "github.com/go-logr/logr" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/util" v1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/api/equality" diff --git a/cmd/cluster/core/dump.go b/cmd/cluster/core/dump.go index 1b9d47ac44..6e4fe89522 100644 --- a/cmd/cluster/core/dump.go +++ b/cmd/cluster/core/dump.go @@ -40,7 +40,7 @@ import ( capiv1 "sigs.k8s.io/cluster-api/api/v1beta1" "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/log" "github.com/openshift/hypershift/cmd/util" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" diff --git a/cmd/cluster/kubevirt/create.go b/cmd/cluster/kubevirt/create.go index 83eea5705a..5b75c3a4d1 100644 --- a/cmd/cluster/kubevirt/create.go +++ b/cmd/cluster/kubevirt/create.go @@ -9,7 +9,7 @@ import ( "github.com/spf13/cobra" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" "github.com/openshift/hypershift/cmd/cluster/kubevirt/params" apifixtures "github.com/openshift/hypershift/examples/fixtures" diff --git a/cmd/cluster/kubevirt/create_test.go b/cmd/cluster/kubevirt/create_test.go index 3857211737..9f75588dfa 100644 --- a/cmd/cluster/kubevirt/create_test.go +++ b/cmd/cluster/kubevirt/create_test.go @@ -7,7 +7,7 @@ import ( . "github.com/onsi/gomega" "k8s.io/utils/pointer" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" apifixtures "github.com/openshift/hypershift/examples/fixtures" ) diff --git a/cmd/cluster/powervs/create.go b/cmd/cluster/powervs/create.go index 4a8a72a40d..dc53d5fd95 100644 --- a/cmd/cluster/powervs/create.go +++ b/cmd/cluster/powervs/create.go @@ -8,7 +8,7 @@ import ( "os/signal" "syscall" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" powervsinfra "github.com/openshift/hypershift/cmd/infra/powervs" apifixtures "github.com/openshift/hypershift/examples/fixtures" diff --git a/cmd/consolelogs/aws/getlogs.go b/cmd/consolelogs/aws/getlogs.go index 7d38e10f2c..12f49be9f1 100644 --- a/cmd/consolelogs/aws/getlogs.go +++ b/cmd/consolelogs/aws/getlogs.go @@ -14,7 +14,7 @@ import ( "k8s.io/apimachinery/pkg/types" utilerrors "k8s.io/apimachinery/pkg/util/errors" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" awsutil "github.com/openshift/hypershift/cmd/infra/aws/util" "github.com/openshift/hypershift/cmd/log" "github.com/openshift/hypershift/cmd/util" diff --git a/cmd/infra/aws/create_iam.go b/cmd/infra/aws/create_iam.go index bf8fb3dd80..e5d5d0331a 100644 --- a/cmd/infra/aws/create_iam.go +++ b/cmd/infra/aws/create_iam.go @@ -16,7 +16,7 @@ import ( crclient "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" awsutil "github.com/openshift/hypershift/cmd/infra/aws/util" "github.com/openshift/hypershift/cmd/log" "github.com/openshift/hypershift/cmd/util" diff --git a/cmd/install/assets/cluster-api-provider-ibmcloud/infrastructure.cluster.x-k8s.io_ibmvpcclusters.yaml b/cmd/install/assets/cluster-api-provider-ibmcloud/infrastructure.cluster.x-k8s.io_ibmvpcclusters.yaml index 90cf6b0d06..d344e9e786 100644 --- a/cmd/install/assets/cluster-api-provider-ibmcloud/infrastructure.cluster.x-k8s.io_ibmvpcclusters.yaml +++ b/cmd/install/assets/cluster-api-provider-ibmcloud/infrastructure.cluster.x-k8s.io_ibmvpcclusters.yaml @@ -184,6 +184,8 @@ spec: address: type: string floatingIPID: + description: 'Deprecated: This field has no function and is going + to be removed in the next release.' type: string loadBalancerIPID: type: string @@ -364,6 +366,8 @@ spec: address: type: string floatingIPID: + description: 'Deprecated: This field has no function and is going + to be removed in the next release.' type: string loadBalancerIPID: type: string diff --git a/cmd/install/assets/cluster-api/cluster.x-k8s.io_clusterclasses.yaml b/cmd/install/assets/cluster-api/cluster.x-k8s.io_clusterclasses.yaml index f84bd9349d..4a4afc49eb 100644 --- a/cmd/install/assets/cluster-api/cluster.x-k8s.io_clusterclasses.yaml +++ b/cmd/install/assets/cluster-api/cluster.x-k8s.io_clusterclasses.yaml @@ -497,7 +497,6 @@ spec: type: string type: array type: object -<<<<<<< HEAD machinePoolClass: description: |- MachinePoolClass selects templates referenced in specific MachinePoolClasses in @@ -510,8 +509,6 @@ spec: type: string type: array type: object -======= ->>>>>>> fe0c9b3f6 (HOSTEDCP-336: Hypershift API separation) type: object required: - apiVersion @@ -971,13 +968,9 @@ spec: x-kubernetes-int-or-string: true type: object type: -<<<<<<< HEAD description: |- Type of deployment. Allowed values are RollingUpdate and OnDelete. The default is RollingUpdate. -======= - description: Type of deployment. Default is RollingUpdate. ->>>>>>> fe0c9b3f6 (HOSTEDCP-336: Hypershift API separation) enum: - RollingUpdate - OnDelete @@ -1129,7 +1122,6 @@ spec: - template type: object type: array -<<<<<<< HEAD machinePools: description: |- MachinePools is a list of machine pool classes that can be used to create @@ -1344,8 +1336,6 @@ spec: - template type: object type: array -======= ->>>>>>> fe0c9b3f6 (HOSTEDCP-336: Hypershift API separation) type: object type: object status: diff --git a/cmd/install/assets/cluster-api/cluster.x-k8s.io_clusters.yaml b/cmd/install/assets/cluster-api/cluster.x-k8s.io_clusters.yaml index a612d6a4be..bcf8523db0 100644 --- a/cmd/install/assets/cluster-api/cluster.x-k8s.io_clusters.yaml +++ b/cmd/install/assets/cluster-api/cluster.x-k8s.io_clusters.yaml @@ -19,6 +19,11 @@ spec: scope: Namespaced versions: - additionalPrinterColumns: + - description: ClusterClass of this Cluster, empty if the Cluster is not using + a ClusterClass + jsonPath: .spec.topology.class + name: ClusterClass + type: string - description: Cluster status such as Pending/Provisioning/Provisioned/Deleting/Failed jsonPath: .status.phase name: Phase @@ -700,13 +705,9 @@ spec: x-kubernetes-int-or-string: true type: object type: -<<<<<<< HEAD description: |- Type of deployment. Allowed values are RollingUpdate and OnDelete. The default is RollingUpdate. -======= - description: Type of deployment. Default is RollingUpdate. ->>>>>>> fe0c9b3f6 (HOSTEDCP-336: Hypershift API separation) enum: - RollingUpdate - OnDelete @@ -755,7 +756,6 @@ spec: - name type: object type: array -<<<<<<< HEAD machinePools: description: MachinePools is a list of machine pools in the cluster. @@ -884,8 +884,6 @@ spec: - name type: object type: array -======= ->>>>>>> fe0c9b3f6 (HOSTEDCP-336: Hypershift API separation) type: object required: - class diff --git a/cmd/install/assets/cluster-api/cluster.x-k8s.io_machinedeployments.yaml b/cmd/install/assets/cluster-api/cluster.x-k8s.io_machinedeployments.yaml index d10df5751e..de60bab6b5 100644 --- a/cmd/install/assets/cluster-api/cluster.x-k8s.io_machinedeployments.yaml +++ b/cmd/install/assets/cluster-api/cluster.x-k8s.io_machinedeployments.yaml @@ -250,13 +250,9 @@ spec: x-kubernetes-int-or-string: true type: object type: -<<<<<<< HEAD description: |- Type of deployment. Allowed values are RollingUpdate and OnDelete. The default is RollingUpdate. -======= - description: Type of deployment. Default is RollingUpdate. ->>>>>>> fe0c9b3f6 (HOSTEDCP-336: Hypershift API separation) enum: - RollingUpdate - OnDelete diff --git a/cmd/install/assets/hypershift_operator.go b/cmd/install/assets/hypershift_operator.go index 29ee03024f..ec83899a75 100644 --- a/cmd/install/assets/hypershift_operator.go +++ b/cmd/install/assets/hypershift_operator.go @@ -6,7 +6,7 @@ import ( "time" "github.com/google/uuid" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/pkg/version" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/images" diff --git a/cmd/install/assets/hypershift_operator_test.go b/cmd/install/assets/hypershift_operator_test.go index 23cdbe7a0a..a657dbd267 100644 --- a/cmd/install/assets/hypershift_operator_test.go +++ b/cmd/install/assets/hypershift_operator_test.go @@ -5,7 +5,7 @@ import ( "testing" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) diff --git a/cmd/install/install.go b/cmd/install/install.go index 608c34d082..cd4116893c 100644 --- a/cmd/install/install.go +++ b/cmd/install/install.go @@ -38,7 +38,7 @@ import ( "sigs.k8s.io/controller-runtime/pkg/client/apiutil" imageapi "github.com/openshift/api/image/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/install/assets" "github.com/openshift/hypershift/cmd/util" "github.com/openshift/hypershift/cmd/version" diff --git a/cmd/install/install_test.go b/cmd/install/install_test.go index 7f1ca450db..6d95673ad8 100644 --- a/cmd/install/install_test.go +++ b/cmd/install/install_test.go @@ -4,7 +4,7 @@ import ( "testing" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func TestOptions_Validate(t *testing.T) { diff --git a/cmd/kubeconfig/create.go b/cmd/kubeconfig/create.go index e95cdf5e08..adaf181fa1 100644 --- a/cmd/kubeconfig/create.go +++ b/cmd/kubeconfig/create.go @@ -16,7 +16,7 @@ import ( "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/yaml" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/util" ) diff --git a/cmd/nodepool/agent/create.go b/cmd/nodepool/agent/create.go index b603cfafe9..4a9748af3e 100644 --- a/cmd/nodepool/agent/create.go +++ b/cmd/nodepool/agent/create.go @@ -7,7 +7,7 @@ import ( "github.com/spf13/cobra" crclient "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/nodepool/core" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) diff --git a/cmd/nodepool/aws/create.go b/cmd/nodepool/aws/create.go index dbe1b138a9..d139c8a96e 100644 --- a/cmd/nodepool/aws/create.go +++ b/cmd/nodepool/aws/create.go @@ -4,7 +4,7 @@ import ( "context" "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/nodepool/core" "github.com/spf13/cobra" crclient "sigs.k8s.io/controller-runtime/pkg/client" diff --git a/cmd/nodepool/azure/create.go b/cmd/nodepool/azure/create.go index 58fa7bcfbe..c48bfd2f16 100644 --- a/cmd/nodepool/azure/create.go +++ b/cmd/nodepool/azure/create.go @@ -4,7 +4,7 @@ import ( "context" "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/nodepool/core" "github.com/spf13/cobra" diff --git a/cmd/nodepool/core/create.go b/cmd/nodepool/core/create.go index 411fbf58da..1fd71bb0dc 100644 --- a/cmd/nodepool/core/create.go +++ b/cmd/nodepool/core/create.go @@ -5,7 +5,7 @@ import ( "fmt" "os" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/log" "github.com/openshift/hypershift/cmd/util" hyperapi "github.com/openshift/hypershift/support/api" diff --git a/cmd/nodepool/create.go b/cmd/nodepool/create.go index cbc2450b54..16bef86914 100644 --- a/cmd/nodepool/create.go +++ b/cmd/nodepool/create.go @@ -1,7 +1,7 @@ package nodepool import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/spf13/cobra" "github.com/openshift/hypershift/cmd/nodepool/agent" diff --git a/cmd/nodepool/kubevirt/create.go b/cmd/nodepool/kubevirt/create.go index 1ddafc30f6..d9e8c87835 100644 --- a/cmd/nodepool/kubevirt/create.go +++ b/cmd/nodepool/kubevirt/create.go @@ -8,7 +8,7 @@ import ( "github.com/spf13/cobra" crclient "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/nodepool/core" ) diff --git a/cmd/nodepool/powervs/create.go b/cmd/nodepool/powervs/create.go index f65da4d22a..816f4ee206 100644 --- a/cmd/nodepool/powervs/create.go +++ b/cmd/nodepool/powervs/create.go @@ -11,7 +11,7 @@ import ( "k8s.io/apimachinery/pkg/util/intstr" crclient "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/log" "github.com/openshift/hypershift/cmd/nodepool/core" ) diff --git a/cmd/util/v1alpha1_wrapper.go b/cmd/util/v1alpha1_wrapper.go index f370596a96..358bfad53c 100644 --- a/cmd/util/v1alpha1_wrapper.go +++ b/cmd/util/v1alpha1_wrapper.go @@ -4,8 +4,8 @@ import ( "context" "fmt" - hyperv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/conversion" "k8s.io/apimachinery/pkg/api/meta" "k8s.io/apimachinery/pkg/runtime" diff --git a/contrib/admission-tracer/main.go b/contrib/admission-tracer/main.go index 829ed2f9ba..fc6823ceb9 100644 --- a/contrib/admission-tracer/main.go +++ b/contrib/admission-tracer/main.go @@ -8,7 +8,7 @@ import ( "net/http" "github.com/google/go-cmp/cmp" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hyperapi "github.com/openshift/hypershift/support/api" ctrl "sigs.k8s.io/controller-runtime" diff --git a/control-plane-operator/controllers/awsprivatelink/awsprivatelink_controller.go b/control-plane-operator/controllers/awsprivatelink/awsprivatelink_controller.go index 3f18a59395..941f99d171 100644 --- a/control-plane-operator/controllers/awsprivatelink/awsprivatelink_controller.go +++ b/control-plane-operator/controllers/awsprivatelink/awsprivatelink_controller.go @@ -38,7 +38,7 @@ import ( "sigs.k8s.io/controller-runtime/pkg/reconcile" "sigs.k8s.io/controller-runtime/pkg/source" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" awsutil "github.com/openshift/hypershift/cmd/infra/aws/util" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/config" diff --git a/control-plane-operator/controllers/awsprivatelink/awsprivatelink_controller_test.go b/control-plane-operator/controllers/awsprivatelink/awsprivatelink_controller_test.go index ad1cd0f8f9..6011ca25e5 100644 --- a/control-plane-operator/controllers/awsprivatelink/awsprivatelink_controller_test.go +++ b/control-plane-operator/controllers/awsprivatelink/awsprivatelink_controller_test.go @@ -5,7 +5,7 @@ import ( "testing" "github.com/google/go-cmp/cmp" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) diff --git a/control-plane-operator/controllers/hostedcontrolplane/autoscaler/reconcile.go b/control-plane-operator/controllers/hostedcontrolplane/autoscaler/reconcile.go index 0c15068c9b..500f6c80e0 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/autoscaler/reconcile.go +++ b/control-plane-operator/controllers/hostedcontrolplane/autoscaler/reconcile.go @@ -4,7 +4,7 @@ import ( "context" "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/kas" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/controlplaneoperator" diff --git a/control-plane-operator/controllers/hostedcontrolplane/cco/reconcile.go b/control-plane-operator/controllers/hostedcontrolplane/cco/reconcile.go index a0891bfd33..c92a874ee6 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/cco/reconcile.go +++ b/control-plane-operator/controllers/hostedcontrolplane/cco/reconcile.go @@ -10,7 +10,7 @@ import ( "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/utils/pointer" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/kas" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" diff --git a/control-plane-operator/controllers/hostedcontrolplane/cco/reconcile_test.go b/control-plane-operator/controllers/hostedcontrolplane/cco/reconcile_test.go index 623c7d4985..916ba69953 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/cco/reconcile_test.go +++ b/control-plane-operator/controllers/hostedcontrolplane/cco/reconcile_test.go @@ -3,7 +3,7 @@ package cco import ( "testing" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" hyperapi "github.com/openshift/hypershift/support/api" diff --git a/control-plane-operator/controllers/hostedcontrolplane/cloud/aws/params.go b/control-plane-operator/controllers/hostedcontrolplane/cloud/aws/params.go index b51ec1c6de..c2b85a7f4f 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/cloud/aws/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/cloud/aws/params.go @@ -6,7 +6,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/utils/pointer" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/config" ) diff --git a/control-plane-operator/controllers/hostedcontrolplane/cloud/aws/reconcile.go b/control-plane-operator/controllers/hostedcontrolplane/cloud/aws/reconcile.go index 464ed74399..96dd901e49 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/cloud/aws/reconcile.go +++ b/control-plane-operator/controllers/hostedcontrolplane/cloud/aws/reconcile.go @@ -2,9 +2,10 @@ package aws import ( "fmt" + k8sutilspointer "k8s.io/utils/pointer" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/controlplaneoperator" diff --git a/control-plane-operator/controllers/hostedcontrolplane/cloud/azure/params.go b/control-plane-operator/controllers/hostedcontrolplane/cloud/azure/params.go index 76b19ff3f5..27073cd9b9 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/cloud/azure/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/cloud/azure/params.go @@ -1,7 +1,7 @@ package azure import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/config" corev1 "k8s.io/api/core/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/cloud/azure/providerconfig.go b/control-plane-operator/controllers/hostedcontrolplane/cloud/azure/providerconfig.go index ff9450f62e..e38df3c93c 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/cloud/azure/providerconfig.go +++ b/control-plane-operator/controllers/hostedcontrolplane/cloud/azure/providerconfig.go @@ -4,7 +4,7 @@ import ( "encoding/json" "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" corev1 "k8s.io/api/core/v1" ) diff --git a/control-plane-operator/controllers/hostedcontrolplane/cloud/azure/reconcile.go b/control-plane-operator/controllers/hostedcontrolplane/cloud/azure/reconcile.go index 9577d052e7..c9e4d3a0b0 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/cloud/azure/reconcile.go +++ b/control-plane-operator/controllers/hostedcontrolplane/cloud/azure/reconcile.go @@ -3,7 +3,7 @@ package azure import ( "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/controlplaneoperator" diff --git a/control-plane-operator/controllers/hostedcontrolplane/cloud/kubevirt/providerconfig.go b/control-plane-operator/controllers/hostedcontrolplane/cloud/kubevirt/providerconfig.go index ece3a2284b..11a1145843 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/cloud/kubevirt/providerconfig.go +++ b/control-plane-operator/controllers/hostedcontrolplane/cloud/kubevirt/providerconfig.go @@ -1,7 +1,7 @@ package kubevirt import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "gopkg.in/yaml.v2" ) diff --git a/control-plane-operator/controllers/hostedcontrolplane/cloud/kubevirt/reconcile.go b/control-plane-operator/controllers/hostedcontrolplane/cloud/kubevirt/reconcile.go index 2aa023ca81..b2f77754bf 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/cloud/kubevirt/reconcile.go +++ b/control-plane-operator/controllers/hostedcontrolplane/cloud/kubevirt/reconcile.go @@ -3,7 +3,7 @@ package kubevirt import ( "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/common" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" diff --git a/control-plane-operator/controllers/hostedcontrolplane/cloud/powervs/powervs.go b/control-plane-operator/controllers/hostedcontrolplane/cloud/powervs/powervs.go index 4a22462a15..e32fe7b05b 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/cloud/powervs/powervs.go +++ b/control-plane-operator/controllers/hostedcontrolplane/cloud/powervs/powervs.go @@ -12,7 +12,7 @@ import ( "k8s.io/apimachinery/pkg/util/intstr" utilpointer "k8s.io/utils/pointer" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" supportconfig "github.com/openshift/hypershift/support/config" diff --git a/control-plane-operator/controllers/hostedcontrolplane/clusterpolicy/deployment.go b/control-plane-operator/controllers/hostedcontrolplane/clusterpolicy/deployment.go index 9685f212c4..415cb5697b 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/clusterpolicy/deployment.go +++ b/control-plane-operator/controllers/hostedcontrolplane/clusterpolicy/deployment.go @@ -3,7 +3,7 @@ package clusterpolicy import ( "path" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/clusterpolicy/params.go b/control-plane-operator/controllers/hostedcontrolplane/clusterpolicy/params.go index 6628292966..f547c6e582 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/clusterpolicy/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/clusterpolicy/params.go @@ -5,7 +5,7 @@ import ( "k8s.io/apimachinery/pkg/api/resource" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/util" diff --git a/control-plane-operator/controllers/hostedcontrolplane/cno/clusternetworkoperator.go b/control-plane-operator/controllers/hostedcontrolplane/cno/clusternetworkoperator.go index 6fe9a8d3b1..26d2f39f00 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/cno/clusternetworkoperator.go +++ b/control-plane-operator/controllers/hostedcontrolplane/cno/clusternetworkoperator.go @@ -12,7 +12,7 @@ import ( "github.com/blang/semver" routev1 "github.com/openshift/api/route/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/awsprivatelink" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/common" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" diff --git a/control-plane-operator/controllers/hostedcontrolplane/cno/clusternetworkoperator_test.go b/control-plane-operator/controllers/hostedcontrolplane/cno/clusternetworkoperator_test.go index 7e674bf5e2..cb1c5918c6 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/cno/clusternetworkoperator_test.go +++ b/control-plane-operator/controllers/hostedcontrolplane/cno/clusternetworkoperator_test.go @@ -6,7 +6,7 @@ import ( . "github.com/onsi/gomega" routev1 "github.com/openshift/api/route/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/config" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/configoperator/params.go b/control-plane-operator/controllers/hostedcontrolplane/configoperator/params.go index baf0c7583f..1785a485cf 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/configoperator/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/configoperator/params.go @@ -9,7 +9,7 @@ import ( "k8s.io/apimachinery/pkg/api/resource" "k8s.io/apimachinery/pkg/util/intstr" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/util" diff --git a/control-plane-operator/controllers/hostedcontrolplane/configoperator/reconcile.go b/control-plane-operator/controllers/hostedcontrolplane/configoperator/reconcile.go index d74b2df0b2..17ee2cd194 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/configoperator/reconcile.go +++ b/control-plane-operator/controllers/hostedcontrolplane/configoperator/reconcile.go @@ -4,7 +4,7 @@ import ( "fmt" "path" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/common" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/kas" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" diff --git a/control-plane-operator/controllers/hostedcontrolplane/creatorupdate_ownerref_enforcer.go b/control-plane-operator/controllers/hostedcontrolplane/creatorupdate_ownerref_enforcer.go index bbe16e078d..068674eadd 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/creatorupdate_ownerref_enforcer.go +++ b/control-plane-operator/controllers/hostedcontrolplane/creatorupdate_ownerref_enforcer.go @@ -3,7 +3,7 @@ package hostedcontrolplane import ( "context" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/upsert" crclient "sigs.k8s.io/controller-runtime/pkg/client" diff --git a/control-plane-operator/controllers/hostedcontrolplane/creatorupdate_ownerref_enforcer_test.go b/control-plane-operator/controllers/hostedcontrolplane/creatorupdate_ownerref_enforcer_test.go index f0afc5e23a..74c99520e2 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/creatorupdate_ownerref_enforcer_test.go +++ b/control-plane-operator/controllers/hostedcontrolplane/creatorupdate_ownerref_enforcer_test.go @@ -5,7 +5,7 @@ import ( "testing" "github.com/google/go-cmp/cmp" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/upsert" corev1 "k8s.io/api/core/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/csi/kubevirt/kubevirt.go b/control-plane-operator/controllers/hostedcontrolplane/csi/kubevirt/kubevirt.go index 5501589d69..773b12e961 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/csi/kubevirt/kubevirt.go +++ b/control-plane-operator/controllers/hostedcontrolplane/csi/kubevirt/kubevirt.go @@ -8,7 +8,7 @@ import ( "io" "strings" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/common" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" diff --git a/control-plane-operator/controllers/hostedcontrolplane/csi/kubevirt/kubevirt_test.go b/control-plane-operator/controllers/hostedcontrolplane/csi/kubevirt/kubevirt_test.go index b9ec2eed62..6b37de2eea 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/csi/kubevirt/kubevirt_test.go +++ b/control-plane-operator/controllers/hostedcontrolplane/csi/kubevirt/kubevirt_test.go @@ -7,7 +7,7 @@ import ( "testing" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/api" storagev1 "k8s.io/api/storage/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/cvo/params.go b/control-plane-operator/controllers/hostedcontrolplane/cvo/params.go index 96e87ce09f..6fe881ea8f 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/cvo/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/cvo/params.go @@ -5,7 +5,7 @@ import ( "k8s.io/apimachinery/pkg/api/resource" utilpointer "k8s.io/utils/pointer" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/support/config" diff --git a/control-plane-operator/controllers/hostedcontrolplane/cvo/reconcile.go b/control-plane-operator/controllers/hostedcontrolplane/cvo/reconcile.go index 03cad2e4d4..78d2f4579d 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/cvo/reconcile.go +++ b/control-plane-operator/controllers/hostedcontrolplane/cvo/reconcile.go @@ -5,7 +5,7 @@ import ( "path" "strings" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/api" prometheusoperatorv1 "github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring/v1" appsv1 "k8s.io/api/apps/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/dnsoperator/dnsoperator.go b/control-plane-operator/controllers/hostedcontrolplane/dnsoperator/dnsoperator.go index dc3d69ebb6..c800a958fa 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/dnsoperator/dnsoperator.go +++ b/control-plane-operator/controllers/hostedcontrolplane/dnsoperator/dnsoperator.go @@ -3,7 +3,7 @@ package dnsoperator import ( "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/kas" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" diff --git a/control-plane-operator/controllers/hostedcontrolplane/etcd/params.go b/control-plane-operator/controllers/hostedcontrolplane/etcd/params.go index e640ddcd8f..97fff5e291 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/etcd/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/etcd/params.go @@ -7,7 +7,7 @@ import ( "k8s.io/apimachinery/pkg/api/meta" "k8s.io/apimachinery/pkg/api/resource" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/support/config" diff --git a/control-plane-operator/controllers/hostedcontrolplane/etcd/params_test.go b/control-plane-operator/controllers/hostedcontrolplane/etcd/params_test.go index ae56391cf3..a061b63c1e 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/etcd/params_test.go +++ b/control-plane-operator/controllers/hostedcontrolplane/etcd/params_test.go @@ -6,7 +6,7 @@ import ( . "github.com/onsi/gomega" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/api/util/ipnet" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" ) diff --git a/control-plane-operator/controllers/hostedcontrolplane/etcd/reconcile.go b/control-plane-operator/controllers/hostedcontrolplane/etcd/reconcile.go index bb32b6d1aa..ab942c4e00 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/etcd/reconcile.go +++ b/control-plane-operator/controllers/hostedcontrolplane/etcd/reconcile.go @@ -6,7 +6,7 @@ import ( "strconv" "strings" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/pki" "github.com/openshift/hypershift/support/certs" diff --git a/control-plane-operator/controllers/hostedcontrolplane/etcd/reconcile_test.go b/control-plane-operator/controllers/hostedcontrolplane/etcd/reconcile_test.go index e20f03811f..b22f0f2874 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/etcd/reconcile_test.go +++ b/control-plane-operator/controllers/hostedcontrolplane/etcd/reconcile_test.go @@ -7,7 +7,7 @@ import ( . "github.com/onsi/gomega" corev1 "k8s.io/api/core/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/config" ) diff --git a/control-plane-operator/controllers/hostedcontrolplane/hostedcontrolplane_controller.go b/control-plane-operator/controllers/hostedcontrolplane/hostedcontrolplane_controller.go index b1a8342182..715ab64898 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/hostedcontrolplane_controller.go +++ b/control-plane-operator/controllers/hostedcontrolplane/hostedcontrolplane_controller.go @@ -28,7 +28,7 @@ import ( "github.com/blang/semver" "github.com/go-logr/logr" routev1 "github.com/openshift/api/route/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" awsutil "github.com/openshift/hypershift/cmd/infra/aws/util" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/autoscaler" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/cloud/aws" diff --git a/control-plane-operator/controllers/hostedcontrolplane/hostedcontrolplane_controller_test.go b/control-plane-operator/controllers/hostedcontrolplane/hostedcontrolplane_controller_test.go index f8eeecf9e2..5447d98acc 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/hostedcontrolplane_controller_test.go +++ b/control-plane-operator/controllers/hostedcontrolplane/hostedcontrolplane_controller_test.go @@ -15,7 +15,7 @@ import ( configv1 "github.com/openshift/api/config/v1" imagev1 "github.com/openshift/api/image/v1" routev1 "github.com/openshift/api/route/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/autoscaler" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/common" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" diff --git a/control-plane-operator/controllers/hostedcontrolplane/ignition/params.go b/control-plane-operator/controllers/hostedcontrolplane/ignition/params.go index 30fae6492c..e5e6fcb152 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/ignition/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/ignition/params.go @@ -1,7 +1,7 @@ package ignition import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/config" ) diff --git a/control-plane-operator/controllers/hostedcontrolplane/ignitionserver/ignitionserver.go b/control-plane-operator/controllers/hostedcontrolplane/ignitionserver/ignitionserver.go index edb3f936be..4d887959b9 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/ignitionserver/ignitionserver.go +++ b/control-plane-operator/controllers/hostedcontrolplane/ignitionserver/ignitionserver.go @@ -8,7 +8,7 @@ import ( configv1 "github.com/openshift/api/config/v1" routev1 "github.com/openshift/api/route/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/controlplaneoperator" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/ignitionserver" diff --git a/control-plane-operator/controllers/hostedcontrolplane/ignitionserver/ignitionserver_test.go b/control-plane-operator/controllers/hostedcontrolplane/ignitionserver/ignitionserver_test.go index 32405ac51e..e7d36a4ccf 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/ignitionserver/ignitionserver_test.go +++ b/control-plane-operator/controllers/hostedcontrolplane/ignitionserver/ignitionserver_test.go @@ -4,7 +4,7 @@ import ( "testing" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/ignitionserver" corev1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/util/intstr" diff --git a/control-plane-operator/controllers/hostedcontrolplane/ingress/router.go b/control-plane-operator/controllers/hostedcontrolplane/ingress/router.go index fc147d41ed..c3552f8404 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/ingress/router.go +++ b/control-plane-operator/controllers/hostedcontrolplane/ingress/router.go @@ -16,7 +16,7 @@ import ( "k8s.io/utils/pointer" routev1 "github.com/openshift/api/route/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/ignitionserver" "github.com/openshift/hypershift/support/config" diff --git a/control-plane-operator/controllers/hostedcontrolplane/ingressoperator/ingressoperator.go b/control-plane-operator/controllers/hostedcontrolplane/ingressoperator/ingressoperator.go index d8bdb7a0a7..0211ece811 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/ingressoperator/ingressoperator.go +++ b/control-plane-operator/controllers/hostedcontrolplane/ingressoperator/ingressoperator.go @@ -3,7 +3,7 @@ package ingressoperator import ( "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/kas" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" diff --git a/control-plane-operator/controllers/hostedcontrolplane/kas/config.go b/control-plane-operator/controllers/hostedcontrolplane/kas/config.go index a24f5b8d51..7c38f0264e 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/kas/config.go +++ b/control-plane-operator/controllers/hostedcontrolplane/kas/config.go @@ -10,7 +10,7 @@ import ( configv1 "github.com/openshift/api/config/v1" kcpv1 "github.com/openshift/api/kubecontrolplane/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/kas/deployment.go b/control-plane-operator/controllers/hostedcontrolplane/kas/deployment.go index 0d96bf82dd..c0203aa8b9 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/kas/deployment.go +++ b/control-plane-operator/controllers/hostedcontrolplane/kas/deployment.go @@ -6,7 +6,7 @@ import ( "path" "strconv" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/kas/kms.go b/control-plane-operator/controllers/hostedcontrolplane/kas/kms.go index 9dad86cab7..8480117971 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/kas/kms.go +++ b/control-plane-operator/controllers/hostedcontrolplane/kas/kms.go @@ -4,7 +4,7 @@ import ( "bytes" "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/kas/kms" "github.com/openshift/hypershift/support/api" corev1 "k8s.io/api/core/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/kas/kms/aws.go b/control-plane-operator/controllers/hostedcontrolplane/kas/kms/aws.go index 24b7e3fa21..7708a1456d 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/kas/kms/aws.go +++ b/control-plane-operator/controllers/hostedcontrolplane/kas/kms/aws.go @@ -9,7 +9,7 @@ import ( "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/cloud/aws" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/util" corev1 "k8s.io/api/core/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/kas/kms/azure.go b/control-plane-operator/controllers/hostedcontrolplane/kas/kms/azure.go index a10383b096..d29628b8d4 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/kas/kms/azure.go +++ b/control-plane-operator/controllers/hostedcontrolplane/kas/kms/azure.go @@ -4,7 +4,7 @@ import ( "fmt" "time" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/cloud/azure" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/config" diff --git a/control-plane-operator/controllers/hostedcontrolplane/kas/kms/ibmcloud.go b/control-plane-operator/controllers/hostedcontrolplane/kas/kms/ibmcloud.go index 7e4d3c9623..f3a23e8c16 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/kas/kms/ibmcloud.go +++ b/control-plane-operator/controllers/hostedcontrolplane/kas/kms/ibmcloud.go @@ -7,7 +7,7 @@ import ( "strconv" "time" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/util" diff --git a/control-plane-operator/controllers/hostedcontrolplane/kas/params.go b/control-plane-operator/controllers/hostedcontrolplane/kas/params.go index 51e77bc4b3..59aa6d71f4 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/kas/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/kas/params.go @@ -5,7 +5,7 @@ import ( "fmt" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/cloud/aws" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/cloud/azure" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" diff --git a/control-plane-operator/controllers/hostedcontrolplane/kas/params_test.go b/control-plane-operator/controllers/hostedcontrolplane/kas/params_test.go index f70da1ad5a..e6fb1da711 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/kas/params_test.go +++ b/control-plane-operator/controllers/hostedcontrolplane/kas/params_test.go @@ -8,7 +8,7 @@ import ( "k8s.io/utils/pointer" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/api/util/ipnet" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/support/config" diff --git a/control-plane-operator/controllers/hostedcontrolplane/kas/pdb.go b/control-plane-operator/controllers/hostedcontrolplane/kas/pdb.go index 4548a6834f..1ac3829b7d 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/kas/pdb.go +++ b/control-plane-operator/controllers/hostedcontrolplane/kas/pdb.go @@ -1,7 +1,7 @@ package kas import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" policyv1 "k8s.io/api/policy/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/util/intstr" diff --git a/control-plane-operator/controllers/hostedcontrolplane/kas/secretencryption.go b/control-plane-operator/controllers/hostedcontrolplane/kas/secretencryption.go index d8f36a3abf..8a078f39d6 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/kas/secretencryption.go +++ b/control-plane-operator/controllers/hostedcontrolplane/kas/secretencryption.go @@ -1,7 +1,7 @@ package kas import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" hcpconfig "github.com/openshift/hypershift/support/config" corev1 "k8s.io/api/core/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/kas/service.go b/control-plane-operator/controllers/hostedcontrolplane/kas/service.go index 6ad35a3edb..e99bebbb2b 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/kas/service.go +++ b/control-plane-operator/controllers/hostedcontrolplane/kas/service.go @@ -11,7 +11,7 @@ import ( "k8s.io/apimachinery/pkg/util/intstr" routev1 "github.com/openshift/api/route/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/events" diff --git a/control-plane-operator/controllers/hostedcontrolplane/kas_pki_setup.go b/control-plane-operator/controllers/hostedcontrolplane/kas_pki_setup.go index 9af9e7ec69..c3209d1b98 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/kas_pki_setup.go +++ b/control-plane-operator/controllers/hostedcontrolplane/kas_pki_setup.go @@ -4,7 +4,7 @@ import ( "context" "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/pki" "github.com/openshift/hypershift/support/config" diff --git a/control-plane-operator/controllers/hostedcontrolplane/kcm/deployment.go b/control-plane-operator/controllers/hostedcontrolplane/kcm/deployment.go index 72e0a2887e..ff487ce557 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/kcm/deployment.go +++ b/control-plane-operator/controllers/hostedcontrolplane/kcm/deployment.go @@ -5,7 +5,7 @@ import ( "path" "strings" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/kcm/params.go b/control-plane-operator/controllers/hostedcontrolplane/kcm/params.go index 62ff25e73c..d7da8dff01 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/kcm/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/kcm/params.go @@ -8,7 +8,7 @@ import ( "k8s.io/apimachinery/pkg/util/intstr" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/config" diff --git a/control-plane-operator/controllers/hostedcontrolplane/konnectivity/params.go b/control-plane-operator/controllers/hostedcontrolplane/konnectivity/params.go index c9e96a793c..9d2f496032 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/konnectivity/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/konnectivity/params.go @@ -5,7 +5,7 @@ import ( "k8s.io/apimachinery/pkg/api/resource" "k8s.io/apimachinery/pkg/util/intstr" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/support/config" ) diff --git a/control-plane-operator/controllers/hostedcontrolplane/konnectivity/reconcile.go b/control-plane-operator/controllers/hostedcontrolplane/konnectivity/reconcile.go index 211831022f..690dee6d54 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/konnectivity/reconcile.go +++ b/control-plane-operator/controllers/hostedcontrolplane/konnectivity/reconcile.go @@ -11,7 +11,7 @@ import ( corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/kas" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/certs" diff --git a/control-plane-operator/controllers/hostedcontrolplane/machineapprover/reconcile.go b/control-plane-operator/controllers/hostedcontrolplane/machineapprover/reconcile.go index da4c591a00..69f78de38e 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/machineapprover/reconcile.go +++ b/control-plane-operator/controllers/hostedcontrolplane/machineapprover/reconcile.go @@ -4,7 +4,7 @@ import ( "context" "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/kas" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/controlplaneoperator" diff --git a/control-plane-operator/controllers/hostedcontrolplane/manifests/kas.go b/control-plane-operator/controllers/hostedcontrolplane/manifests/kas.go index ae8266848b..72b9289614 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/manifests/kas.go +++ b/control-plane-operator/controllers/hostedcontrolplane/manifests/kas.go @@ -10,7 +10,7 @@ import ( policyv1 "k8s.io/api/policy/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) const ( diff --git a/control-plane-operator/controllers/hostedcontrolplane/mcs/params.go b/control-plane-operator/controllers/hostedcontrolplane/mcs/params.go index 696ffe05bc..7c5639a462 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/mcs/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/mcs/params.go @@ -6,7 +6,7 @@ import ( configv1 "github.com/openshift/api/config/v1" corev1 "k8s.io/api/core/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/globalconfig" ) diff --git a/control-plane-operator/controllers/hostedcontrolplane/nto/clusternodetuningoperator.go b/control-plane-operator/controllers/hostedcontrolplane/nto/clusternodetuningoperator.go index 6c6cb24fd8..2cbb2690ff 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/nto/clusternodetuningoperator.go +++ b/control-plane-operator/controllers/hostedcontrolplane/nto/clusternodetuningoperator.go @@ -1,7 +1,7 @@ package nto import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/common" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" diff --git a/control-plane-operator/controllers/hostedcontrolplane/oapi/config.go b/control-plane-operator/controllers/hostedcontrolplane/oapi/config.go index 22ce7f6cde..b4cd0fc96d 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/oapi/config.go +++ b/control-plane-operator/controllers/hostedcontrolplane/oapi/config.go @@ -9,7 +9,7 @@ import ( configv1 "github.com/openshift/api/config/v1" openshiftcpv1 "github.com/openshift/api/openshiftcontrolplane/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/common" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/kas" diff --git a/control-plane-operator/controllers/hostedcontrolplane/oapi/deployment.go b/control-plane-operator/controllers/hostedcontrolplane/oapi/deployment.go index 499aff05b7..c8a82d4e89 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/oapi/deployment.go +++ b/control-plane-operator/controllers/hostedcontrolplane/oapi/deployment.go @@ -6,7 +6,7 @@ import ( "path" "strings" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/api/resource" diff --git a/control-plane-operator/controllers/hostedcontrolplane/oapi/oauth_deployment.go b/control-plane-operator/controllers/hostedcontrolplane/oapi/oauth_deployment.go index 06815ccbbc..93700254de 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/oapi/oauth_deployment.go +++ b/control-plane-operator/controllers/hostedcontrolplane/oapi/oauth_deployment.go @@ -4,7 +4,7 @@ import ( "fmt" "path" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/oapi/params.go b/control-plane-operator/controllers/hostedcontrolplane/oapi/params.go index edfa8aca91..4fa6c8ff17 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/oapi/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/oapi/params.go @@ -7,7 +7,7 @@ import ( "k8s.io/apimachinery/pkg/util/intstr" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/globalconfig" diff --git a/control-plane-operator/controllers/hostedcontrolplane/oapi/pdb.go b/control-plane-operator/controllers/hostedcontrolplane/oapi/pdb.go index 385ac86c2f..e8fc2ec33c 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/oapi/pdb.go +++ b/control-plane-operator/controllers/hostedcontrolplane/oapi/pdb.go @@ -1,7 +1,7 @@ package oapi import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" policyv1 "k8s.io/api/policy/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/util/intstr" diff --git a/control-plane-operator/controllers/hostedcontrolplane/oapi/service.go b/control-plane-operator/controllers/hostedcontrolplane/oapi/service.go index bd848ce9f6..d529050146 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/oapi/service.go +++ b/control-plane-operator/controllers/hostedcontrolplane/oapi/service.go @@ -1,7 +1,7 @@ package oapi import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" corev1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/util/intstr" diff --git a/control-plane-operator/controllers/hostedcontrolplane/oauth/deployment.go b/control-plane-operator/controllers/hostedcontrolplane/oauth/deployment.go index 29d26c910a..c630c7df27 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/oauth/deployment.go +++ b/control-plane-operator/controllers/hostedcontrolplane/oauth/deployment.go @@ -6,7 +6,7 @@ import ( "path" "strings" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/globalconfig" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/oauth/params.go b/control-plane-operator/controllers/hostedcontrolplane/oauth/params.go index c7c6754267..82d8a0e916 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/oauth/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/oauth/params.go @@ -12,7 +12,7 @@ import ( "k8s.io/apimachinery/pkg/api/resource" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/config" diff --git a/control-plane-operator/controllers/hostedcontrolplane/oauth/pdb.go b/control-plane-operator/controllers/hostedcontrolplane/oauth/pdb.go index fda2d50ad9..1ad588f72f 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/oauth/pdb.go +++ b/control-plane-operator/controllers/hostedcontrolplane/oauth/pdb.go @@ -1,7 +1,7 @@ package oauth import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" policyv1 "k8s.io/api/policy/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/util/intstr" diff --git a/control-plane-operator/controllers/hostedcontrolplane/oauth/route.go b/control-plane-operator/controllers/hostedcontrolplane/oauth/route.go index fd895f7492..a7e627db98 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/oauth/route.go +++ b/control-plane-operator/controllers/hostedcontrolplane/oauth/route.go @@ -1,7 +1,7 @@ package oauth import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" routev1 "github.com/openshift/api/route/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/oauth/service.go b/control-plane-operator/controllers/hostedcontrolplane/oauth/service.go index 173f7bffe1..7eb2cc0058 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/oauth/service.go +++ b/control-plane-operator/controllers/hostedcontrolplane/oauth/service.go @@ -9,7 +9,7 @@ import ( "k8s.io/apimachinery/pkg/util/intstr" routev1 "github.com/openshift/api/route/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/config" ) diff --git a/control-plane-operator/controllers/hostedcontrolplane/ocm/config_test.go b/control-plane-operator/controllers/hostedcontrolplane/ocm/config_test.go index f992da3731..1c134de72b 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/ocm/config_test.go +++ b/control-plane-operator/controllers/hostedcontrolplane/ocm/config_test.go @@ -10,7 +10,7 @@ import ( "github.com/openshift/hypershift/support/globalconfig" corev1 "k8s.io/api/core/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/api" "github.com/openshift/hypershift/support/testutil" "github.com/openshift/hypershift/support/util" diff --git a/control-plane-operator/controllers/hostedcontrolplane/ocm/deployment.go b/control-plane-operator/controllers/hostedcontrolplane/ocm/deployment.go index a7354a67af..ff4d861cc4 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/ocm/deployment.go +++ b/control-plane-operator/controllers/hostedcontrolplane/ocm/deployment.go @@ -4,7 +4,7 @@ import ( "fmt" "path" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/ocm/params.go b/control-plane-operator/controllers/hostedcontrolplane/ocm/params.go index a9ad7a2be6..bfecdfb703 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/ocm/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/ocm/params.go @@ -6,7 +6,7 @@ import ( "k8s.io/apimachinery/pkg/util/intstr" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/globalconfig" diff --git a/control-plane-operator/controllers/hostedcontrolplane/olm/catalogs.go b/control-plane-operator/controllers/hostedcontrolplane/olm/catalogs.go index 5c6c056ede..68aa0b7d13 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/olm/catalogs.go +++ b/control-plane-operator/controllers/hostedcontrolplane/olm/catalogs.go @@ -5,7 +5,7 @@ import ( "math/big" "strings" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/assets" prometheusoperatorv1 "github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/olm/olm-collect-profiles.go b/control-plane-operator/controllers/hostedcontrolplane/olm/olm-collect-profiles.go index 823b43ba33..1ff5284a75 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/olm/olm-collect-profiles.go +++ b/control-plane-operator/controllers/hostedcontrolplane/olm/olm-collect-profiles.go @@ -1,7 +1,7 @@ package olm import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/common" "github.com/openshift/hypershift/support/assets" "github.com/openshift/hypershift/support/config" diff --git a/control-plane-operator/controllers/hostedcontrolplane/olm/operator.go b/control-plane-operator/controllers/hostedcontrolplane/olm/operator.go index 3e2681b163..90edc62bc6 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/olm/operator.go +++ b/control-plane-operator/controllers/hostedcontrolplane/olm/operator.go @@ -3,7 +3,7 @@ package olm import ( "strings" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/assets" prometheusoperatorv1 "github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/olm/params.go b/control-plane-operator/controllers/hostedcontrolplane/olm/params.go index ab1635568d..eb4c9363de 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/olm/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/olm/params.go @@ -1,7 +1,7 @@ package olm import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/util" diff --git a/control-plane-operator/controllers/hostedcontrolplane/pki/kas.go b/control-plane-operator/controllers/hostedcontrolplane/pki/kas.go index a5f186ecbc..0dbad28abc 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/pki/kas.go +++ b/control-plane-operator/controllers/hostedcontrolplane/pki/kas.go @@ -10,7 +10,7 @@ import ( "k8s.io/apiserver/pkg/authentication/serviceaccount" clientcmdapi "k8s.io/client-go/tools/clientcmd/api" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/certs" "github.com/openshift/hypershift/support/config" diff --git a/control-plane-operator/controllers/hostedcontrolplane/pki/params.go b/control-plane-operator/controllers/hostedcontrolplane/pki/params.go index 1a0effee75..068e888dc0 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/pki/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/pki/params.go @@ -3,7 +3,7 @@ package pki import ( "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/globalconfig" diff --git a/control-plane-operator/controllers/hostedcontrolplane/pkioperator/reconcile.go b/control-plane-operator/controllers/hostedcontrolplane/pkioperator/reconcile.go index 2714863966..79d2a17858 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/pkioperator/reconcile.go +++ b/control-plane-operator/controllers/hostedcontrolplane/pkioperator/reconcile.go @@ -3,7 +3,7 @@ package pkioperator import ( "time" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/proxy" hyperutil "github.com/openshift/hypershift/support/util" diff --git a/control-plane-operator/controllers/hostedcontrolplane/pkioperator/reconcile_test.go b/control-plane-operator/controllers/hostedcontrolplane/pkioperator/reconcile_test.go index f5b2365256..a3dd45af77 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/pkioperator/reconcile_test.go +++ b/control-plane-operator/controllers/hostedcontrolplane/pkioperator/reconcile_test.go @@ -4,8 +4,8 @@ import ( "testing" "time" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/api" "github.com/openshift/hypershift/support/config" diff --git a/control-plane-operator/controllers/hostedcontrolplane/registryoperator/reconcile.go b/control-plane-operator/controllers/hostedcontrolplane/registryoperator/reconcile.go index eb8a1d74cd..13a48d31ee 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/registryoperator/reconcile.go +++ b/control-plane-operator/controllers/hostedcontrolplane/registryoperator/reconcile.go @@ -13,7 +13,7 @@ import ( "k8s.io/apimachinery/pkg/util/intstr" "k8s.io/utils/pointer" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/kas" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" diff --git a/control-plane-operator/controllers/hostedcontrolplane/registryoperator/reconcile_test.go b/control-plane-operator/controllers/hostedcontrolplane/registryoperator/reconcile_test.go index d49aa37305..3255fb7a13 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/registryoperator/reconcile_test.go +++ b/control-plane-operator/controllers/hostedcontrolplane/registryoperator/reconcile_test.go @@ -3,7 +3,7 @@ package registryoperator import ( "testing" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/api" diff --git a/control-plane-operator/controllers/hostedcontrolplane/routecm/config_test.go b/control-plane-operator/controllers/hostedcontrolplane/routecm/config_test.go index efa4f3a8c9..e9a175f167 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/routecm/config_test.go +++ b/control-plane-operator/controllers/hostedcontrolplane/routecm/config_test.go @@ -8,7 +8,7 @@ import ( "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" config2 "github.com/openshift/hypershift/support/config" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/api" "github.com/openshift/hypershift/support/testutil" "github.com/openshift/hypershift/support/util" diff --git a/control-plane-operator/controllers/hostedcontrolplane/routecm/deployment.go b/control-plane-operator/controllers/hostedcontrolplane/routecm/deployment.go index 2b7396b542..506de033e0 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/routecm/deployment.go +++ b/control-plane-operator/controllers/hostedcontrolplane/routecm/deployment.go @@ -4,7 +4,7 @@ import ( "fmt" "path" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/routecm/params.go b/control-plane-operator/controllers/hostedcontrolplane/routecm/params.go index b3f30f9213..2328f7c996 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/routecm/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/routecm/params.go @@ -6,7 +6,7 @@ import ( "k8s.io/apimachinery/pkg/util/intstr" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/globalconfig" diff --git a/control-plane-operator/controllers/hostedcontrolplane/scheduler/deployment.go b/control-plane-operator/controllers/hostedcontrolplane/scheduler/deployment.go index a1c43396b5..da7ae018d2 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/scheduler/deployment.go +++ b/control-plane-operator/controllers/hostedcontrolplane/scheduler/deployment.go @@ -5,7 +5,7 @@ import ( "path" "strings" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" diff --git a/control-plane-operator/controllers/hostedcontrolplane/scheduler/params.go b/control-plane-operator/controllers/hostedcontrolplane/scheduler/params.go index 6da5947675..f1c4c45582 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/scheduler/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/scheduler/params.go @@ -8,7 +8,7 @@ import ( "k8s.io/apimachinery/pkg/util/intstr" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/config" diff --git a/control-plane-operator/controllers/hostedcontrolplane/snapshotcontroller/operator_test.go b/control-plane-operator/controllers/hostedcontrolplane/snapshotcontroller/operator_test.go index 462179bb66..21c8333802 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/snapshotcontroller/operator_test.go +++ b/control-plane-operator/controllers/hostedcontrolplane/snapshotcontroller/operator_test.go @@ -3,7 +3,7 @@ package snapshotcontroller import ( "testing" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/api" diff --git a/control-plane-operator/controllers/hostedcontrolplane/snapshotcontroller/params.go b/control-plane-operator/controllers/hostedcontrolplane/snapshotcontroller/params.go index 2327555d1c..2737adf7e2 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/snapshotcontroller/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/snapshotcontroller/params.go @@ -1,7 +1,7 @@ package snapshotcontroller import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/util" diff --git a/control-plane-operator/controllers/hostedcontrolplane/storage/params.go b/control-plane-operator/controllers/hostedcontrolplane/storage/params.go index fda25a3d7e..be4c3c6615 100644 --- a/control-plane-operator/controllers/hostedcontrolplane/storage/params.go +++ b/control-plane-operator/controllers/hostedcontrolplane/storage/params.go @@ -1,7 +1,7 @@ package storage import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/util" diff --git a/control-plane-operator/hostedclusterconfigoperator/api/scheme.go b/control-plane-operator/hostedclusterconfigoperator/api/scheme.go index c4056b77c3..e606427383 100644 --- a/control-plane-operator/hostedclusterconfigoperator/api/scheme.go +++ b/control-plane-operator/hostedclusterconfigoperator/api/scheme.go @@ -10,7 +10,7 @@ import ( osinv1 "github.com/openshift/api/osin/v1" routev1 "github.com/openshift/api/route/v1" securityv1 "github.com/openshift/api/security/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" operatorsv1alpha1 "github.com/operator-framework/api/pkg/operators/v1alpha1" prometheusoperatorv1 "github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring/v1" corev1 "k8s.io/api/core/v1" diff --git a/control-plane-operator/hostedclusterconfigoperator/cmd.go b/control-plane-operator/hostedclusterconfigoperator/cmd.go index 00d0c1fbe6..3343a06d42 100644 --- a/control-plane-operator/hostedclusterconfigoperator/cmd.go +++ b/control-plane-operator/hostedclusterconfigoperator/cmd.go @@ -18,7 +18,7 @@ import ( "fmt" "os" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/hostedclusterconfigoperator/api" "github.com/openshift/hypershift/control-plane-operator/hostedclusterconfigoperator/configmetrics" "github.com/openshift/hypershift/control-plane-operator/hostedclusterconfigoperator/controllers/cmca" diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/hcpstatus/hcpstatus.go b/control-plane-operator/hostedclusterconfigoperator/controllers/hcpstatus/hcpstatus.go index 8fdf2e65e6..5626f0b782 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/hcpstatus/hcpstatus.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/hcpstatus/hcpstatus.go @@ -6,7 +6,7 @@ import ( "reflect" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/hostedclusterconfigoperator/operator" "github.com/openshift/hypershift/support/releaseinfo" "k8s.io/apimachinery/pkg/api/meta" diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/machine/machine.go b/control-plane-operator/hostedclusterconfigoperator/controllers/machine/machine.go index 9125575b05..b8df677052 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/machine/machine.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/machine/machine.go @@ -6,7 +6,7 @@ import ( "net/netip" "strings" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hcpmanifests "github.com/openshift/hypershift/control-plane-operator/hostedclusterconfigoperator/controllers/resources/manifests" "github.com/openshift/hypershift/support/config" corev1 "k8s.io/api/core/v1" diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/machine/machine_test.go b/control-plane-operator/hostedclusterconfigoperator/controllers/machine/machine_test.go index 239cb04b37..c596fb10f6 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/machine/machine_test.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/machine/machine_test.go @@ -20,7 +20,7 @@ import ( "sigs.k8s.io/controller-runtime/pkg/client/fake" "sigs.k8s.io/controller-runtime/pkg/controller/controllerutil" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func TestReconcileDefaultIngressEndpoints(t *testing.T) { diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/node/node.go b/control-plane-operator/hostedclusterconfigoperator/controllers/node/node.go index cdfa1e6b61..9ccc379510 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/node/node.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/node/node.go @@ -7,7 +7,7 @@ import ( "fmt" "strings" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/upsert" supportutil "github.com/openshift/hypershift/support/util" corev1 "k8s.io/api/core/v1" diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/clusteroperators.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/clusteroperators.go index 72ac410b5a..ca9e4e8344 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/clusteroperators.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/clusteroperators.go @@ -6,7 +6,7 @@ import ( "sort" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" utilerrors "k8s.io/apimachinery/pkg/util/errors" ) diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/params.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/params.go index 9abb6e2feb..2b68fe8d51 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/params.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/params.go @@ -3,7 +3,7 @@ package ingress import ( configv1 "github.com/openshift/api/config/v1" v1 "github.com/openshift/api/operator/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/globalconfig" ) diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/params_test.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/params_test.go index fab831395e..70d1646b03 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/params_test.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/params_test.go @@ -5,7 +5,7 @@ import ( configv1 "github.com/openshift/api/config/v1" v1 "github.com/openshift/api/operator/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" . "github.com/onsi/gomega" diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/reconcile.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/reconcile.go index 48764d1732..c94f1fcd3e 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/reconcile.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/reconcile.go @@ -8,7 +8,7 @@ import ( operatorv1 "github.com/openshift/api/operator/v1" routev1 "github.com/openshift/api/route/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/hostedclusterconfigoperator/controllers/resources/manifests" ) diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/reconcile_test.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/reconcile_test.go index 38871a18d2..58700aab22 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/reconcile_test.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/ingress/reconcile_test.go @@ -5,7 +5,7 @@ import ( . "github.com/onsi/gomega" operatorv1 "github.com/openshift/api/operator/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/konnectivity/params.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/konnectivity/params.go index e296762e28..69af1a387c 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/konnectivity/params.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/konnectivity/params.go @@ -5,7 +5,7 @@ import ( "k8s.io/apimachinery/pkg/api/resource" "k8s.io/apimachinery/pkg/util/intstr" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/config" ) diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/konnectivity/reconcile.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/konnectivity/reconcile.go index 3983f2563e..9660d71f83 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/konnectivity/reconcile.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/konnectivity/reconcile.go @@ -12,7 +12,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/util/intstr" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/util" diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/manifests/hostedcp.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/manifests/hostedcp.go index 34fb653290..96c41c3da4 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/manifests/hostedcp.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/manifests/hostedcp.go @@ -1,7 +1,7 @@ package manifests import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/network/reconcile.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/network/reconcile.go index 91e8b0e0d2..a40826f80c 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/network/reconcile.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/network/reconcile.go @@ -5,7 +5,7 @@ import ( "fmt" operatorv1 "github.com/openshift/api/operator/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "k8s.io/apimachinery/pkg/api/equality" "k8s.io/apimachinery/pkg/api/meta" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/network/reconcile_test.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/network/reconcile_test.go index 779905ba8a..1a5d617a04 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/network/reconcile_test.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/network/reconcile_test.go @@ -5,7 +5,7 @@ import ( . "github.com/onsi/gomega" operatorv1 "github.com/openshift/api/operator/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func TestReconcileDefaultIngressController(t *testing.T) { diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/olm/catalogs.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/olm/catalogs.go index 687ce10e60..f58a131706 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/olm/catalogs.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/olm/catalogs.go @@ -5,7 +5,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" operatorsv1alpha1 "github.com/operator-framework/api/pkg/operators/v1alpha1" ) diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/olm/params.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/olm/params.go index 46431df189..1d4f8705a8 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/olm/params.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/olm/params.go @@ -1,7 +1,7 @@ package olm import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/olm" ) diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/registry/reconcile_test.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/registry/reconcile_test.go index e80ddc9c89..ad6f1529bc 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/registry/reconcile_test.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/registry/reconcile_test.go @@ -6,7 +6,7 @@ import ( . "github.com/onsi/gomega" imageregistryv1 "github.com/openshift/api/imageregistry/v1" operatorv1 "github.com/openshift/api/operator/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/hostedclusterconfigoperator/controllers/resources/manifests" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/registry/registry.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/registry/registry.go index 4893233bac..6fb54f5bbb 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/registry/registry.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/registry/registry.go @@ -6,7 +6,7 @@ import ( imageregistryv1 "github.com/openshift/api/imageregistry/v1" operatorv1 "github.com/openshift/api/operator/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func ReconcileRegistryConfig(cfg *imageregistryv1.Config, platform hyperv1.PlatformType, availabilityPolicy hyperv1.AvailabilityPolicy) { diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/resources.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/resources.go index 4fab41dffc..53276ac566 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/resources.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/resources.go @@ -39,7 +39,7 @@ import ( imageregistryv1 "github.com/openshift/api/imageregistry/v1" operatorv1 "github.com/openshift/api/operator/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/cloud/azure" kubevirtcsi "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/csi/kubevirt" diff --git a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/resources_test.go b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/resources_test.go index 1d6579b1d1..1f6bc7216d 100644 --- a/control-plane-operator/hostedclusterconfigoperator/controllers/resources/resources_test.go +++ b/control-plane-operator/hostedclusterconfigoperator/controllers/resources/resources_test.go @@ -16,7 +16,7 @@ import ( configv1 "github.com/openshift/api/config/v1" operatorv1 "github.com/openshift/api/operator/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" cpomanifests "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/control-plane-operator/hostedclusterconfigoperator/api" "github.com/openshift/hypershift/control-plane-operator/hostedclusterconfigoperator/controllers/resources/manifests" diff --git a/control-plane-operator/hostedclusterconfigoperator/operator/config.go b/control-plane-operator/hostedclusterconfigoperator/operator/config.go index ce70ea8a29..471128a945 100644 --- a/control-plane-operator/hostedclusterconfigoperator/operator/config.go +++ b/control-plane-operator/hostedclusterconfigoperator/operator/config.go @@ -23,7 +23,7 @@ import ( configv1 "github.com/openshift/api/config/v1" imageregistryv1 "github.com/openshift/api/imageregistry/v1" operatorv1 "github.com/openshift/api/operator/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/hostedclusterconfigoperator/api" "github.com/openshift/hypershift/support/labelenforcingclient" "github.com/openshift/hypershift/support/releaseinfo" diff --git a/control-plane-pki-operator/certificates/validation.go b/control-plane-pki-operator/certificates/validation.go index b7af9a4635..b77ca71884 100644 --- a/control-plane-pki-operator/certificates/validation.go +++ b/control-plane-pki-operator/certificates/validation.go @@ -5,7 +5,7 @@ import ( "errors" "fmt" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" certificatesv1 "k8s.io/api/certificates/v1" "k8s.io/apimachinery/pkg/util/sets" diff --git a/control-plane-pki-operator/certificates/validation_test.go b/control-plane-pki-operator/certificates/validation_test.go index 208c238349..192334584e 100644 --- a/control-plane-pki-operator/certificates/validation_test.go +++ b/control-plane-pki-operator/certificates/validation_test.go @@ -7,7 +7,7 @@ import ( "net/url" "testing" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" certificatesv1 "k8s.io/api/certificates/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) diff --git a/control-plane-pki-operator/certificatesigningcontroller/certificatesigningcontroller.go b/control-plane-pki-operator/certificatesigningcontroller/certificatesigningcontroller.go index 0035ba7fcb..1762029275 100644 --- a/control-plane-pki-operator/certificatesigningcontroller/certificatesigningcontroller.go +++ b/control-plane-pki-operator/certificatesigningcontroller/certificatesigningcontroller.go @@ -6,7 +6,7 @@ import ( "fmt" "time" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-pki-operator/certificates" "github.com/openshift/library-go/pkg/controller/factory" librarygocrypto "github.com/openshift/library-go/pkg/crypto" diff --git a/control-plane-pki-operator/certificatesigningcontroller/certificatesigningcontroller_test.go b/control-plane-pki-operator/certificatesigningcontroller/certificatesigningcontroller_test.go index 479992633f..5f74ba2039 100644 --- a/control-plane-pki-operator/certificatesigningcontroller/certificatesigningcontroller_test.go +++ b/control-plane-pki-operator/certificatesigningcontroller/certificatesigningcontroller_test.go @@ -18,7 +18,7 @@ import ( "github.com/google/go-cmp/cmp" "github.com/google/go-cmp/cmp/cmpopts" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" corev1 "k8s.io/api/core/v1" apierrors "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/control-plane-pki-operator/certificatesigningrequestapprovalcontroller/certificatesigningrequestapprovalcontroller.go b/control-plane-pki-operator/certificatesigningrequestapprovalcontroller/certificatesigningrequestapprovalcontroller.go index 212cf9e6ad..fde7a5f45b 100644 --- a/control-plane-pki-operator/certificatesigningrequestapprovalcontroller/certificatesigningrequestapprovalcontroller.go +++ b/control-plane-pki-operator/certificatesigningrequestapprovalcontroller/certificatesigningrequestapprovalcontroller.go @@ -4,8 +4,8 @@ import ( "context" "time" - certificatesv1alpha1 "github.com/openshift/hypershift/api/types/certificates/v1alpha1" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + certificatesv1alpha1 "github.com/openshift/hypershift/api/certificates/v1alpha1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hypershiftinformers "github.com/openshift/hypershift/client/informers/externalversions" "github.com/openshift/hypershift/control-plane-pki-operator/certificates" "github.com/openshift/library-go/pkg/controller/factory" diff --git a/control-plane-pki-operator/certificatesigningrequestapprovalcontroller/certificatesigningrequestapprovalcontroller_test.go b/control-plane-pki-operator/certificatesigningrequestapprovalcontroller/certificatesigningrequestapprovalcontroller_test.go index 81ece3d325..87083ee9b6 100644 --- a/control-plane-pki-operator/certificatesigningrequestapprovalcontroller/certificatesigningrequestapprovalcontroller_test.go +++ b/control-plane-pki-operator/certificatesigningrequestapprovalcontroller/certificatesigningrequestapprovalcontroller_test.go @@ -6,14 +6,14 @@ import ( "github.com/google/go-cmp/cmp" "github.com/google/go-cmp/cmp/cmpopts" - certificatesv1alpha1 "github.com/openshift/hypershift/api/types/certificates/v1alpha1" + certificatesv1alpha1 "github.com/openshift/hypershift/api/certificates/v1alpha1" certificatesv1 "k8s.io/api/certificates/v1" corev1 "k8s.io/api/core/v1" apierrors "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func TestCertificateSigningRequestApprovalController_processCertificateSigningRequest(t *testing.T) { diff --git a/control-plane-pki-operator/certrotationcontroller/certrotationcontroller.go b/control-plane-pki-operator/certrotationcontroller/certrotationcontroller.go index 3139fef493..53b4beb780 100644 --- a/control-plane-pki-operator/certrotationcontroller/certrotationcontroller.go +++ b/control-plane-pki-operator/certrotationcontroller/certrotationcontroller.go @@ -7,7 +7,7 @@ import ( "math/big" "time" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hypershiftv1beta1client "github.com/openshift/hypershift/client/clientset/clientset/typed/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-pki-operator/clienthelpers" pkimanifests "github.com/openshift/hypershift/control-plane-pki-operator/manifests" diff --git a/control-plane-pki-operator/clienthelpers/conditions.go b/control-plane-pki-operator/clienthelpers/conditions.go index 739e75930e..ec84f45f8e 100644 --- a/control-plane-pki-operator/clienthelpers/conditions.go +++ b/control-plane-pki-operator/clienthelpers/conditions.go @@ -5,13 +5,13 @@ import ( "fmt" "time" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hypershiftv1beta1applyconfigurations "github.com/openshift/hypershift/client/applyconfiguration/hypershift/v1beta1" hypershiftv1beta1client "github.com/openshift/hypershift/client/clientset/clientset/typed/hypershift/v1beta1" "github.com/openshift/library-go/pkg/operator/certrotation" "github.com/openshift/library-go/pkg/operator/condition" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - metav1applyconfigurations "k8s.io/client-go/applyconfigurations/meta/v1" + clientgoapplyconfig "k8s.io/client-go/applyconfigurations/meta/v1" ) func NewHostedControlPlaneStatusReporter(name, namespace string, client hypershiftv1beta1client.HostedControlPlanesGetter) *HostedControlPlaneStatusReporter { @@ -67,13 +67,14 @@ func UpdateHostedControlPlaneStatusCondition(ctx context.Context, newCondition m } cfg := hypershiftv1beta1applyconfigurations.HostedControlPlane(name, namespace). - WithStatus(hypershiftv1beta1applyconfigurations.HostedControlPlaneStatus().WithConditions(metav1applyconfigurations.Condition(). - WithType(newCondition.Type). - WithStatus(newCondition.Status). - WithLastTransitionTime(newCondition.LastTransitionTime). - WithReason(newCondition.Reason). - WithMessage(newCondition.Message), - )) + WithStatus(hypershiftv1beta1applyconfigurations.HostedControlPlaneStatus().WithConditions( + &clientgoapplyconfig.ConditionApplyConfiguration{ + Type: &newCondition.Type, + Status: &newCondition.Status, + Reason: &newCondition.Reason, + Message: &newCondition.Message, + LastTransitionTime: &newCondition.LastTransitionTime, + })) _, updateErr := client.HostedControlPlanes(namespace).ApplyStatus(ctx, cfg, metav1.ApplyOptions{FieldManager: fieldManager}) return true, updateErr diff --git a/control-plane-pki-operator/targetconfigcontroller/targetconfigcontroller.go b/control-plane-pki-operator/targetconfigcontroller/targetconfigcontroller.go index 8c50c9ef76..2bb99b796b 100644 --- a/control-plane-pki-operator/targetconfigcontroller/targetconfigcontroller.go +++ b/control-plane-pki-operator/targetconfigcontroller/targetconfigcontroller.go @@ -5,7 +5,7 @@ import ( "fmt" "time" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hypershiftv1beta1client "github.com/openshift/hypershift/client/clientset/clientset/typed/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-pki-operator/clienthelpers" pkimanifests "github.com/openshift/hypershift/control-plane-pki-operator/manifests" diff --git a/control-plane-pki-operator/topology/detector.go b/control-plane-pki-operator/topology/detector.go index 9184063a31..a41dfc6a0a 100644 --- a/control-plane-pki-operator/topology/detector.go +++ b/control-plane-pki-operator/topology/detector.go @@ -6,7 +6,7 @@ import ( "os" configv1 "github.com/openshift/api/config/v1" - "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + "github.com/openshift/hypershift/api/hypershift/v1beta1" hypershiftv1beta1 "github.com/openshift/hypershift/client/clientset/clientset/typed/hypershift/v1beta1" "github.com/openshift/library-go/pkg/controller/controllercmd" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/docs/api-doc-gen/templates/members.tpl b/docs/api-doc-gen/templates/members.tpl index 98278fcaba..5daf1e9b5e 100644 --- a/docs/api-doc-gen/templates/members.tpl +++ b/docs/api-doc-gen/templates/members.tpl @@ -28,7 +28,7 @@ {{ safe (renderComments .CommentLines) }} - {{- if and (eq .Type.Kind "Alias") (eq .Type.Name.Package "github.com/openshift/hypershift/api/types/hypershift/v1alpha1") }} + {{- if and (eq .Type.Kind "Alias") (eq .Type.Name.Package "github.com/openshift/hypershift/api/hypershift/v1alpha1") }} {{- with (constantsOfType .Type) }}

Value must be one of: diff --git a/examples/fixtures/example.go b/examples/fixtures/example.go index b785707ff5..7c4f508e7f 100644 --- a/examples/fixtures/example.go +++ b/examples/fixtures/example.go @@ -6,7 +6,7 @@ import ( "strings" "time" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/api/util/ipnet" "github.com/openshift/hypershift/cmd/util" diff --git a/examples/fixtures/example_aws.go b/examples/fixtures/example_aws.go index a2b0a353da..d4cb6f8a23 100644 --- a/examples/fixtures/example_aws.go +++ b/examples/fixtures/example_aws.go @@ -1,7 +1,7 @@ package fixtures import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) type ExampleAWSOptions struct { diff --git a/examples/fixtures/example_ibmcloud_powervs.go b/examples/fixtures/example_ibmcloud_powervs.go index 4031aee4f3..b9a01c907b 100644 --- a/examples/fixtures/example_ibmcloud_powervs.go +++ b/examples/fixtures/example_ibmcloud_powervs.go @@ -4,7 +4,7 @@ import ( corev1 "k8s.io/api/core/v1" crclient "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) type ExamplePowerVSOptions struct { diff --git a/examples/fixtures/example_kubevirt.go b/examples/fixtures/example_kubevirt.go index 47be8e5aa4..ce4804abec 100644 --- a/examples/fixtures/example_kubevirt.go +++ b/examples/fixtures/example_kubevirt.go @@ -4,7 +4,7 @@ import ( "fmt" "strings" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" corev1 "k8s.io/api/core/v1" apiresource "k8s.io/apimachinery/pkg/api/resource" ) diff --git a/go.mod b/go.mod index b35d8111b6..9a2e4ac940 100644 --- a/go.mod +++ b/go.mod @@ -259,6 +259,4 @@ replace ( kubevirt.io/client-go => kubevirt.io/client-go v0.0.0-00010101000000-000000000000 kubevirt.io/containerized-data-importer-api => github.com/kubevirt/containerized-data-importer-api v1.41.1-0.20211201033752-05520fb9f18d sigs.k8s.io/apiserver-network-proxy/konnectivity-client => sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.28.1 - sigs.k8s.io/cluster-api => sigs.k8s.io/cluster-api v1.5.3 - sigs.k8s.io/cluster-api-provider-ibmcloud => sigs.k8s.io/cluster-api-provider-ibmcloud v0.6.0 ) diff --git a/go.sum b/go.sum index 28640dd4a3..acdece7797 100644 --- a/go.sum +++ b/go.sum @@ -1015,26 +1015,7 @@ github.com/gobuffalo/flect v0.2.2/go.mod h1:vmkQwuZYhN5Pc4ljYQZzP+1sq+NEkK+lh20j github.com/gobuffalo/flect v0.2.3/go.mod h1:vmkQwuZYhN5Pc4ljYQZzP+1sq+NEkK+lh20jmEmX3jc= github.com/gobuffalo/flect v1.0.2 h1:eqjPGSo2WmjgY2XlpGwo2NXgL3RucAKo4k4qQMNA5sA= github.com/gobuffalo/flect v1.0.2/go.mod h1:A5msMlrHtLqh9umBSnvabjsMrCcCpAyzglnDvkbYKHs= -<<<<<<< HEAD -======= -github.com/gobuffalo/genny v0.0.0-20190329151137-27723ad26ef9/go.mod h1:rWs4Z12d1Zbf19rlsn0nurr75KqhYp52EAGGxTbBhNk= -github.com/gobuffalo/genny v0.0.0-20190403191548-3ca520ef0d9e/go.mod h1:80lIj3kVJWwOrXWWMRzzdhW3DsrdjILVil/SFKBzF28= -github.com/gobuffalo/genny v0.1.0/go.mod h1:XidbUqzak3lHdS//TPu2OgiFB+51Ur5f7CSnXZ/JDvo= -github.com/gobuffalo/genny v0.1.1/go.mod h1:5TExbEyY48pfunL4QSXxlDOmdsD44RRq4mVZ0Ex28Xk= -github.com/gobuffalo/gitgen v0.0.0-20190315122116-cc086187d211/go.mod h1:vEHJk/E9DmhejeLeNt7UVvlSGv3ziL+djtTr3yyzcOw= -github.com/gobuffalo/gogen v0.0.0-20190315121717-8f38393713f5/go.mod h1:V9QVDIxsgKNZs6L2IYiGR8datgMhB577vzTDqypH360= -github.com/gobuffalo/gogen v0.1.0/go.mod h1:8NTelM5qd8RZ15VjQTFkAW6qOMx5wBbW4dSCS3BY8gg= -github.com/gobuffalo/gogen v0.1.1/go.mod h1:y8iBtmHmGc4qa3urIyo1shvOD8JftTtfcKi+71xfDNE= -github.com/gobuffalo/logger v0.0.0-20190315122211-86e12af44bc2/go.mod h1:QdxcLw541hSGtBnhUc4gaNIXRjiDppFGaDqzbrBd3v8= -github.com/gobuffalo/mapi v1.0.1/go.mod h1:4VAGh89y6rVOvm5A8fKFxYG+wIW6LO1FMTG9hnKStFc= -github.com/gobuffalo/mapi v1.0.2/go.mod h1:4VAGh89y6rVOvm5A8fKFxYG+wIW6LO1FMTG9hnKStFc= -github.com/gobuffalo/packd v0.0.0-20190315124812-a385830c7fc0/go.mod h1:M2Juc+hhDXf/PnmBANFCqx4DM3wRbgDvnVWeG2RIxq4= -github.com/gobuffalo/packd v0.1.0/go.mod h1:M2Juc+hhDXf/PnmBANFCqx4DM3wRbgDvnVWeG2RIxq4= -github.com/gobuffalo/packr/v2 v2.0.9/go.mod h1:emmyGweYTm6Kdper+iywB6YK5YzuKchGtJQZ0Odn4pQ= -github.com/gobuffalo/packr/v2 v2.2.0/go.mod h1:CaAwI0GPIAv+5wKLtv8Afwl+Cm78K/I/VCm/3ptBN+0= -github.com/gobuffalo/syncx v0.0.0-20190224160051-33c29581e754/go.mod h1:HhnNqWY95UYwwW3uSASeV7vtgYkT2t16hJgV3AEPUpw= github.com/goccy/go-json v0.9.11/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MGFi0w8I= ->>>>>>> 1a9420c4b (HOSTEDCP-336: Hypershift API separation) github.com/goccy/go-yaml v1.8.1/go.mod h1:wS4gNoLalDSJxo/SpngzPQ2BN4uuZVLCmbM4S3vd4+Y= github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/gogo/protobuf v1.0.0/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= @@ -1279,23 +1260,14 @@ github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/X github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= -<<<<<<< HEAD -======= github.com/jung-kurt/gofpdf v1.0.0/go.mod h1:7Id9E/uU8ce6rXgefFLlgrJj/GYY22cpxn+r32jIOes= github.com/jung-kurt/gofpdf v1.0.3-0.20190309125859-24315acbbda5/go.mod h1:7Id9E/uU8ce6rXgefFLlgrJj/GYY22cpxn+r32jIOes= -github.com/karrick/godirwalk v1.8.0/go.mod h1:H5KPZjojv4lE+QYImBI8xVtrBRgYrIVsaRPx4tDPEn4= -github.com/karrick/godirwalk v1.10.3/go.mod h1:RoGL9dQei4vP9ilrpETWE8CLOZ1kiN0LhBygSwrAsHA= github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51/go.mod h1:CzGEWj7cYgsdH8dAjBGEr58BoE7ScuLd+fwFZ44+/x8= ->>>>>>> 1a9420c4b (HOSTEDCP-336: Hypershift API separation) github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q= github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= -<<<<<<< HEAD -======= github.com/klauspost/asmfmt v1.3.2/go.mod h1:AG8TuvYojzulgDAMCnYn50l/5QV3Bs/tp6j0HLHbNSE= -github.com/klauspost/compress v1.9.5/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= ->>>>>>> 1a9420c4b (HOSTEDCP-336: Hypershift API separation) github.com/klauspost/compress v1.13.6/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk= github.com/klauspost/compress v1.15.9/go.mod h1:PhcZ0MbTNciWF3rruxRgKxI5NkcHHrHUDtV4Yw2GlzU= github.com/klauspost/cpuid/v2 v2.0.9/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= @@ -2683,14 +2655,14 @@ sigs.k8s.io/apiserver-network-proxy v0.29.0 h1:4N+QiVBucLicDSP8V1Izf5h4t8DsKFZ34 sigs.k8s.io/apiserver-network-proxy v0.29.0/go.mod h1:TKqOJ9X/IP2ZuCmJrTgAiiCgdAs1v6fNYP7Ma33RVnk= sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.28.1 h1:suc8HHvU5zDtc5N+CiGu1YG/ipwvkv7vPB9OUMUVjW8= sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.28.1/go.mod h1:o6mPitrlgUex6ZK5mp4VerN54SOVNzSWELwWnr8wep0= -sigs.k8s.io/cluster-api v1.5.3 h1:TtxneDCps14sZ9bNr515ivBRMj9OwUE6mRUr6l7fSBA= -sigs.k8s.io/cluster-api v1.5.3/go.mod h1:0fMUk93Wf7AkQHIWLbDoKsiUHaMxnpqfLMlVmx8DX7Q= +sigs.k8s.io/cluster-api v1.6.1 h1:I34p/fwgRlEhs+o9cUhKXDwNNfPS3no0yJsd2bJyQVc= +sigs.k8s.io/cluster-api v1.6.1/go.mod h1:DaxwruDvSaEYq5q6FREDaGzX6UsAVUCA99Sp8vfMHyQ= sigs.k8s.io/cluster-api-provider-aws/v2 v2.3.1 h1:0HmdPYMYdgmPGETOMhQ0HQzVhDPmdExb/QBiR8YpV5A= sigs.k8s.io/cluster-api-provider-aws/v2 v2.3.1/go.mod h1:dOX+I3KdLY3C1F0iPQQhV0Po2qPTO9sb6ogN8TOw5sY= sigs.k8s.io/cluster-api-provider-azure v1.13.0 h1:1FPaKflYhfckqmYlIpbtr82LgAqHdSHzVxdiW7I3EG0= sigs.k8s.io/cluster-api-provider-azure v1.13.0/go.mod h1:uKcphoKB5FThLp4iAI42mAXZaR7AFNDH9DFParHjzL0= -sigs.k8s.io/cluster-api-provider-ibmcloud v0.6.0 h1:uRVgEyZn0cp4ou2tBGEzm9kA4XQBZRWrrX19jPSV07Y= -sigs.k8s.io/cluster-api-provider-ibmcloud v0.6.0/go.mod h1:/YGABlED5qr9BWAR7TMq7xxa0gO09uxqPaiQvvu5JbQ= +sigs.k8s.io/cluster-api-provider-ibmcloud v0.7.0 h1:3IDw0U2ZFX/RQmJ2mFu3ibQ5mBUUcG1ShcHm7eLHGJ4= +sigs.k8s.io/cluster-api-provider-ibmcloud v0.7.0/go.mod h1:/tqPsGYcODyLUP+DcqMZDeF2l2jiE9qET32s8/eeJTA= sigs.k8s.io/cluster-api-provider-kubevirt v0.1.8 h1:YsvcTxGuBcCeLF/+8Z4yxFuiGRS6yXMDMj0KitSt528= sigs.k8s.io/cluster-api-provider-kubevirt v0.1.8/go.mod h1:N823VwItvoON1ykmV1nkhRvMr5wezi7XLNem7NYhVps= sigs.k8s.io/controller-runtime v0.8.3/go.mod h1:U/l+DUopBc1ecfRZ5aviA9JDmGFQKvLf5YkZNx2e0sU= diff --git a/hack/app-sre/saas_template.yaml b/hack/app-sre/saas_template.yaml index 8c722b71e4..11510b4982 100644 --- a/hack/app-sre/saas_template.yaml +++ b/hack/app-sre/saas_template.yaml @@ -1595,7 +1595,6 @@ objects: type: string type: array type: object -<<<<<<< HEAD machinePoolClass: description: |- MachinePoolClass selects templates referenced in specific MachinePoolClasses in @@ -1608,8 +1607,6 @@ objects: type: string type: array type: object -======= ->>>>>>> fe0c9b3f6 (HOSTEDCP-336: Hypershift API separation) type: object required: - apiVersion @@ -2069,13 +2066,9 @@ objects: x-kubernetes-int-or-string: true type: object type: -<<<<<<< HEAD description: |- Type of deployment. Allowed values are RollingUpdate and OnDelete. The default is RollingUpdate. -======= - description: Type of deployment. Default is RollingUpdate. ->>>>>>> fe0c9b3f6 (HOSTEDCP-336: Hypershift API separation) enum: - RollingUpdate - OnDelete @@ -2227,7 +2220,6 @@ objects: - template type: object type: array -<<<<<<< HEAD machinePools: description: |- MachinePools is a list of machine pool classes that can be used to create @@ -2442,8 +2434,6 @@ objects: - template type: object type: array -======= ->>>>>>> fe0c9b3f6 (HOSTEDCP-336: Hypershift API separation) type: object type: object status: @@ -2721,6 +2711,11 @@ objects: scope: Namespaced versions: - additionalPrinterColumns: + - description: ClusterClass of this Cluster, empty if the Cluster is not using + a ClusterClass + jsonPath: .spec.topology.class + name: ClusterClass + type: string - description: Cluster status such as Pending/Provisioning/Provisioned/Deleting/Failed jsonPath: .status.phase name: Phase @@ -3404,13 +3399,9 @@ objects: x-kubernetes-int-or-string: true type: object type: -<<<<<<< HEAD description: |- Type of deployment. Allowed values are RollingUpdate and OnDelete. The default is RollingUpdate. -======= - description: Type of deployment. Default is RollingUpdate. ->>>>>>> fe0c9b3f6 (HOSTEDCP-336: Hypershift API separation) enum: - RollingUpdate - OnDelete @@ -3459,7 +3450,6 @@ objects: - name type: object type: array -<<<<<<< HEAD machinePools: description: MachinePools is a list of machine pools in the cluster. @@ -3588,8 +3578,6 @@ objects: - name type: object type: array -======= ->>>>>>> fe0c9b3f6 (HOSTEDCP-336: Hypershift API separation) type: object required: - class @@ -3958,13 +3946,9 @@ objects: x-kubernetes-int-or-string: true type: object type: -<<<<<<< HEAD description: |- Type of deployment. Allowed values are RollingUpdate and OnDelete. The default is RollingUpdate. -======= - description: Type of deployment. Default is RollingUpdate. ->>>>>>> fe0c9b3f6 (HOSTEDCP-336: Hypershift API separation) enum: - RollingUpdate - OnDelete @@ -25196,6 +25180,8 @@ objects: address: type: string floatingIPID: + description: 'Deprecated: This field has no function and is + going to be removed in the next release.' type: string loadBalancerIPID: type: string @@ -25377,6 +25363,8 @@ objects: address: type: string floatingIPID: + description: 'Deprecated: This field has no function and is + going to be removed in the next release.' type: string loadBalancerIPID: type: string @@ -25401,7 +25389,6 @@ objects: annotations: controller-gen.kubebuilder.io/version: v0.14.0 creationTimestamp: null -<<<<<<< HEAD name: ibmvpcclustertemplates.infrastructure.cluster.x-k8s.io spec: group: infrastructure.cluster.x-k8s.io @@ -25543,8 +25530,6 @@ objects: annotations: controller-gen.kubebuilder.io/version: v0.14.0 creationTimestamp: null -======= ->>>>>>> fe0c9b3f6 (HOSTEDCP-336: Hypershift API separation) name: ibmvpcmachines.infrastructure.cluster.x-k8s.io spec: group: infrastructure.cluster.x-k8s.io diff --git a/hack/gen-api-docs.sh b/hack/gen-api-docs.sh index 3f83da7b1f..dbfd86b22c 100755 --- a/hack/gen-api-docs.sh +++ b/hack/gen-api-docs.sh @@ -24,5 +24,5 @@ export GO111MODULE="off" ${GEN_BIN} \ --config "${FAKE_REPOPATH}/docs/api-doc-gen/config.json" \ --template-dir "${FAKE_REPOPATH}/docs/api-doc-gen/templates" \ ---api-dir ./api/types/hypershift/v1beta1 \ +--api-dir ./api/hypershift/v1beta1 \ --out-file "${FAKE_REPOPATH}/docs/content/reference/api.md" diff --git a/hack/tools/go.mod b/hack/tools/go.mod index f5f7d6b249..e3bbe65268 100644 --- a/hack/tools/go.mod +++ b/hack/tools/go.mod @@ -11,7 +11,7 @@ require ( sigs.k8s.io/controller-tools v0.14.0 ) -replace k8s.io/code-generator => github.com/stevekuznetsov/k8s-code-generator v0.0.0-20231218200749-2151937f4610 +replace k8s.io/code-generator => github.com/jparrill/code-generator v0.0.0-20240205120635-697bef95b1c3 require ( cloud.google.com/go/compute v1.23.3 // indirect diff --git a/hack/tools/go.sum b/hack/tools/go.sum index e4905cecbe..de7d041e82 100644 --- a/hack/tools/go.sum +++ b/hack/tools/go.sum @@ -416,6 +416,8 @@ github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfC github.com/joho/godotenv v1.3.0/go.mod h1:7hK45KPybAkOC6peb+G5yklZfMxEjkZhHbwpqxOKXbg= 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/jparrill/code-generator v0.0.0-20240205120635-697bef95b1c3 h1:sgeo7lhmhvVOPACabF9qLmoYz8jD86h1Jr5URyQne0Y= +github.com/jparrill/code-generator v0.0.0-20240205120635-697bef95b1c3/go.mod h1:C1oDIDCuN+hZsr8bZVFUp6dsOKvvMZ6jcmE4SFQn//8= github.com/jpillora/backoff v1.0.0 h1:uvFg412JmmHBHw7iwprIxkPMI+sGQ4kzOWsMeHnm2EA= github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= @@ -608,8 +610,6 @@ github.com/spf13/cobra v1.8.0/go.mod h1:WXLWApfZ71AjXPya3WOlMsY9yMs7YeiHhFVlvLyh github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= -github.com/stevekuznetsov/k8s-code-generator v0.0.0-20231218200749-2151937f4610 h1:DE8bxqW3Pz2tPP32l/NiZpx7PW1WIaLv2WaFuQHOOuA= -github.com/stevekuznetsov/k8s-code-generator v0.0.0-20231218200749-2151937f4610/go.mod h1:C1oDIDCuN+hZsr8bZVFUp6dsOKvvMZ6jcmE4SFQn//8= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= diff --git a/hack/tools/vendor/k8s.io/code-generator/kube_codegen.sh b/hack/tools/vendor/k8s.io/code-generator/kube_codegen.sh index a030731088..150ae36707 100644 --- a/hack/tools/vendor/k8s.io/code-generator/kube_codegen.sh +++ b/hack/tools/vendor/k8s.io/code-generator/kube_codegen.sh @@ -33,7 +33,7 @@ function kube::codegen::internal::git_find() { function kube::codegen::internal::git_grep() { # We want to include modified and untracked files because this might be # running against code which is not tracked by git yet. - git grep --untracked "$@" + git grep --untracked "$@" ":(exclude)*vendor/" } # Generate tagged helper code: conversions, deepcopy, and defaults diff --git a/hack/tools/vendor/modules.txt b/hack/tools/vendor/modules.txt index ab1d91ec96..bab62a9ece 100644 --- a/hack/tools/vendor/modules.txt +++ b/hack/tools/vendor/modules.txt @@ -1334,7 +1334,7 @@ k8s.io/client-go/util/flowcontrol k8s.io/client-go/util/homedir k8s.io/client-go/util/keyutil k8s.io/client-go/util/workqueue -# k8s.io/code-generator v0.29.0 => github.com/stevekuznetsov/k8s-code-generator v0.0.0-20231218200749-2151937f4610 +# k8s.io/code-generator v0.29.0 => github.com/jparrill/code-generator v0.0.0-20240205120635-697bef95b1c3 ## explicit; go 1.21.3 k8s.io/code-generator k8s.io/code-generator/cmd/applyconfiguration-gen @@ -1454,4 +1454,4 @@ sigs.k8s.io/structured-merge-diff/v4/value ## explicit; go 1.12 sigs.k8s.io/yaml sigs.k8s.io/yaml/goyaml.v2 -# k8s.io/code-generator => github.com/stevekuznetsov/k8s-code-generator v0.0.0-20231218200749-2151937f4610 +# k8s.io/code-generator => github.com/jparrill/code-generator v0.0.0-20240205120635-697bef95b1c3 diff --git a/hack/update-codegen.sh b/hack/update-codegen.sh index 0625a9a8fa..1df7d731f0 100755 --- a/hack/update-codegen.sh +++ b/hack/update-codegen.sh @@ -21,7 +21,7 @@ trap "rm -rf ${PROJECT_ROOT}/github.com" EXIT kube::codegen::gen_client \ --with-watch \ --with-applyconfig \ - --input-pkg-root github.com/openshift/hypershift/api/types \ + --input-pkg-root github.com/openshift/hypershift/api \ --output-pkg-root github.com/openshift/hypershift/client \ --output-base "$(dirname "${BASH_SOURCE[0]}")/.." \ --versioned-name clientset \ diff --git a/hypershift-operator/controllers/hostedcluster/hostedcluster_controller.go b/hypershift-operator/controllers/hostedcluster/hostedcluster_controller.go index c65649cfa8..c7bd5e6b68 100644 --- a/hypershift-operator/controllers/hostedcluster/hostedcluster_controller.go +++ b/hypershift-operator/controllers/hostedcluster/hostedcluster_controller.go @@ -76,7 +76,7 @@ import ( ctrllog "sigs.k8s.io/controller-runtime/pkg/log" "sigs.k8s.io/controller-runtime/pkg/reconcile" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/api/util/configrefs" "github.com/openshift/hypershift/cmd/util" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/autoscaler" diff --git a/hypershift-operator/controllers/hostedcluster/hostedcluster_controller_test.go b/hypershift-operator/controllers/hostedcluster/hostedcluster_controller_test.go index f101a5c212..3c3360b10a 100644 --- a/hypershift-operator/controllers/hostedcluster/hostedcluster_controller_test.go +++ b/hypershift-operator/controllers/hostedcluster/hostedcluster_controller_test.go @@ -14,7 +14,7 @@ import ( "github.com/google/go-cmp/cmp" . "github.com/onsi/gomega" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/api/util/ipnet" "github.com/openshift/hypershift/cmd/version" "github.com/openshift/hypershift/control-plane-operator/hostedclusterconfigoperator/controllers/resources/manifests" diff --git a/hypershift-operator/controllers/hostedcluster/hostedcluster_webhook.go b/hypershift-operator/controllers/hostedcluster/hostedcluster_webhook.go index 851ef07103..2c168c86e3 100644 --- a/hypershift-operator/controllers/hostedcluster/hostedcluster_webhook.go +++ b/hypershift-operator/controllers/hostedcluster/hostedcluster_webhook.go @@ -15,9 +15,8 @@ import ( "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/webhook/admission" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/conversion" - "github.com/openshift/hypershift/kubevirtexternalinfra" "github.com/openshift/hypershift/support/supportedversion" hyperutil "github.com/openshift/hypershift/support/util" ) @@ -125,12 +124,6 @@ func SetupWebhookWithManager(mgr ctrl.Manager, imageMetaDataProvider *hyperutil. mgr.GetWebhookServer().Register("/convert", conversion.NewWebhookHandler(mgr.GetScheme())) - kvValidator = &kubevirtClusterValidator{ - client: mgr.GetClient(), - clientMap: kubevirtexternalinfra.NewKubevirtInfraClientMap(), - imageMetaDataProvider: imageMetaDataProvider, - } - err := ctrl.NewWebhookManagedBy(mgr). For(&hyperv1.HostedCluster{}). WithDefaulter(&hostedClusterDefaulter{}). diff --git a/hypershift-operator/controllers/hostedcluster/hostedcluster_webhook_test.go b/hypershift-operator/controllers/hostedcluster/hostedcluster_webhook_test.go index 74b485f78f..a8403f6098 100644 --- a/hypershift-operator/controllers/hostedcluster/hostedcluster_webhook_test.go +++ b/hypershift-operator/controllers/hostedcluster/hostedcluster_webhook_test.go @@ -8,7 +8,7 @@ import ( corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + "github.com/openshift/hypershift/api/hypershift/v1beta1" apiexample "github.com/openshift/hypershift/examples/fixtures" ) diff --git a/hypershift-operator/controllers/hostedcluster/ignitionserver/ignitionserver.go b/hypershift-operator/controllers/hostedcluster/ignitionserver/ignitionserver.go index d1aa2c6068..7cbc1e26aa 100644 --- a/hypershift-operator/controllers/hostedcluster/ignitionserver/ignitionserver.go +++ b/hypershift-operator/controllers/hostedcluster/ignitionserver/ignitionserver.go @@ -6,7 +6,7 @@ import ( "net" routev1 "github.com/openshift/api/route/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/controlplaneoperator" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/ignitionserver" diff --git a/hypershift-operator/controllers/hostedcluster/internal/platform/agent/agent.go b/hypershift-operator/controllers/hostedcluster/internal/platform/agent/agent.go index b59e40ae6e..e12206ae3e 100644 --- a/hypershift-operator/controllers/hostedcluster/internal/platform/agent/agent.go +++ b/hypershift-operator/controllers/hostedcluster/internal/platform/agent/agent.go @@ -6,7 +6,7 @@ import ( "os" agentv1 "github.com/openshift/cluster-api-provider-agent/api/v1beta1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/ignitionserver" "github.com/openshift/hypershift/support/images" "github.com/openshift/hypershift/support/upsert" diff --git a/hypershift-operator/controllers/hostedcluster/internal/platform/agent/agent_test.go b/hypershift-operator/controllers/hostedcluster/internal/platform/agent/agent_test.go index fd468f3460..f8a99c92e9 100644 --- a/hypershift-operator/controllers/hostedcluster/internal/platform/agent/agent_test.go +++ b/hypershift-operator/controllers/hostedcluster/internal/platform/agent/agent_test.go @@ -8,7 +8,7 @@ import ( "github.com/google/go-cmp/cmp" . "github.com/onsi/gomega" agentv1 "github.com/openshift/cluster-api-provider-agent/api/v1beta1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/ignitionserver" hyperapi "github.com/openshift/hypershift/support/api" diff --git a/hypershift-operator/controllers/hostedcluster/internal/platform/aws/aws.go b/hypershift-operator/controllers/hostedcluster/internal/platform/aws/aws.go index eb53c13cf4..822d18062d 100644 --- a/hypershift-operator/controllers/hostedcluster/internal/platform/aws/aws.go +++ b/hypershift-operator/controllers/hostedcluster/internal/platform/aws/aws.go @@ -8,7 +8,7 @@ import ( utilerrors "k8s.io/apimachinery/pkg/util/errors" "github.com/blang/semver" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/kas" "github.com/openshift/hypershift/support/images" "github.com/openshift/hypershift/support/upsert" diff --git a/hypershift-operator/controllers/hostedcluster/internal/platform/aws/aws_test.go b/hypershift-operator/controllers/hostedcluster/internal/platform/aws/aws_test.go index ea62e1cd5a..f724f8622c 100644 --- a/hypershift-operator/controllers/hostedcluster/internal/platform/aws/aws_test.go +++ b/hypershift-operator/controllers/hostedcluster/internal/platform/aws/aws_test.go @@ -4,7 +4,7 @@ import ( "testing" "github.com/google/go-cmp/cmp" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "k8s.io/apimachinery/pkg/api/meta" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" capiaws "sigs.k8s.io/cluster-api-provider-aws/v2/api/v1beta2" diff --git a/hypershift-operator/controllers/hostedcluster/internal/platform/azure/azure.go b/hypershift-operator/controllers/hostedcluster/internal/platform/azure/azure.go index b8ca299f1f..6de2994546 100644 --- a/hypershift-operator/controllers/hostedcluster/internal/platform/azure/azure.go +++ b/hypershift-operator/controllers/hostedcluster/internal/platform/azure/azure.go @@ -5,7 +5,7 @@ import ( "fmt" "os" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/images" "github.com/openshift/hypershift/support/upsert" diff --git a/hypershift-operator/controllers/hostedcluster/internal/platform/ibmcloud/ibmcloud.go b/hypershift-operator/controllers/hostedcluster/internal/platform/ibmcloud/ibmcloud.go index 51e8e23da5..2176d404cf 100644 --- a/hypershift-operator/controllers/hostedcluster/internal/platform/ibmcloud/ibmcloud.go +++ b/hypershift-operator/controllers/hostedcluster/internal/platform/ibmcloud/ibmcloud.go @@ -8,7 +8,7 @@ import ( corev1 "k8s.io/api/core/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/upsert" appsv1 "k8s.io/api/apps/v1" rbacv1 "k8s.io/api/rbac/v1" diff --git a/hypershift-operator/controllers/hostedcluster/internal/platform/ibmcloud/ibmcloud_test.go b/hypershift-operator/controllers/hostedcluster/internal/platform/ibmcloud/ibmcloud_test.go index 727b2b4e59..2d71af54dc 100644 --- a/hypershift-operator/controllers/hostedcluster/internal/platform/ibmcloud/ibmcloud_test.go +++ b/hypershift-operator/controllers/hostedcluster/internal/platform/ibmcloud/ibmcloud_test.go @@ -7,7 +7,7 @@ import ( "github.com/google/go-cmp/cmp" . "github.com/onsi/gomega" v1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/api" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" capiibmv1 "sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2" diff --git a/hypershift-operator/controllers/hostedcluster/internal/platform/kubevirt/kubevirt.go b/hypershift-operator/controllers/hostedcluster/internal/platform/kubevirt/kubevirt.go index 4253ed8a90..8079f8c53f 100644 --- a/hypershift-operator/controllers/hostedcluster/internal/platform/kubevirt/kubevirt.go +++ b/hypershift-operator/controllers/hostedcluster/internal/platform/kubevirt/kubevirt.go @@ -5,7 +5,7 @@ import ( "fmt" "os" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/images" "github.com/openshift/hypershift/support/upsert" appsv1 "k8s.io/api/apps/v1" diff --git a/hypershift-operator/controllers/hostedcluster/internal/platform/kubevirt/kubevirt_test.go b/hypershift-operator/controllers/hostedcluster/internal/platform/kubevirt/kubevirt_test.go index ceac3aee95..b74e7758f9 100644 --- a/hypershift-operator/controllers/hostedcluster/internal/platform/kubevirt/kubevirt_test.go +++ b/hypershift-operator/controllers/hostedcluster/internal/platform/kubevirt/kubevirt_test.go @@ -6,7 +6,7 @@ import ( "testing" "github.com/google/go-cmp/cmp" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "k8s.io/apimachinery/pkg/api/equality" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" capikubevirt "sigs.k8s.io/cluster-api-provider-kubevirt/api/v1alpha1" diff --git a/hypershift-operator/controllers/hostedcluster/internal/platform/none/none.go b/hypershift-operator/controllers/hostedcluster/internal/platform/none/none.go index 970c89971b..a886aac72f 100644 --- a/hypershift-operator/controllers/hostedcluster/internal/platform/none/none.go +++ b/hypershift-operator/controllers/hostedcluster/internal/platform/none/none.go @@ -3,7 +3,7 @@ package none import ( "context" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/upsert" appsv1 "k8s.io/api/apps/v1" rbacv1 "k8s.io/api/rbac/v1" diff --git a/hypershift-operator/controllers/hostedcluster/internal/platform/platform.go b/hypershift-operator/controllers/hostedcluster/internal/platform/platform.go index 37b4c0ddcd..f379cd3db0 100644 --- a/hypershift-operator/controllers/hostedcluster/internal/platform/platform.go +++ b/hypershift-operator/controllers/hostedcluster/internal/platform/platform.go @@ -5,7 +5,7 @@ import ( "fmt" "github.com/blang/semver" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/hostedcluster/internal/platform/agent" "github.com/openshift/hypershift/hypershift-operator/controllers/hostedcluster/internal/platform/aws" "github.com/openshift/hypershift/hypershift-operator/controllers/hostedcluster/internal/platform/azure" diff --git a/hypershift-operator/controllers/hostedcluster/internal/platform/powervs/powervs.go b/hypershift-operator/controllers/hostedcluster/internal/platform/powervs/powervs.go index 4b6e9e437d..d8c5244319 100644 --- a/hypershift-operator/controllers/hostedcluster/internal/platform/powervs/powervs.go +++ b/hypershift-operator/controllers/hostedcluster/internal/platform/powervs/powervs.go @@ -16,7 +16,7 @@ import ( capiv1 "sigs.k8s.io/cluster-api/api/v1beta1" "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/images" "github.com/openshift/hypershift/support/upsert" ) diff --git a/hypershift-operator/controllers/hostedcluster/metrics/metrics.go b/hypershift-operator/controllers/hostedcluster/metrics/metrics.go index c3efc6c2b8..e7c450a5c9 100644 --- a/hypershift-operator/controllers/hostedcluster/metrics/metrics.go +++ b/hypershift-operator/controllers/hostedcluster/metrics/metrics.go @@ -5,7 +5,7 @@ import ( "time" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" platformaws "github.com/openshift/hypershift/hypershift-operator/controllers/hostedcluster/internal/platform/aws" "github.com/openshift/hypershift/support/conditions" "github.com/prometheus/client_golang/prometheus" diff --git a/hypershift-operator/controllers/hostedcluster/metrics/metrics_test.go b/hypershift-operator/controllers/hostedcluster/metrics/metrics_test.go index 256e9b4d65..74cd07d84e 100644 --- a/hypershift-operator/controllers/hostedcluster/metrics/metrics_test.go +++ b/hypershift-operator/controllers/hostedcluster/metrics/metrics_test.go @@ -7,7 +7,7 @@ import ( "github.com/google/go-cmp/cmp" "github.com/google/go-cmp/cmp/cmpopts" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/api" "github.com/prometheus/client_golang/prometheus" dto "github.com/prometheus/client_model/go" diff --git a/hypershift-operator/controllers/hostedcluster/network_policies.go b/hypershift-operator/controllers/hostedcluster/network_policies.go index 08efdd4736..71e97c3435 100644 --- a/hypershift-operator/controllers/hostedcluster/network_policies.go +++ b/hypershift-operator/controllers/hostedcluster/network_policies.go @@ -8,7 +8,7 @@ import ( "github.com/blang/semver" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/networkpolicy" "github.com/openshift/hypershift/support/capabilities" diff --git a/hypershift-operator/controllers/manifests/controlplaneoperator/manifests.go b/hypershift-operator/controllers/manifests/controlplaneoperator/manifests.go index 91a2c6a00f..16f33b7393 100644 --- a/hypershift-operator/controllers/manifests/controlplaneoperator/manifests.go +++ b/hypershift-operator/controllers/manifests/controlplaneoperator/manifests.go @@ -1,7 +1,7 @@ package controlplaneoperator import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" prometheusoperatorv1 "github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring/v1" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" diff --git a/hypershift-operator/controllers/manifests/controlplanepkioperator/manifests.go b/hypershift-operator/controllers/manifests/controlplanepkioperator/manifests.go index a8c0052442..73ca08ad48 100644 --- a/hypershift-operator/controllers/manifests/controlplanepkioperator/manifests.go +++ b/hypershift-operator/controllers/manifests/controlplanepkioperator/manifests.go @@ -3,7 +3,7 @@ package controlplanepkioperator import ( "fmt" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" rbacv1 "k8s.io/api/rbac/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/hypershift-operator/controllers/manifests/controlplanepkioperator/reconcile.go b/hypershift-operator/controllers/manifests/controlplanepkioperator/reconcile.go index f67b793f97..9bc65262ca 100644 --- a/hypershift-operator/controllers/manifests/controlplanepkioperator/reconcile.go +++ b/hypershift-operator/controllers/manifests/controlplanepkioperator/reconcile.go @@ -4,7 +4,7 @@ import ( corev1 "k8s.io/api/core/v1" rbacv1 "k8s.io/api/rbac/v1" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-pki-operator/certificates" ) diff --git a/hypershift-operator/controllers/manifests/controlplanepkioperator/reconcile_test.go b/hypershift-operator/controllers/manifests/controlplanepkioperator/reconcile_test.go index 1c0cfb1d42..553c08c9b0 100644 --- a/hypershift-operator/controllers/manifests/controlplanepkioperator/reconcile_test.go +++ b/hypershift-operator/controllers/manifests/controlplanepkioperator/reconcile_test.go @@ -3,7 +3,7 @@ package controlplanepkioperator_test import ( "testing" - hypershiftv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hypershiftv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/control-plane-pki-operator/certificates" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/controlplanepkioperator" diff --git a/hypershift-operator/controllers/nodepool/agent.go b/hypershift-operator/controllers/nodepool/agent.go index 6838b58008..744caea7f7 100644 --- a/hypershift-operator/controllers/nodepool/agent.go +++ b/hypershift-operator/controllers/nodepool/agent.go @@ -2,7 +2,7 @@ package nodepool import ( agentv1 "github.com/openshift/cluster-api-provider-agent/api/v1beta1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func agentMachineTemplateSpec(nodePool *hyperv1.NodePool) *agentv1.AgentMachineTemplateSpec { diff --git a/hypershift-operator/controllers/nodepool/aws.go b/hypershift-operator/controllers/nodepool/aws.go index 881100909b..185b3e1244 100644 --- a/hypershift-operator/controllers/nodepool/aws.go +++ b/hypershift-operator/controllers/nodepool/aws.go @@ -3,7 +3,7 @@ package nodepool import ( "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" k8sutilspointer "k8s.io/utils/pointer" capiaws "sigs.k8s.io/cluster-api-provider-aws/v2/api/v1beta2" ) diff --git a/hypershift-operator/controllers/nodepool/aws_test.go b/hypershift-operator/controllers/nodepool/aws_test.go index 8cbee61a31..75028137e7 100644 --- a/hypershift-operator/controllers/nodepool/aws_test.go +++ b/hypershift-operator/controllers/nodepool/aws_test.go @@ -4,7 +4,7 @@ import ( "testing" "github.com/google/go-cmp/cmp" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "k8s.io/apimachinery/pkg/api/equality" k8sutilspointer "k8s.io/utils/pointer" capiaws "sigs.k8s.io/cluster-api-provider-aws/v2/api/v1beta2" diff --git a/hypershift-operator/controllers/nodepool/azure.go b/hypershift-operator/controllers/nodepool/azure.go index b1c237a3bd..9f2b1869e1 100644 --- a/hypershift-operator/controllers/nodepool/azure.go +++ b/hypershift-operator/controllers/nodepool/azure.go @@ -8,7 +8,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "golang.org/x/crypto/ssh" utilpointer "k8s.io/utils/pointer" diff --git a/hypershift-operator/controllers/nodepool/azure_test.go b/hypershift-operator/controllers/nodepool/azure_test.go index 02b2b97563..6551f75ea1 100644 --- a/hypershift-operator/controllers/nodepool/azure_test.go +++ b/hypershift-operator/controllers/nodepool/azure_test.go @@ -3,7 +3,7 @@ package nodepool import ( "testing" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func TestBootImage(t *testing.T) { diff --git a/hypershift-operator/controllers/nodepool/conditions.go b/hypershift-operator/controllers/nodepool/conditions.go index 053c708fa6..5eab3954de 100644 --- a/hypershift-operator/controllers/nodepool/conditions.go +++ b/hypershift-operator/controllers/nodepool/conditions.go @@ -5,7 +5,7 @@ import ( "strconv" "time" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/util" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/hypershift-operator/controllers/nodepool/conditions_test.go b/hypershift-operator/controllers/nodepool/conditions_test.go index 15885ce89c..d95399e43a 100644 --- a/hypershift-operator/controllers/nodepool/conditions_test.go +++ b/hypershift-operator/controllers/nodepool/conditions_test.go @@ -5,7 +5,7 @@ import ( "testing" "time" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" corev1 "k8s.io/api/core/v1" "k8s.io/utils/pointer" diff --git a/hypershift-operator/controllers/nodepool/haproxy.go b/hypershift-operator/controllers/nodepool/haproxy.go index 660b3dddf0..7a00c2b7de 100644 --- a/hypershift-operator/controllers/nodepool/haproxy.go +++ b/hypershift-operator/controllers/nodepool/haproxy.go @@ -12,7 +12,7 @@ import ( "github.com/clarketm/json" ignitionapi "github.com/coreos/ignition/v2/config/v3_2/types" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/ignition" "github.com/openshift/hypershift/hypershift-operator/controllers/hostedcluster" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" diff --git a/hypershift-operator/controllers/nodepool/haproxy_test.go b/hypershift-operator/controllers/nodepool/haproxy_test.go index a2c94e16c5..f7be8ea341 100644 --- a/hypershift-operator/controllers/nodepool/haproxy_test.go +++ b/hypershift-operator/controllers/nodepool/haproxy_test.go @@ -7,7 +7,7 @@ import ( "testing" ignitionapi "github.com/coreos/ignition/v2/config/v3_2/types" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/api/util/ipnet" "github.com/openshift/hypershift/support/testutil" mcfgv1 "github.com/openshift/hypershift/thirdparty/machineconfigoperator/pkg/apis/machineconfiguration.openshift.io/v1" diff --git a/hypershift-operator/controllers/nodepool/inplace.go b/hypershift-operator/controllers/nodepool/inplace.go index 49e5e34586..ddaa7f2582 100644 --- a/hypershift-operator/controllers/nodepool/inplace.go +++ b/hypershift-operator/controllers/nodepool/inplace.go @@ -5,7 +5,7 @@ import ( "fmt" "strconv" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/api" corev1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/util/intstr" diff --git a/hypershift-operator/controllers/nodepool/inplace_test.go b/hypershift-operator/controllers/nodepool/inplace_test.go index f7c65e6eee..7044c8426e 100644 --- a/hypershift-operator/controllers/nodepool/inplace_test.go +++ b/hypershift-operator/controllers/nodepool/inplace_test.go @@ -4,7 +4,7 @@ import ( "testing" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" k8sutilspointer "k8s.io/utils/pointer" capiv1 "sigs.k8s.io/cluster-api/api/v1beta1" diff --git a/hypershift-operator/controllers/nodepool/kubevirt/imagecacher.go b/hypershift-operator/controllers/nodepool/kubevirt/imagecacher.go index 38e97fbb8b..b686ddefef 100644 --- a/hypershift-operator/controllers/nodepool/kubevirt/imagecacher.go +++ b/hypershift-operator/controllers/nodepool/kubevirt/imagecacher.go @@ -14,7 +14,7 @@ import ( ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) const ( diff --git a/hypershift-operator/controllers/nodepool/kubevirt/kubevirt.go b/hypershift-operator/controllers/nodepool/kubevirt/kubevirt.go index 74c87af83d..bd3dc4e0b5 100644 --- a/hypershift-operator/controllers/nodepool/kubevirt/kubevirt.go +++ b/hypershift-operator/controllers/nodepool/kubevirt/kubevirt.go @@ -15,7 +15,7 @@ import ( "kubevirt.io/containerized-data-importer-api/pkg/apis/core/v1beta1" capikubevirt "sigs.k8s.io/cluster-api-provider-kubevirt/api/v1alpha1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" suppconfig "github.com/openshift/hypershift/support/config" "github.com/openshift/hypershift/support/releaseinfo" ) diff --git a/hypershift-operator/controllers/nodepool/kubevirt/kubevirt_test.go b/hypershift-operator/controllers/nodepool/kubevirt/kubevirt_test.go index 7bf63f482a..d941e0d2d3 100644 --- a/hypershift-operator/controllers/nodepool/kubevirt/kubevirt_test.go +++ b/hypershift-operator/controllers/nodepool/kubevirt/kubevirt_test.go @@ -23,7 +23,7 @@ import ( "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/client/fake" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) const ( diff --git a/hypershift-operator/controllers/nodepool/manifests.go b/hypershift-operator/controllers/nodepool/manifests.go index ac95a1db58..26088ffb17 100644 --- a/hypershift-operator/controllers/nodepool/manifests.go +++ b/hypershift-operator/controllers/nodepool/manifests.go @@ -3,7 +3,7 @@ package nodepool import ( "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" capiv1 "sigs.k8s.io/cluster-api/api/v1beta1" diff --git a/hypershift-operator/controllers/nodepool/metrics/metrics.go b/hypershift-operator/controllers/nodepool/metrics/metrics.go index 4b24851976..e335022da4 100644 --- a/hypershift-operator/controllers/nodepool/metrics/metrics.go +++ b/hypershift-operator/controllers/nodepool/metrics/metrics.go @@ -7,7 +7,7 @@ import ( "github.com/aws/aws-sdk-go/service/ec2" "github.com/aws/aws-sdk-go/service/ec2/ec2iface" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" "github.com/openshift/hypershift/support/conditions" "github.com/prometheus/client_golang/prometheus" diff --git a/hypershift-operator/controllers/nodepool/metrics/metrics_test.go b/hypershift-operator/controllers/nodepool/metrics/metrics_test.go index db8bb9b32d..4d93b0702f 100644 --- a/hypershift-operator/controllers/nodepool/metrics/metrics_test.go +++ b/hypershift-operator/controllers/nodepool/metrics/metrics_test.go @@ -8,7 +8,7 @@ import ( "github.com/aws/aws-sdk-go/service/ec2/ec2iface" "github.com/google/go-cmp/cmp" "github.com/google/go-cmp/cmp/cmpopts" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/api" "github.com/prometheus/client_golang/prometheus" dto "github.com/prometheus/client_model/go" diff --git a/hypershift-operator/controllers/nodepool/nodepool_controller.go b/hypershift-operator/controllers/nodepool/nodepool_controller.go index fc07f9b106..5088bbae98 100644 --- a/hypershift-operator/controllers/nodepool/nodepool_controller.go +++ b/hypershift-operator/controllers/nodepool/nodepool_controller.go @@ -21,7 +21,7 @@ import ( agentv1 "github.com/openshift/cluster-api-provider-agent/api/v1beta1" tunedv1 "github.com/openshift/cluster-node-tuning-operator/pkg/apis/tuned/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/hostedcluster" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests/ignitionserver" diff --git a/hypershift-operator/controllers/nodepool/nodepool_controller_test.go b/hypershift-operator/controllers/nodepool/nodepool_controller_test.go index 4beb52ca3b..325ad51773 100644 --- a/hypershift-operator/controllers/nodepool/nodepool_controller_test.go +++ b/hypershift-operator/controllers/nodepool/nodepool_controller_test.go @@ -28,7 +28,7 @@ import ( "sigs.k8s.io/controller-runtime/pkg/client/fake" "sigs.k8s.io/controller-runtime/pkg/reconcile" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/api/util/ipnet" "github.com/openshift/hypershift/hypershift-operator/controllers/hostedcluster" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" diff --git a/hypershift-operator/controllers/nodepool/powervs.go b/hypershift-operator/controllers/nodepool/powervs.go index bc25cbf72d..868bd77778 100644 --- a/hypershift-operator/controllers/nodepool/powervs.go +++ b/hypershift-operator/controllers/nodepool/powervs.go @@ -3,7 +3,7 @@ package nodepool import ( "fmt" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/releaseinfo" v1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/hypershift-operator/controllers/platform/aws/controller.go b/hypershift-operator/controllers/platform/aws/controller.go index 830897f370..960f63130f 100644 --- a/hypershift-operator/controllers/platform/aws/controller.go +++ b/hypershift-operator/controllers/platform/aws/controller.go @@ -18,7 +18,7 @@ import ( "github.com/aws/aws-sdk-go/service/elbv2/elbv2iface" "github.com/go-logr/logr" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" awsutil "github.com/openshift/hypershift/cmd/infra/aws/util" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/hypershift-operator/controllers/hostedcluster" diff --git a/hypershift-operator/controllers/platform/aws/controller_test.go b/hypershift-operator/controllers/platform/aws/controller_test.go index 7c9f48f47f..f183e0fe6c 100644 --- a/hypershift-operator/controllers/platform/aws/controller_test.go +++ b/hypershift-operator/controllers/platform/aws/controller_test.go @@ -13,7 +13,7 @@ import ( "github.com/aws/aws-sdk-go/service/elbv2/elbv2iface" "github.com/go-logr/logr/testr" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hyperapi "github.com/openshift/hypershift/support/api" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "sigs.k8s.io/controller-runtime/pkg/client/fake" diff --git a/hypershift-operator/controllers/scheduler/dedicated_request_serving_nodes.go b/hypershift-operator/controllers/scheduler/dedicated_request_serving_nodes.go index c24e75a449..90dc86ca07 100644 --- a/hypershift-operator/controllers/scheduler/dedicated_request_serving_nodes.go +++ b/hypershift-operator/controllers/scheduler/dedicated_request_serving_nodes.go @@ -5,7 +5,7 @@ import ( "fmt" "time" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/upsert" corev1 "k8s.io/api/core/v1" apierrors "k8s.io/apimachinery/pkg/api/errors" diff --git a/hypershift-operator/controllers/scheduler/dedicated_request_serving_nodes_test.go b/hypershift-operator/controllers/scheduler/dedicated_request_serving_nodes_test.go index 6ede6798bf..a2d52240bd 100644 --- a/hypershift-operator/controllers/scheduler/dedicated_request_serving_nodes_test.go +++ b/hypershift-operator/controllers/scheduler/dedicated_request_serving_nodes_test.go @@ -6,7 +6,7 @@ import ( "testing" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hyperapi "github.com/openshift/hypershift/support/api" corev1 "k8s.io/api/core/v1" apierrors "k8s.io/apimachinery/pkg/api/errors" diff --git a/hypershift-operator/conversion/conversion.go b/hypershift-operator/conversion/conversion.go index 3539074f15..aa376c6f25 100644 --- a/hypershift-operator/conversion/conversion.go +++ b/hypershift-operator/conversion/conversion.go @@ -6,8 +6,8 @@ import ( "strings" configv1 "github.com/openshift/api/config/v1" - hyperv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" - hyperv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" + hyperv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/api/util/configrefs" "github.com/openshift/hypershift/api/util/ipnet" corev1 "k8s.io/api/core/v1" diff --git a/hypershift-operator/conversion/conversion_test.go b/hypershift-operator/conversion/conversion_test.go index f9dac2287e..a39eeca917 100644 --- a/hypershift-operator/conversion/conversion_test.go +++ b/hypershift-operator/conversion/conversion_test.go @@ -12,8 +12,8 @@ import ( "github.com/google/go-cmp/cmp" fuzz "github.com/google/gofuzz" configv1 "github.com/openshift/api/config/v1" - hyperv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" - hyperv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" + hyperv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/api/util/configrefs" "github.com/openshift/hypershift/api/util/ipnet" diff --git a/hypershift-operator/conversion/handler.go b/hypershift-operator/conversion/handler.go index e012db6fd1..98256f8071 100644 --- a/hypershift-operator/conversion/handler.go +++ b/hypershift-operator/conversion/handler.go @@ -28,8 +28,8 @@ import ( "fmt" "net/http" - hyperv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" - hyperv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" + hyperv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" apix "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1" "k8s.io/apimachinery/pkg/api/meta" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/hypershift-operator/main.go b/hypershift-operator/main.go index 7eb19dcb93..21f34e121f 100644 --- a/hypershift-operator/main.go +++ b/hypershift-operator/main.go @@ -34,7 +34,7 @@ import ( "github.com/aws/aws-sdk-go/service/s3" "github.com/go-logr/logr" operatorv1 "github.com/openshift/api/operator/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" awsutil "github.com/openshift/hypershift/cmd/infra/aws/util" "github.com/openshift/hypershift/hypershift-operator/controllers/hostedcluster" hcmetrics "github.com/openshift/hypershift/hypershift-operator/controllers/hostedcluster/metrics" diff --git a/ignition-server/cmd/start.go b/ignition-server/cmd/start.go index 951df92b76..e14a36abc5 100644 --- a/ignition-server/cmd/start.go +++ b/ignition-server/cmd/start.go @@ -13,7 +13,7 @@ import ( "syscall" "time" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/nodepool" "github.com/openshift/hypershift/ignition-server/controllers" "github.com/openshift/hypershift/pkg/version" diff --git a/ignition-server/controllers/local_ignitionprovider.go b/ignition-server/controllers/local_ignitionprovider.go index 872d3ed0dc..e99087682e 100644 --- a/ignition-server/controllers/local_ignitionprovider.go +++ b/ignition-server/controllers/local_ignitionprovider.go @@ -16,7 +16,7 @@ import ( "time" "github.com/blang/semver" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/common" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/imageprovider" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" diff --git a/ignition-server/controllers/machineconfigserver_ignitionprovider.go b/ignition-server/controllers/machineconfigserver_ignitionprovider.go index 2f57f4c7c1..70f1cf6eb0 100644 --- a/ignition-server/controllers/machineconfigserver_ignitionprovider.go +++ b/ignition-server/controllers/machineconfigserver_ignitionprovider.go @@ -12,7 +12,7 @@ import ( "text/template" "time" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/support/releaseinfo" "github.com/openshift/hypershift/support/util" diff --git a/ignition-server/controllers/tokensecret_controller.go b/ignition-server/controllers/tokensecret_controller.go index b608c60d83..08acc73305 100644 --- a/ignition-server/controllers/tokensecret_controller.go +++ b/ignition-server/controllers/tokensecret_controller.go @@ -10,7 +10,7 @@ import ( "github.com/go-logr/logr" "github.com/google/uuid" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/util" "github.com/prometheus/client_golang/prometheus" corev1 "k8s.io/api/core/v1" diff --git a/ignition-server/controllers/tokensecret_controller_test.go b/ignition-server/controllers/tokensecret_controller_test.go index b12cf2d14d..310d3c2b2f 100644 --- a/ignition-server/controllers/tokensecret_controller_test.go +++ b/ignition-server/controllers/tokensecret_controller_test.go @@ -8,7 +8,7 @@ import ( "github.com/go-logr/logr" "github.com/google/uuid" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/util" corev1 "k8s.io/api/core/v1" apierrors "k8s.io/apimachinery/pkg/api/errors" diff --git a/kubevirtexternalinfra/externalinfra.go b/kubevirtexternalinfra/externalinfra.go index 71c67f971a..489799895a 100644 --- a/kubevirtexternalinfra/externalinfra.go +++ b/kubevirtexternalinfra/externalinfra.go @@ -18,7 +18,7 @@ import ( cr "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) type KubevirtInfraClientMap interface { diff --git a/product-cli/cmd/cluster/aws/create.go b/product-cli/cmd/cluster/aws/create.go index 35fb719cb2..d9f1f9bc59 100644 --- a/product-cli/cmd/cluster/aws/create.go +++ b/product-cli/cmd/cluster/aws/create.go @@ -5,7 +5,7 @@ import ( "github.com/spf13/cobra" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hypershiftaws "github.com/openshift/hypershift/cmd/cluster/aws" "github.com/openshift/hypershift/cmd/cluster/core" ) diff --git a/product-cli/cmd/cluster/cluster.go b/product-cli/cmd/cluster/cluster.go index 79ffa86cc0..6fe7a3f8dd 100644 --- a/product-cli/cmd/cluster/cluster.go +++ b/product-cli/cmd/cluster/cluster.go @@ -5,7 +5,7 @@ import ( "github.com/spf13/cobra" - "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" "github.com/openshift/hypershift/cmd/log" "github.com/openshift/hypershift/product-cli/cmd/cluster/agent" diff --git a/support/api/scheme.go b/support/api/scheme.go index b906d04ecd..397b5316ac 100644 --- a/support/api/scheme.go +++ b/support/api/scheme.go @@ -14,8 +14,8 @@ import ( routev1 "github.com/openshift/api/route/v1" securityv1 "github.com/openshift/api/security/v1" agentv1 "github.com/openshift/cluster-api-provider-agent/api/v1beta1" - hyperv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" - hyperv1beta1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" + hyperv1beta1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/rhobsmonitoring" mcfgv1 "github.com/openshift/hypershift/thirdparty/machineconfigoperator/pkg/apis/machineconfiguration.openshift.io/v1" prometheusoperatorv1 "github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring/v1" diff --git a/support/capabilities/management_cluster_capabilities_test.go b/support/capabilities/management_cluster_capabilities_test.go index 56a5096093..7659bf144f 100644 --- a/support/capabilities/management_cluster_capabilities_test.go +++ b/support/capabilities/management_cluster_capabilities_test.go @@ -7,7 +7,7 @@ import ( configv1 "github.com/openshift/api/config/v1" routev1 "github.com/openshift/api/route/v1" securityv1 "github.com/openshift/api/security/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" diff --git a/support/conditions/conditions.go b/support/conditions/conditions.go index 519a41e099..f4bc381f44 100644 --- a/support/conditions/conditions.go +++ b/support/conditions/conditions.go @@ -1,7 +1,7 @@ package conditions import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) diff --git a/support/config/deployment.go b/support/config/deployment.go index e81963deb8..09ef469f5d 100644 --- a/support/config/deployment.go +++ b/support/config/deployment.go @@ -3,7 +3,7 @@ package config import ( "strings" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/util" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" diff --git a/support/config/deployment_test.go b/support/config/deployment_test.go index 95672a4979..cabb219a81 100644 --- a/support/config/deployment_test.go +++ b/support/config/deployment_test.go @@ -6,7 +6,7 @@ import ( "testing" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/api/resource" diff --git a/support/config/ownerref.go b/support/config/ownerref.go index 4acf0feba3..aa5391e102 100644 --- a/support/config/ownerref.go +++ b/support/config/ownerref.go @@ -6,8 +6,8 @@ import ( "sigs.k8s.io/controller-runtime/pkg/client/apiutil" "github.com/blang/semver" - hyperv1alpha1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1alpha1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/api" "github.com/openshift/hypershift/support/util" ) diff --git a/support/config/ownerref_test.go b/support/config/ownerref_test.go index 2a91b84bcc..a3c3c90923 100644 --- a/support/config/ownerref_test.go +++ b/support/config/ownerref_test.go @@ -4,7 +4,7 @@ import ( "testing" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/blang/semver" ) diff --git a/support/globalconfig/authentication.go b/support/globalconfig/authentication.go index 9179b03ca7..dd1fa4169f 100644 --- a/support/globalconfig/authentication.go +++ b/support/globalconfig/authentication.go @@ -4,7 +4,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func AuthenticationConfiguration() *configv1.Authentication { diff --git a/support/globalconfig/dns.go b/support/globalconfig/dns.go index 33da13a1a1..bc304f8682 100644 --- a/support/globalconfig/dns.go +++ b/support/globalconfig/dns.go @@ -6,7 +6,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func DNSConfig() *configv1.DNS { diff --git a/support/globalconfig/dns_test.go b/support/globalconfig/dns_test.go index 2ad5d05f98..b4e34672f2 100644 --- a/support/globalconfig/dns_test.go +++ b/support/globalconfig/dns_test.go @@ -6,7 +6,7 @@ import ( . "github.com/onsi/gomega" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) diff --git a/support/globalconfig/imagecontentsource.go b/support/globalconfig/imagecontentsource.go index 313cac1280..2746a672c6 100644 --- a/support/globalconfig/imagecontentsource.go +++ b/support/globalconfig/imagecontentsource.go @@ -6,7 +6,7 @@ import ( configv1 "github.com/openshift/api/config/v1" operatorv1alpha1 "github.com/openshift/api/operator/v1alpha1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ctrl "sigs.k8s.io/controller-runtime" diff --git a/support/globalconfig/infrastructure.go b/support/globalconfig/infrastructure.go index 3a5c74e4cc..fe9ac8def0 100644 --- a/support/globalconfig/infrastructure.go +++ b/support/globalconfig/infrastructure.go @@ -9,7 +9,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func InfrastructureConfig() *configv1.Infrastructure { diff --git a/support/globalconfig/ingress.go b/support/globalconfig/ingress.go index bb565fe518..07dd40d965 100644 --- a/support/globalconfig/ingress.go +++ b/support/globalconfig/ingress.go @@ -6,7 +6,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func IngressConfig() *configv1.Ingress { diff --git a/support/globalconfig/installconfig.go b/support/globalconfig/installconfig.go index 92e3fdde7e..dcd9832a9f 100644 --- a/support/globalconfig/installconfig.go +++ b/support/globalconfig/installconfig.go @@ -5,7 +5,7 @@ import ( "fmt" "text/template" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/util" ) diff --git a/support/globalconfig/network.go b/support/globalconfig/network.go index e7a60eec6e..5c034f228a 100644 --- a/support/globalconfig/network.go +++ b/support/globalconfig/network.go @@ -6,7 +6,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/util" ) diff --git a/support/globalconfig/proxy.go b/support/globalconfig/proxy.go index 386d8a16ad..d76469f38f 100644 --- a/support/globalconfig/proxy.go +++ b/support/globalconfig/proxy.go @@ -5,7 +5,7 @@ import ( "strings" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/util/sets" ) diff --git a/support/releaseinfo/fake/fake.go b/support/releaseinfo/fake/fake.go index 49004b84e8..a60d42ac8c 100644 --- a/support/releaseinfo/fake/fake.go +++ b/support/releaseinfo/fake/fake.go @@ -9,7 +9,7 @@ import ( corev1 "k8s.io/api/core/v1" imagev1 "github.com/openshift/api/image/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/releaseinfo" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/types" diff --git a/support/supportedversion/version.go b/support/supportedversion/version.go index bab8a8ba10..bf36a51455 100644 --- a/support/supportedversion/version.go +++ b/support/supportedversion/version.go @@ -9,7 +9,7 @@ import ( "strings" "github.com/blang/semver" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // LatestSupportedVersion is the latest minor OCP version supported by the diff --git a/support/supportedversion/version_test.go b/support/supportedversion/version_test.go index b1c05403d0..b2e0650f34 100644 --- a/support/supportedversion/version_test.go +++ b/support/supportedversion/version_test.go @@ -7,7 +7,7 @@ import ( "github.com/blang/semver" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func TestSupportedVersions(t *testing.T) { diff --git a/support/upsert/loopdetector.go b/support/upsert/loopdetector.go index 512905c37d..a767fa3476 100644 --- a/support/upsert/loopdetector.go +++ b/support/upsert/loopdetector.go @@ -9,7 +9,7 @@ import ( "github.com/go-logr/logr" "github.com/google/go-cmp/cmp" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "k8s.io/apimachinery/pkg/api/equality" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/util/sets" diff --git a/support/util/deployment.go b/support/util/deployment.go index 76ce6d861b..2b3bb571f5 100644 --- a/support/util/deployment.go +++ b/support/util/deployment.go @@ -5,7 +5,7 @@ import ( "fmt" "path" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" diff --git a/support/util/expose.go b/support/util/expose.go index c891434d80..c453ef4331 100644 --- a/support/util/expose.go +++ b/support/util/expose.go @@ -1,7 +1,7 @@ package util import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func ServicePublishingStrategyByTypeForHCP(hcp *hyperv1.HostedControlPlane, svcType hyperv1.ServiceType) *hyperv1.ServicePublishingStrategy { diff --git a/support/util/imagemetadata.go b/support/util/imagemetadata.go index 623613e246..cc0a30a3da 100644 --- a/support/util/imagemetadata.go +++ b/support/util/imagemetadata.go @@ -12,7 +12,7 @@ import ( "github.com/golang/groupcache/lru" "k8s.io/client-go/rest" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/releaseinfo" "github.com/openshift/hypershift/support/thirdparty/library-go/pkg/image/dockerv1client" "github.com/openshift/hypershift/support/thirdparty/library-go/pkg/image/reference" diff --git a/support/util/networking.go b/support/util/networking.go index 23c96164d5..7822f36fa0 100644 --- a/support/util/networking.go +++ b/support/util/networking.go @@ -1,7 +1,7 @@ package util import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func MachineCIDRs(machineNetwork []hyperv1.MachineNetworkEntry) []string { diff --git a/support/util/networking_test.go b/support/util/networking_test.go index 42e5bc52f3..1699f64d83 100644 --- a/support/util/networking_test.go +++ b/support/util/networking_test.go @@ -4,7 +4,7 @@ import ( "reflect" "testing" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/api/util/ipnet" "k8s.io/utils/pointer" ) diff --git a/support/util/oauth.go b/support/util/oauth.go index bbba365f42..0dd7f79cff 100644 --- a/support/util/oauth.go +++ b/support/util/oauth.go @@ -2,7 +2,7 @@ package util import ( configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func HCPOAuthEnabled(hcp *hyperv1.HostedControlPlane) bool { diff --git a/support/util/pausereconcile.go b/support/util/pausereconcile.go index 1151e57e27..5f33ed67b0 100644 --- a/support/util/pausereconcile.go +++ b/support/util/pausereconcile.go @@ -6,7 +6,7 @@ import ( "time" "github.com/go-logr/logr" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) diff --git a/support/util/pausereconcile_test.go b/support/util/pausereconcile_test.go index 6946894647..b0e6db518d 100644 --- a/support/util/pausereconcile_test.go +++ b/support/util/pausereconcile_test.go @@ -5,7 +5,7 @@ import ( "testing" "time" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/utils/pointer" diff --git a/support/util/public.go b/support/util/public.go index 12fced77a1..06a7bbd55e 100644 --- a/support/util/public.go +++ b/support/util/public.go @@ -1,7 +1,7 @@ package util import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) // HasPrivateAPIServerConnectivity determines if workloads running inside the guest cluster can access diff --git a/support/util/public_test.go b/support/util/public_test.go index f046eca998..b82b374681 100644 --- a/support/util/public_test.go +++ b/support/util/public_test.go @@ -3,7 +3,7 @@ package util import ( "testing" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func TestConnectsThroughInternetToControlplane(t *testing.T) { diff --git a/support/util/route.go b/support/util/route.go index a6a48806e7..63c55d5795 100644 --- a/support/util/route.go +++ b/support/util/route.go @@ -8,7 +8,7 @@ import ( routev1 "github.com/openshift/api/route/v1" crclient "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1alpha1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1alpha1" "k8s.io/apimachinery/pkg/util/validation" ) diff --git a/support/util/util.go b/support/util/util.go index ef91979f4b..fc079a2275 100644 --- a/support/util/util.go +++ b/support/util/util.go @@ -15,7 +15,7 @@ import ( "strings" "time" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" corev1 "k8s.io/api/core/v1" apierrors "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/types" diff --git a/support/util/visibility.go b/support/util/visibility.go index 6b63754737..c34d9bd540 100644 --- a/support/util/visibility.go +++ b/support/util/visibility.go @@ -1,7 +1,7 @@ package util import ( - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func IsPrivateHCP(hcp *hyperv1.HostedControlPlane) bool { diff --git a/support/util/visibility_test.go b/support/util/visibility_test.go index 9cc5a0dfe3..9dfb447ba4 100644 --- a/support/util/visibility_test.go +++ b/support/util/visibility_test.go @@ -3,7 +3,7 @@ package util import ( "testing" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" ) func TestIsPrivateHCP(t *testing.T) { diff --git a/test/e2e/autoscaling_test.go b/test/e2e/autoscaling_test.go index 07c7b55ee7..f639e3dcc5 100644 --- a/test/e2e/autoscaling_test.go +++ b/test/e2e/autoscaling_test.go @@ -9,7 +9,7 @@ import ( "testing" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" e2eutil "github.com/openshift/hypershift/test/e2e/util" batchv1 "k8s.io/api/batch/v1" corev1 "k8s.io/api/core/v1" diff --git a/test/e2e/chaos_test.go b/test/e2e/chaos_test.go index 6a0bf27417..af757929e8 100644 --- a/test/e2e/chaos_test.go +++ b/test/e2e/chaos_test.go @@ -18,7 +18,7 @@ import ( "k8s.io/apimachinery/pkg/util/wait" "k8s.io/utils/pointer" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" e2eutil "github.com/openshift/hypershift/test/e2e/util" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/test/e2e/control_plane_upgrade_test.go b/test/e2e/control_plane_upgrade_test.go index 2d775f4ab9..913f44b1f9 100644 --- a/test/e2e/control_plane_upgrade_test.go +++ b/test/e2e/control_plane_upgrade_test.go @@ -8,7 +8,7 @@ import ( "testing" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" e2eutil "github.com/openshift/hypershift/test/e2e/util" crclient "sigs.k8s.io/controller-runtime/pkg/client" ) diff --git a/test/e2e/create_cluster_test.go b/test/e2e/create_cluster_test.go index 80a3eec756..fb55e768ec 100644 --- a/test/e2e/create_cluster_test.go +++ b/test/e2e/create_cluster_test.go @@ -10,7 +10,7 @@ import ( "testing" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" e2eutil "github.com/openshift/hypershift/test/e2e/util" diff --git a/test/e2e/e2e_test.go b/test/e2e/e2e_test.go index 3a7b55b2d6..d3d580c2a8 100644 --- a/test/e2e/e2e_test.go +++ b/test/e2e/e2e_test.go @@ -23,7 +23,7 @@ import ( "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/service/s3" "github.com/go-logr/logr" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" "github.com/openshift/hypershift/cmd/cluster/kubevirt" awsinfra "github.com/openshift/hypershift/cmd/infra/aws" diff --git a/test/e2e/nodepool_autorepair_test.go b/test/e2e/nodepool_autorepair_test.go index c7a812162d..e6897a6f84 100644 --- a/test/e2e/nodepool_autorepair_test.go +++ b/test/e2e/nodepool_autorepair_test.go @@ -12,7 +12,7 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/service/ec2" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" awsutil "github.com/openshift/hypershift/cmd/infra/aws/util" e2eutil "github.com/openshift/hypershift/test/e2e/util" diff --git a/test/e2e/nodepool_kms_root_volume_test.go b/test/e2e/nodepool_kms_root_volume_test.go index d25d93a55b..5a5e23050d 100644 --- a/test/e2e/nodepool_kms_root_volume_test.go +++ b/test/e2e/nodepool_kms_root_volume_test.go @@ -9,7 +9,7 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/service/ec2" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" e2eutil "github.com/openshift/hypershift/test/e2e/util" corev1 "k8s.io/api/core/v1" diff --git a/test/e2e/nodepool_kv_cache_image_test.go b/test/e2e/nodepool_kv_cache_image_test.go index 212dd17fb6..ca0dddcdef 100644 --- a/test/e2e/nodepool_kv_cache_image_test.go +++ b/test/e2e/nodepool_kv_cache_image_test.go @@ -17,7 +17,7 @@ import ( "sigs.k8s.io/cluster-api/util" crclient "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" kvinfra "github.com/openshift/hypershift/kubevirtexternalinfra" ) diff --git a/test/e2e/nodepool_kv_jsonpatch_test.go b/test/e2e/nodepool_kv_jsonpatch_test.go index 970070ef0d..8d12b67e6d 100644 --- a/test/e2e/nodepool_kv_jsonpatch_test.go +++ b/test/e2e/nodepool_kv_jsonpatch_test.go @@ -17,7 +17,7 @@ import ( "sigs.k8s.io/cluster-api/util" crclient "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" kvinfra "github.com/openshift/hypershift/kubevirtexternalinfra" ) diff --git a/test/e2e/nodepool_kv_multinet_test.go b/test/e2e/nodepool_kv_multinet_test.go index 8b37d6b473..a6cd3b9bd3 100644 --- a/test/e2e/nodepool_kv_multinet_test.go +++ b/test/e2e/nodepool_kv_multinet_test.go @@ -20,7 +20,7 @@ import ( crclient "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/yaml" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" kvinfra "github.com/openshift/hypershift/kubevirtexternalinfra" ) diff --git a/test/e2e/nodepool_kv_nodeselector_test.go b/test/e2e/nodepool_kv_nodeselector_test.go index 5e04c96b3f..48bd594d20 100644 --- a/test/e2e/nodepool_kv_nodeselector_test.go +++ b/test/e2e/nodepool_kv_nodeselector_test.go @@ -18,7 +18,7 @@ import ( kubevirtv1 "kubevirt.io/api/core/v1" crclient "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" kvinfra "github.com/openshift/hypershift/kubevirtexternalinfra" ) diff --git a/test/e2e/nodepool_kv_qos_guaranteed_test.go b/test/e2e/nodepool_kv_qos_guaranteed_test.go index d337a07afa..96aebd1b11 100644 --- a/test/e2e/nodepool_kv_qos_guaranteed_test.go +++ b/test/e2e/nodepool_kv_qos_guaranteed_test.go @@ -18,7 +18,7 @@ import ( "sigs.k8s.io/cluster-api/util" crclient "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" kvinfra "github.com/openshift/hypershift/kubevirtexternalinfra" ) diff --git a/test/e2e/nodepool_machineconfig_test.go b/test/e2e/nodepool_machineconfig_test.go index f85cae9b1f..6f00760c87 100644 --- a/test/e2e/nodepool_machineconfig_test.go +++ b/test/e2e/nodepool_machineconfig_test.go @@ -14,7 +14,7 @@ import ( . "github.com/onsi/gomega" ignitionapi "github.com/coreos/ignition/v2/config/v3_2/types" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" hyperapi "github.com/openshift/hypershift/support/api" e2eutil "github.com/openshift/hypershift/test/e2e/util" diff --git a/test/e2e/nodepool_nto_machineconfig_test.go b/test/e2e/nodepool_nto_machineconfig_test.go index 197b32ef9a..03d72cf939 100644 --- a/test/e2e/nodepool_nto_machineconfig_test.go +++ b/test/e2e/nodepool_nto_machineconfig_test.go @@ -12,7 +12,7 @@ import ( . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" e2eutil "github.com/openshift/hypershift/test/e2e/util" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" diff --git a/test/e2e/nodepool_rolling_upgrade_test.go b/test/e2e/nodepool_rolling_upgrade_test.go index dc638a6908..402dd98895 100644 --- a/test/e2e/nodepool_rolling_upgrade_test.go +++ b/test/e2e/nodepool_rolling_upgrade_test.go @@ -9,7 +9,7 @@ import ( "time" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" npcontroller "github.com/openshift/hypershift/hypershift-operator/controllers/nodepool" e2eutil "github.com/openshift/hypershift/test/e2e/util" diff --git a/test/e2e/nodepool_test.go b/test/e2e/nodepool_test.go index b1222e62b3..8fc50e6cf8 100644 --- a/test/e2e/nodepool_test.go +++ b/test/e2e/nodepool_test.go @@ -9,7 +9,7 @@ import ( "testing" "time" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/support/conditions" e2eutil "github.com/openshift/hypershift/test/e2e/util" corev1 "k8s.io/api/core/v1" diff --git a/test/e2e/nodepool_upgrade_test.go b/test/e2e/nodepool_upgrade_test.go index d11fb4e06d..fc2ceb5dab 100644 --- a/test/e2e/nodepool_upgrade_test.go +++ b/test/e2e/nodepool_upgrade_test.go @@ -11,7 +11,7 @@ import ( "testing" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" "github.com/openshift/hypershift/support/releaseinfo" e2eutil "github.com/openshift/hypershift/test/e2e/util" diff --git a/test/e2e/olm_test.go b/test/e2e/olm_test.go index a418c8bdea..89c5ba0602 100644 --- a/test/e2e/olm_test.go +++ b/test/e2e/olm_test.go @@ -10,7 +10,7 @@ import ( "time" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" e2eutil "github.com/openshift/hypershift/test/e2e/util" operatorsv1 "github.com/operator-framework/api/pkg/operators/v1" diff --git a/test/e2e/util/dump/dump.go b/test/e2e/util/dump/dump.go index b77cbef165..b3892a72b7 100644 --- a/test/e2e/util/dump/dump.go +++ b/test/e2e/util/dump/dump.go @@ -8,7 +8,7 @@ import ( "testing" "github.com/go-logr/zapr" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" consolelogsaws "github.com/openshift/hypershift/cmd/consolelogs/aws" "github.com/openshift/hypershift/support/upsert" diff --git a/test/e2e/util/dump/journals.go b/test/e2e/util/dump/journals.go index de5255d659..7122d9e160 100644 --- a/test/e2e/util/dump/journals.go +++ b/test/e2e/util/dump/journals.go @@ -15,7 +15,7 @@ import ( corev1 "k8s.io/api/core/v1" "sigs.k8s.io/controller-runtime/pkg/client" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" bastionaws "github.com/openshift/hypershift/cmd/bastion/aws" awsutil "github.com/openshift/hypershift/cmd/infra/aws/util" cmdutil "github.com/openshift/hypershift/cmd/util" diff --git a/test/e2e/util/fixture.go b/test/e2e/util/fixture.go index 95c1e5ed2e..7e63edf430 100644 --- a/test/e2e/util/fixture.go +++ b/test/e2e/util/fixture.go @@ -11,7 +11,7 @@ import ( awssdk "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/aws-sdk-go/service/resourcegroupstaggingapi" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/aws" "github.com/openshift/hypershift/cmd/cluster/azure" "github.com/openshift/hypershift/cmd/cluster/core" diff --git a/test/e2e/util/hypershift_framework.go b/test/e2e/util/hypershift_framework.go index 4954bd8307..21da603c76 100644 --- a/test/e2e/util/hypershift_framework.go +++ b/test/e2e/util/hypershift_framework.go @@ -9,7 +9,7 @@ import ( "time" configv1 "github.com/openshift/api/config/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" hcmetrics "github.com/openshift/hypershift/hypershift-operator/controllers/hostedcluster/metrics" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" diff --git a/test/e2e/util/node.go b/test/e2e/util/node.go index 0082753562..e46865ad19 100644 --- a/test/e2e/util/node.go +++ b/test/e2e/util/node.go @@ -6,7 +6,7 @@ import ( "time" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/util/wait" diff --git a/test/e2e/util/oauth.go b/test/e2e/util/oauth.go index 4c9839e12a..a81437f780 100644 --- a/test/e2e/util/oauth.go +++ b/test/e2e/util/oauth.go @@ -12,7 +12,7 @@ import ( . "github.com/onsi/gomega" v1 "github.com/openshift/api/config/v1" routev1 "github.com/openshift/api/route/v1" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hcpmanifests "github.com/openshift/hypershift/control-plane-operator/controllers/hostedcontrolplane/manifests" "github.com/openshift/hypershift/control-plane-operator/hostedclusterconfigoperator/controllers/resources" configmanifests "github.com/openshift/hypershift/control-plane-operator/hostedclusterconfigoperator/controllers/resources/manifests" diff --git a/test/e2e/util/requestserving.go b/test/e2e/util/requestserving.go index 2b34684686..195295d2b7 100644 --- a/test/e2e/util/requestserving.go +++ b/test/e2e/util/requestserving.go @@ -9,7 +9,7 @@ import ( "github.com/openshift/hypershift/hypershift-operator/controllers/scheduler" . "github.com/onsi/gomega" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" hyperapi "github.com/openshift/hypershift/support/api" supportutil "github.com/openshift/hypershift/support/util" corev1 "k8s.io/api/core/v1" diff --git a/test/e2e/util/util.go b/test/e2e/util/util.go index ba415bc06f..47fc1a36e0 100644 --- a/test/e2e/util/util.go +++ b/test/e2e/util/util.go @@ -16,7 +16,7 @@ import ( configv1 "github.com/openshift/api/config/v1" routev1 "github.com/openshift/api/route/v1" routev1client "github.com/openshift/client-go/route/clientset/versioned" - hyperv1 "github.com/openshift/hypershift/api/types/hypershift/v1beta1" + hyperv1 "github.com/openshift/hypershift/api/hypershift/v1beta1" "github.com/openshift/hypershift/cmd/cluster/core" hcmetrics "github.com/openshift/hypershift/hypershift-operator/controllers/hostedcluster/metrics" "github.com/openshift/hypershift/hypershift-operator/controllers/manifests" diff --git a/vendor/github.com/openshift/hypershift/api/types/certificates/register.go b/vendor/github.com/openshift/hypershift/api/certificates/register.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/certificates/register.go rename to vendor/github.com/openshift/hypershift/api/certificates/register.go diff --git a/vendor/github.com/openshift/hypershift/api/certificates/v1alpha1/certificaterevocationrequest_types.go b/vendor/github.com/openshift/hypershift/api/certificates/v1alpha1/certificaterevocationrequest_types.go new file mode 100644 index 0000000000..5a235198f6 --- /dev/null +++ b/vendor/github.com/openshift/hypershift/api/certificates/v1alpha1/certificaterevocationrequest_types.go @@ -0,0 +1,82 @@ +package v1alpha1 + +import ( + corev1 "k8s.io/api/core/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// +genclient +// +kubebuilder:resource:path=certificaterevocationrequests,shortName=crr;crrs,scope=Namespaced +// +kubebuilder:object:root=true +// +kubebuilder:subresource:status +// +kubebuilder:storageversion + +// CertificateRevocationRequest defines the desired state of CertificateRevocationRequest. +// A request denotes the user's desire to revoke a signer certificate of the class indicated in spec. +type CertificateRevocationRequest struct { + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty"` + + Spec CertificateRevocationRequestSpec `json:"spec,omitempty"` + Status CertificateRevocationRequestStatus `json:"status,omitempty"` +} + +// CertificateRevocationRequestSpec defines the desired state of CertificateRevocationRequest +type CertificateRevocationRequestSpec struct { + // +kubebuilder:validation:Required + // +kubebuilder:validation:Enum=customer-break-glass + // +kubebuilder:validation:XValidation:rule="self == oldSelf", message="signerClass is immutable" + + // SignerClass identifies the class of signer to revoke. All the active signing CAs for the + // signer class will be revoked. + SignerClass string `json:"signerClass"` +} + +const ( + SignerClassValidType string = "SignerClassValid" + SignerClassUnknownReason string = "SignerClassUnknown" + + RootCertificatesRegeneratedType string = "RootCertificatesRegenerated" + RootCertificatesStaleReason string = "RootCertificatesStale" + + LeafCertificatesRegeneratedType string = "LeafCertificatesRegenerated" + LeafCertificatesStaleReason string = "LeafCertificatesStale" + + NewCertificatesTrustedType = "NewCertificatesTrusted" + PreviousCertificatesRevokedType = "PreviousCertificatesRevoked" +) + +// CertificateRevocationRequestStatus defines the observed state of CertificateRevocationRequest +type CertificateRevocationRequestStatus struct { + // +optional + + // RevocationTimestamp is the cut-off time for signing CAs to be revoked. All certificates that + // are valid before this time will be revoked; all re-generated certificates will not be valid + // at or before this time. + RevocationTimestamp *metav1.Time `json:"revocationTimestamp,omitempty"` + + // +optional + + // PreviousSigner stores a reference to the previous signer certificate. We require + // storing this data to ensure that we can validate that the old signer is no longer + // valid before considering revocation complete. + PreviousSigner *corev1.LocalObjectReference `json:"previousSigner,omitempty"` + + // +optional + // +listType=map + // +listMapKey=type + // +patchMergeKey=type + // +patchStrategy=merge + + // Conditions contain details about the various aspects of certificate revocation. + Conditions []metav1.Condition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type"` +} + +// +kubebuilder:object:root=true + +// CertificateRevocationRequestList contains a list of CertificateRevocationRequest. +type CertificateRevocationRequestList struct { + metav1.TypeMeta `json:",inline"` + metav1.ListMeta `json:"metadata,omitempty"` + Items []CertificateRevocationRequest `json:"items"` +} diff --git a/vendor/github.com/openshift/hypershift/api/types/certificates/v1alpha1/certificatesigningrequestapproval_types.go b/vendor/github.com/openshift/hypershift/api/certificates/v1alpha1/certificatesigningrequestapproval_types.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/certificates/v1alpha1/certificatesigningrequestapproval_types.go rename to vendor/github.com/openshift/hypershift/api/certificates/v1alpha1/certificatesigningrequestapproval_types.go diff --git a/vendor/github.com/openshift/hypershift/api/types/certificates/v1alpha1/doc.go b/vendor/github.com/openshift/hypershift/api/certificates/v1alpha1/doc.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/certificates/v1alpha1/doc.go rename to vendor/github.com/openshift/hypershift/api/certificates/v1alpha1/doc.go diff --git a/api/types/certificates/v1alpha1/register.go b/vendor/github.com/openshift/hypershift/api/certificates/v1alpha1/register.go similarity index 89% rename from api/types/certificates/v1alpha1/register.go rename to vendor/github.com/openshift/hypershift/api/certificates/v1alpha1/register.go index a6df1c76ea..558235401e 100644 --- a/api/types/certificates/v1alpha1/register.go +++ b/vendor/github.com/openshift/hypershift/api/certificates/v1alpha1/register.go @@ -5,7 +5,7 @@ import ( "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" - "github.com/openshift/hypershift/api/types/certificates" + "github.com/openshift/hypershift/api/certificates" ) // SchemeGroupVersion is group version used to register these objects. @@ -31,6 +31,9 @@ func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, &CertificateSigningRequestApproval{}, &CertificateSigningRequestApprovalList{}, + + &CertificateRevocationRequest{}, + &CertificateRevocationRequestList{}, ) metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil diff --git a/api/types/certificates/v1alpha1/zz_generated.deepcopy.go b/vendor/github.com/openshift/hypershift/api/certificates/v1alpha1/zz_generated.deepcopy.go similarity index 51% rename from api/types/certificates/v1alpha1/zz_generated.deepcopy.go rename to vendor/github.com/openshift/hypershift/api/certificates/v1alpha1/zz_generated.deepcopy.go index aac2d488f7..1d15b173f6 100644 --- a/api/types/certificates/v1alpha1/zz_generated.deepcopy.go +++ b/vendor/github.com/openshift/hypershift/api/certificates/v1alpha1/zz_generated.deepcopy.go @@ -21,9 +21,116 @@ limitations under the License. package v1alpha1 import ( + "k8s.io/api/core/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" ) +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *CertificateRevocationRequest) DeepCopyInto(out *CertificateRevocationRequest) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + out.Spec = in.Spec + in.Status.DeepCopyInto(&out.Status) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CertificateRevocationRequest. +func (in *CertificateRevocationRequest) DeepCopy() *CertificateRevocationRequest { + if in == nil { + return nil + } + out := new(CertificateRevocationRequest) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *CertificateRevocationRequest) 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 *CertificateRevocationRequestList) DeepCopyInto(out *CertificateRevocationRequestList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]CertificateRevocationRequest, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CertificateRevocationRequestList. +func (in *CertificateRevocationRequestList) DeepCopy() *CertificateRevocationRequestList { + if in == nil { + return nil + } + out := new(CertificateRevocationRequestList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *CertificateRevocationRequestList) 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 *CertificateRevocationRequestSpec) DeepCopyInto(out *CertificateRevocationRequestSpec) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CertificateRevocationRequestSpec. +func (in *CertificateRevocationRequestSpec) DeepCopy() *CertificateRevocationRequestSpec { + if in == nil { + return nil + } + out := new(CertificateRevocationRequestSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *CertificateRevocationRequestStatus) DeepCopyInto(out *CertificateRevocationRequestStatus) { + *out = *in + if in.RevocationTimestamp != nil { + in, out := &in.RevocationTimestamp, &out.RevocationTimestamp + *out = (*in).DeepCopy() + } + if in.PreviousSigner != nil { + in, out := &in.PreviousSigner, &out.PreviousSigner + *out = new(v1.LocalObjectReference) + **out = **in + } + if in.Conditions != nil { + in, out := &in.Conditions, &out.Conditions + *out = make([]metav1.Condition, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CertificateRevocationRequestStatus. +func (in *CertificateRevocationRequestStatus) DeepCopy() *CertificateRevocationRequestStatus { + if in == nil { + return nil + } + out := new(CertificateRevocationRequestStatus) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *CertificateSigningRequestApproval) DeepCopyInto(out *CertificateSigningRequestApproval) { *out = *in diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/register.go b/vendor/github.com/openshift/hypershift/api/hypershift/register.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/register.go rename to vendor/github.com/openshift/hypershift/api/hypershift/register.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/clusterconfig.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/clusterconfig.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/clusterconfig.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/clusterconfig.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/conditions.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/conditions.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/conditions.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/conditions.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/doc.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/doc.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/doc.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/doc.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/endpointservice_types.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/endpointservice_types.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/endpointservice_types.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/endpointservice_types.go diff --git a/api/types/hypershift/v1alpha1/groupversion_info.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/groupversion_info.go similarity index 96% rename from api/types/hypershift/v1alpha1/groupversion_info.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/groupversion_info.go index 96343de32b..b63c943eaa 100644 --- a/api/types/hypershift/v1alpha1/groupversion_info.go +++ b/vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/groupversion_info.go @@ -4,7 +4,7 @@ package v1alpha1 import ( - "github.com/openshift/hypershift/api/types/hypershift" + "github.com/openshift/hypershift/api/hypershift" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" diff --git a/api/types/hypershift/v1alpha1/hosted_controlplane.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/hosted_controlplane.go similarity index 99% rename from api/types/hypershift/v1alpha1/hosted_controlplane.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/hosted_controlplane.go index 243dafdbb0..d337d999af 100644 --- a/api/types/hypershift/v1alpha1/hosted_controlplane.go +++ b/vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/hosted_controlplane.go @@ -125,6 +125,8 @@ type HostedControlPlaneSpec struct { // critical control plane components. The default value is SingleReplica. // // +optional + // +immutable + // +kubebuilder:validation:XValidation:rule="self == oldSelf",message="ControllerAvailabilityPolicy is immutable" // +kubebuilder:default:="SingleReplica" ControllerAvailabilityPolicy AvailabilityPolicy `json:"controllerAvailabilityPolicy,omitempty"` diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/hostedcluster_types.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/hostedcluster_types.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/hostedcluster_types.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/hostedcluster_types.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/nodepool_types.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/nodepool_types.go similarity index 99% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/nodepool_types.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/nodepool_types.go index 9f4100f6df..4cd22a1a79 100644 --- a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/nodepool_types.go +++ b/vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/nodepool_types.go @@ -9,7 +9,7 @@ import ( "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/util/intstr" - "github.com/openshift/hypershift/api/types/ibmcapi" + "github.com/openshift/hypershift/api/ibmcapi" ) const ( diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/zz_generated.deepcopy.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/zz_generated.deepcopy.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1alpha1/zz_generated.deepcopy.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1alpha1/zz_generated.deepcopy.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/certificatesigningrequestapproval_types.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/certificatesigningrequestapproval_types.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/certificatesigningrequestapproval_types.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/certificatesigningrequestapproval_types.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/clusterconfig.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/clusterconfig.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/clusterconfig.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/clusterconfig.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/doc.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/doc.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/doc.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/doc.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/endpointservice_types.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/endpointservice_types.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/endpointservice_types.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/endpointservice_types.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/groupversion_info.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/groupversion_info.go similarity index 96% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/groupversion_info.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/groupversion_info.go index 337ad40871..4fc32d35c6 100644 --- a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/groupversion_info.go +++ b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/groupversion_info.go @@ -4,7 +4,7 @@ package v1beta1 import ( - "github.com/openshift/hypershift/api/types/hypershift" + "github.com/openshift/hypershift/api/hypershift" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" diff --git a/api/types/hypershift/v1beta1/hosted_controlplane.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/hosted_controlplane.go similarity index 98% rename from api/types/hypershift/v1beta1/hosted_controlplane.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/hosted_controlplane.go index 2bbaf98e08..8308d0f082 100644 --- a/api/types/hypershift/v1beta1/hosted_controlplane.go +++ b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/hosted_controlplane.go @@ -86,6 +86,8 @@ type HostedControlPlaneSpec struct { // critical control plane components. The default value is SingleReplica. // // +optional + // +immutable + // +kubebuilder:validation:XValidation:rule="self == oldSelf",message="ControllerAvailabilityPolicy is immutable" // +kubebuilder:default:="SingleReplica" ControllerAvailabilityPolicy AvailabilityPolicy `json:"controllerAvailabilityPolicy,omitempty"` diff --git a/api/types/hypershift/v1beta1/hostedcluster_conditions.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/hostedcluster_conditions.go similarity index 99% rename from api/types/hypershift/v1beta1/hostedcluster_conditions.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/hostedcluster_conditions.go index b50d6d90f8..33d6f6f337 100644 --- a/api/types/hypershift/v1beta1/hostedcluster_conditions.go +++ b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/hostedcluster_conditions.go @@ -174,6 +174,7 @@ const ( WaitingForAvailableReason = "WaitingForAvailable" SecretNotFoundReason = "SecretNotFound" WaitingForGracePeriodReason = "WaitingForGracePeriod" + BlockedReason = "Blocked" InfraStatusFailureReason = "InfraStatusFailure" WaitingOnInfrastructureReadyReason = "WaitingOnInfrastructureReady" diff --git a/api/types/hypershift/v1beta1/hostedcluster_types.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/hostedcluster_types.go similarity index 99% rename from api/types/hypershift/v1beta1/hostedcluster_types.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/hostedcluster_types.go index b932ce3d64..4eb1f14261 100644 --- a/api/types/hypershift/v1beta1/hostedcluster_types.go +++ b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/hostedcluster_types.go @@ -49,9 +49,13 @@ const ( // KonnectivityAgentImageAnnotation is a temporary annotation that allows the specification of the konnectivity agent image. // This will be removed when Konnectivity is added to the Openshift release payload KonnectivityAgentImageAnnotation = "hypershift.openshift.io/konnectivity-agent-image" - // ControlPlaneOperatorImageAnnotation is a annotation that allows the specification of the control plane operator image. + // ControlPlaneOperatorImageAnnotation is an annotation that allows the specification of the control plane operator image. // This is used for development and e2e workflows ControlPlaneOperatorImageAnnotation = "hypershift.openshift.io/control-plane-operator-image" + // ControlPlaneOperatorImageLabelsAnnotation is an annotation that allows the specification of the control plane operator image labels. + // Labels are provided in a comma-delimited format: key=value,key2=value2 + // This is used for development and e2e workflows + ControlPlaneOperatorImageLabelsAnnotation = "hypershift.openshift.io/control-plane-operator-image-labels" // RestartDateAnnotation is a annotation that can be used to trigger a rolling restart of all components managed by hypershift. // it is important in some situations like CA rotation where components need to be fully restarted to pick up new CAs. It's also // important in some recovery situations where a fresh start of the component helps fix symptoms a user might be experiencing. diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/nodepool_conditions.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/nodepool_conditions.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/nodepool_conditions.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/nodepool_conditions.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/nodepool_types.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/nodepool_types.go similarity index 99% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/nodepool_types.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/nodepool_types.go index d80d1b93e0..1e4fc648e0 100644 --- a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/nodepool_types.go +++ b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/nodepool_types.go @@ -4,7 +4,7 @@ import ( "fmt" "strings" - "github.com/openshift/hypershift/api/types/ibmcapi" + "github.com/openshift/hypershift/api/ibmcapi" corev1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/api/resource" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/zz_generated.deepcopy.go b/vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/zz_generated.deepcopy.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/zz_generated.deepcopy.go rename to vendor/github.com/openshift/hypershift/api/hypershift/v1beta1/zz_generated.deepcopy.go diff --git a/vendor/github.com/openshift/hypershift/api/types/ibmcapi/types.go b/vendor/github.com/openshift/hypershift/api/ibmcapi/types.go similarity index 100% rename from vendor/github.com/openshift/hypershift/api/types/ibmcapi/types.go rename to vendor/github.com/openshift/hypershift/api/ibmcapi/types.go diff --git a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/conversion.go b/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/conversion.go deleted file mode 100644 index 01f3a38f98..0000000000 --- a/vendor/github.com/openshift/hypershift/api/types/hypershift/v1beta1/conversion.go +++ /dev/null @@ -1,7 +0,0 @@ -package v1beta1 - -// Declare the types in this version as the Hub -func (*HostedCluster) Hub() {} -func (*NodePool) Hub() {} -func (*AWSEndpointService) Hub() {} -func (*HostedControlPlane) Hub() {} diff --git a/vendor/modules.txt b/vendor/modules.txt index a6b225c37b..58cb479e5a 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -828,12 +828,12 @@ github.com/openshift/cluster-node-tuning-operator/pkg/apis/tuned/v1 github.com/openshift/custom-resource-status/conditions/v1 # github.com/openshift/hypershift/api v0.0.0-00010101000000-000000000000 => ./api ## explicit; go 1.21 -github.com/openshift/hypershift/api/types/certificates -github.com/openshift/hypershift/api/types/certificates/v1alpha1 -github.com/openshift/hypershift/api/types/hypershift -github.com/openshift/hypershift/api/types/hypershift/v1alpha1 -github.com/openshift/hypershift/api/types/hypershift/v1beta1 -github.com/openshift/hypershift/api/types/ibmcapi +github.com/openshift/hypershift/api/certificates +github.com/openshift/hypershift/api/certificates/v1alpha1 +github.com/openshift/hypershift/api/hypershift +github.com/openshift/hypershift/api/hypershift/v1alpha1 +github.com/openshift/hypershift/api/hypershift/v1beta1 +github.com/openshift/hypershift/api/ibmcapi github.com/openshift/hypershift/api/util/configrefs github.com/openshift/hypershift/api/util/ipnet # github.com/openshift/library-go v0.0.0-20231214171439-128164517bf7 @@ -2108,7 +2108,7 @@ sigs.k8s.io/apiserver-network-proxy/konnectivity-client/pkg/client sigs.k8s.io/apiserver-network-proxy/konnectivity-client/pkg/client/metrics sigs.k8s.io/apiserver-network-proxy/konnectivity-client/pkg/common/metrics sigs.k8s.io/apiserver-network-proxy/konnectivity-client/proto/client -# sigs.k8s.io/cluster-api v1.6.1 => sigs.k8s.io/cluster-api v1.5.3 +# sigs.k8s.io/cluster-api v1.6.1 ## explicit; go 1.20 sigs.k8s.io/cluster-api/api/v1beta1 sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3 @@ -2121,10 +2121,8 @@ sigs.k8s.io/cluster-api/util/annotations sigs.k8s.io/cluster-api/util/conditions sigs.k8s.io/cluster-api/util/contract sigs.k8s.io/cluster-api/util/conversion -sigs.k8s.io/cluster-api/util/labels/format sigs.k8s.io/cluster-api/util/patch sigs.k8s.io/cluster-api/util/topology -sigs.k8s.io/cluster-api/util/version # sigs.k8s.io/cluster-api-provider-aws/v2 v2.3.1 ## explicit; go 1.20 sigs.k8s.io/cluster-api-provider-aws/v2/api/v1beta1 @@ -2142,7 +2140,7 @@ sigs.k8s.io/cluster-api-provider-azure/feature sigs.k8s.io/cluster-api-provider-azure/util/azure sigs.k8s.io/cluster-api-provider-azure/util/ssh sigs.k8s.io/cluster-api-provider-azure/util/webhook -# sigs.k8s.io/cluster-api-provider-ibmcloud v0.7.0 => sigs.k8s.io/cluster-api-provider-ibmcloud v0.6.0 +# sigs.k8s.io/cluster-api-provider-ibmcloud v0.7.0 ## explicit; go 1.20 sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta1 sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2 @@ -2307,5 +2305,3 @@ sigs.k8s.io/yaml/goyaml.v2 # kubevirt.io/client-go => kubevirt.io/client-go v0.0.0-00010101000000-000000000000 # kubevirt.io/containerized-data-importer-api => github.com/kubevirt/containerized-data-importer-api v1.41.1-0.20211201033752-05520fb9f18d # sigs.k8s.io/apiserver-network-proxy/konnectivity-client => sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.28.1 -# sigs.k8s.io/cluster-api => sigs.k8s.io/cluster-api v1.5.3 -# sigs.k8s.io/cluster-api-provider-ibmcloud => sigs.k8s.io/cluster-api-provider-ibmcloud v0.6.0 diff --git a/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta1/types.go b/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta1/types.go index ae55fb1156..cfb61aae4f 100644 --- a/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta1/types.go +++ b/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta1/types.go @@ -93,6 +93,7 @@ type Subnet struct { type VPCEndpoint struct { Address *string `json:"address"` // +optional + // Deprecated: This field has no function and is going to be removed in the next release. FIPID *string `json:"floatingIPID,omitempty"` // +optional LBID *string `json:"loadBalancerIPID,omitempty"` diff --git a/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta1/zz_generated.deepcopy.go b/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta1/zz_generated.deepcopy.go index 952d2c8c3f..1a595196ec 100644 --- a/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta1/zz_generated.deepcopy.go +++ b/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright The Kubernetes Authors. diff --git a/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/ibmvpccluster_webhook.go b/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/ibmvpccluster_webhook.go index f53ca9ee15..9c7d29b422 100644 --- a/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/ibmvpccluster_webhook.go +++ b/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/ibmvpccluster_webhook.go @@ -17,7 +17,10 @@ limitations under the License. package v1beta2 import ( + apierrors "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/util/validation/field" ctrl "sigs.k8s.io/controller-runtime" logf "sigs.k8s.io/controller-runtime/pkg/log" @@ -51,13 +54,13 @@ var _ webhook.Validator = &IBMVPCCluster{} // ValidateCreate implements webhook.Validator so a webhook will be registered for the type. func (r *IBMVPCCluster) ValidateCreate() (admission.Warnings, error) { ibmvpcclusterlog.Info("validate create", "name", r.Name) - return nil, nil + return r.validateIBMVPCCluster() } // ValidateUpdate implements webhook.Validator so a webhook will be registered for the type. func (r *IBMVPCCluster) ValidateUpdate(_ runtime.Object) (admission.Warnings, error) { ibmvpcclusterlog.Info("validate update", "name", r.Name) - return nil, nil + return r.validateIBMVPCCluster() } // ValidateDelete implements webhook.Validator so a webhook will be registered for the type. @@ -65,3 +68,24 @@ func (r *IBMVPCCluster) ValidateDelete() (admission.Warnings, error) { ibmvpcclusterlog.Info("validate delete", "name", r.Name) return nil, nil } + +func (r *IBMVPCCluster) validateIBMVPCCluster() (admission.Warnings, error) { + var allErrs field.ErrorList + if err := r.validateIBMVPCClusterControlPlane(); err != nil { + allErrs = append(allErrs, err) + } + if len(allErrs) == 0 { + return nil, nil + } + + return nil, apierrors.NewInvalid( + schema.GroupKind{Group: "infrastructure.cluster.x-k8s.io", Kind: "IBMVPCCluster"}, + r.Name, allErrs) +} + +func (r *IBMVPCCluster) validateIBMVPCClusterControlPlane() *field.Error { + if r.Spec.ControlPlaneEndpoint.Host == "" && r.Spec.ControlPlaneLoadBalancer == nil { + return field.Invalid(field.NewPath(""), "", "One of - ControlPlaneEndpoint or ControlPlaneLoadBalancer must be specified") + } + return nil +} diff --git a/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/ibmvpcclustertemplate_types.go b/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/ibmvpcclustertemplate_types.go new file mode 100644 index 0000000000..2121d38a1f --- /dev/null +++ b/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/ibmvpcclustertemplate_types.go @@ -0,0 +1,62 @@ +/* +Copyright 2022 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta2 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + + capiv1beta1 "sigs.k8s.io/cluster-api/api/v1beta1" +) + +// IBMVPCClusterTemplateSpec defines the desired state of IBMVPCClusterTemplate. +type IBMVPCClusterTemplateSpec struct { + Template IBMVPCClusterTemplateResource `json:"template,omitempty"` +} + +// +kubebuilder:object:root=true +// +kubebuilder:resource:path=ibmvpcclustertemplates,scope=Namespaced,categories=cluster-api,shortName=ibmvpcct +// +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp",description="Time duration since creation of IBMVPCClusterTemplate" + +// IBMVPCClusterTemplate is the Schema for the ibmvpcclustertemplates API. +type IBMVPCClusterTemplate struct { + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty"` + + Spec IBMVPCClusterTemplateSpec `json:"spec,omitempty"` +} + +//+kubebuilder:object:root=true + +// IBMVPCClusterTemplateList contains a list of IBMVPCClusterTemplate. +type IBMVPCClusterTemplateList struct { + metav1.TypeMeta `json:",inline"` + metav1.ListMeta `json:"metadata,omitempty"` + Items []IBMVPCClusterTemplate `json:"items"` +} + +// IBMVPCClusterTemplateResource describes the data needed to create an IBMVPCCluster from a template. +type IBMVPCClusterTemplateResource struct { + // Standard object's metadata. + // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + // +optional + ObjectMeta capiv1beta1.ObjectMeta `json:"metadata,omitempty"` + Spec IBMVPCClusterSpec `json:"spec"` +} + +func init() { + SchemeBuilder.Register(&IBMVPCClusterTemplate{}, &IBMVPCClusterTemplateList{}) +} diff --git a/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/types.go b/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/types.go index 32096cbdae..d41c7816ae 100644 --- a/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/types.go +++ b/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/types.go @@ -93,6 +93,7 @@ type Subnet struct { type VPCEndpoint struct { Address *string `json:"address"` // +optional + // Deprecated: This field has no function and is going to be removed in the next release. FIPID *string `json:"floatingIPID,omitempty"` // +optional LBID *string `json:"loadBalancerIPID,omitempty"` diff --git a/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/zz_generated.deepcopy.go b/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/zz_generated.deepcopy.go index f1781854dc..a0062f18c7 100644 --- a/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/zz_generated.deepcopy.go +++ b/vendor/sigs.k8s.io/cluster-api-provider-ibmcloud/api/v1beta2/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright The Kubernetes Authors. @@ -707,6 +706,97 @@ func (in *IBMVPCClusterStatus) DeepCopy() *IBMVPCClusterStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *IBMVPCClusterTemplate) DeepCopyInto(out *IBMVPCClusterTemplate) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IBMVPCClusterTemplate. +func (in *IBMVPCClusterTemplate) DeepCopy() *IBMVPCClusterTemplate { + if in == nil { + return nil + } + out := new(IBMVPCClusterTemplate) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *IBMVPCClusterTemplate) 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 *IBMVPCClusterTemplateList) DeepCopyInto(out *IBMVPCClusterTemplateList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]IBMVPCClusterTemplate, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IBMVPCClusterTemplateList. +func (in *IBMVPCClusterTemplateList) DeepCopy() *IBMVPCClusterTemplateList { + if in == nil { + return nil + } + out := new(IBMVPCClusterTemplateList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *IBMVPCClusterTemplateList) 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 *IBMVPCClusterTemplateResource) DeepCopyInto(out *IBMVPCClusterTemplateResource) { + *out = *in + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IBMVPCClusterTemplateResource. +func (in *IBMVPCClusterTemplateResource) DeepCopy() *IBMVPCClusterTemplateResource { + if in == nil { + return nil + } + out := new(IBMVPCClusterTemplateResource) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *IBMVPCClusterTemplateSpec) DeepCopyInto(out *IBMVPCClusterTemplateSpec) { + *out = *in + in.Template.DeepCopyInto(&out.Template) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IBMVPCClusterTemplateSpec. +func (in *IBMVPCClusterTemplateSpec) DeepCopy() *IBMVPCClusterTemplateSpec { + if in == nil { + return nil + } + out := new(IBMVPCClusterTemplateSpec) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *IBMVPCMachine) DeepCopyInto(out *IBMVPCMachine) { *out = *in diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/.import-restrictions b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/.import-restrictions new file mode 100644 index 0000000000..a2e1dfd081 --- /dev/null +++ b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/.import-restrictions @@ -0,0 +1,5 @@ +rules: + - selectorRegexp: sigs[.]k8s[.]io/controller-runtime + allowedPrefixes: [] + forbiddenPrefixes: + - "sigs.k8s.io/controller-runtime" diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/cluster_types.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/cluster_types.go index d9ceff05c4..456d836223 100644 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/cluster_types.go +++ b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/cluster_types.go @@ -149,6 +149,10 @@ type WorkersTopology struct { // MachineDeployments is a list of machine deployments in the cluster. // +optional MachineDeployments []MachineDeploymentTopology `json:"machineDeployments,omitempty"` + + // MachinePools is a list of machine pools in the cluster. + // +optional + MachinePools []MachinePoolTopology `json:"machinePools,omitempty"` } // MachineDeploymentTopology specifies the different parameters for a set of worker nodes in the topology. @@ -240,6 +244,66 @@ type MachineHealthCheckTopology struct { MachineHealthCheckClass `json:",inline"` } +// MachinePoolTopology specifies the different parameters for a pool of worker nodes in the topology. +// This pool of nodes is managed by a MachinePool object whose lifecycle is managed by the Cluster controller. +type MachinePoolTopology struct { + // Metadata is the metadata applied to the MachinePool. + // At runtime this metadata is merged with the corresponding metadata from the ClusterClass. + // +optional + Metadata ObjectMeta `json:"metadata,omitempty"` + + // Class is the name of the MachinePoolClass used to create the pool of worker nodes. + // This should match one of the deployment classes defined in the ClusterClass object + // mentioned in the `Cluster.Spec.Class` field. + Class string `json:"class"` + + // Name is the unique identifier for this MachinePoolTopology. + // The value is used with other unique identifiers to create a MachinePool's Name + // (e.g. cluster's name, etc). In case the name is greater than the allowed maximum length, + // the values are hashed together. + Name string `json:"name"` + + // FailureDomains is the list of failure domains the machine pool will be created in. + // Must match a key in the FailureDomains map stored on the cluster object. + // +optional + FailureDomains []string `json:"failureDomains,omitempty"` + + // NodeDrainTimeout is the total amount of time that the controller will spend on draining a node. + // The default value is 0, meaning that the node can be drained without any time limitations. + // NOTE: NodeDrainTimeout is different from `kubectl drain --timeout` + // +optional + NodeDrainTimeout *metav1.Duration `json:"nodeDrainTimeout,omitempty"` + + // NodeVolumeDetachTimeout is the total amount of time that the controller will spend on waiting for all volumes + // to be detached. The default value is 0, meaning that the volumes can be detached without any time limitations. + // +optional + NodeVolumeDetachTimeout *metav1.Duration `json:"nodeVolumeDetachTimeout,omitempty"` + + // NodeDeletionTimeout defines how long the controller will attempt to delete the Node that the MachinePool + // hosts after the MachinePool is marked for deletion. A duration of 0 will retry deletion indefinitely. + // Defaults to 10 seconds. + // +optional + NodeDeletionTimeout *metav1.Duration `json:"nodeDeletionTimeout,omitempty"` + + // Minimum number of seconds for which a newly created machine pool should + // be ready. + // Defaults to 0 (machine will be considered available as soon as it + // is ready) + // +optional + MinReadySeconds *int32 `json:"minReadySeconds,omitempty"` + + // Replicas is the number of nodes belonging to this pool. + // If the value is nil, the MachinePool is created without the number of Replicas (defaulting to 1) + // and it's assumed that an external entity (like cluster autoscaler) is responsible for the management + // of this value. + // +optional + Replicas *int32 `json:"replicas,omitempty"` + + // Variables can be used to customize the MachinePool through patches. + // +optional + Variables *MachinePoolVariables `json:"variables,omitempty"` +} + // ClusterVariable can be used to customize the Cluster through patches. Each ClusterVariable is associated with a // Variable definition in the ClusterClass `status` variables. type ClusterVariable struct { @@ -270,6 +334,13 @@ type MachineDeploymentVariables struct { Overrides []ClusterVariable `json:"overrides,omitempty"` } +// MachinePoolVariables can be used to provide variables for a specific MachinePool. +type MachinePoolVariables struct { + // Overrides can be used to override Cluster level variables. + // +optional + Overrides []ClusterVariable `json:"overrides,omitempty"` +} + // ANCHOR_END: ClusterSpec // ANCHOR: ClusterNetwork @@ -409,6 +480,7 @@ func (v APIEndpoint) String() string { // +kubebuilder:resource:path=clusters,shortName=cl,scope=Namespaced,categories=cluster-api // +kubebuilder:storageversion // +kubebuilder:subresource:status +// +kubebuilder:printcolumn:name="ClusterClass",type="string",JSONPath=".spec.topology.class",description="ClusterClass of this Cluster, empty if the Cluster is not using a ClusterClass" // +kubebuilder:printcolumn:name="Phase",type="string",JSONPath=".status.phase",description="Cluster status such as Pending/Provisioning/Provisioned/Deleting/Failed" // +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp",description="Time duration since creation of Cluster" // +kubebuilder:printcolumn:name="Version",type="string",JSONPath=".spec.topology.version",description="Kubernetes version associated with this Cluster" @@ -528,7 +600,7 @@ type ClusterList struct { } func init() { - SchemeBuilder.Register(&Cluster{}, &ClusterList{}) + objectTypes = append(objectTypes, &Cluster{}, &ClusterList{}) } // FailureDomains is a slice of FailureDomains. diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/clusterclass_types.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/clusterclass_types.go index 6765d158c4..19cdad710c 100644 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/clusterclass_types.go +++ b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/clusterclass_types.go @@ -150,6 +150,11 @@ type WorkersClass struct { // a set of worker nodes. // +optional MachineDeployments []MachineDeploymentClass `json:"machineDeployments,omitempty"` + + // MachinePools is a list of machine pool classes that can be used to create + // a set of worker nodes. + // +optional + MachinePools []MachinePoolClass `json:"machinePools,omitempty"` } // MachineDeploymentClass serves as a template to define a set of worker nodes of the cluster @@ -279,6 +284,87 @@ type MachineHealthCheckClass struct { RemediationTemplate *corev1.ObjectReference `json:"remediationTemplate,omitempty"` } +// MachinePoolClass serves as a template to define a pool of worker nodes of the cluster +// provisioned using `ClusterClass`. +type MachinePoolClass struct { + // Class denotes a type of machine pool present in the cluster, + // this name MUST be unique within a ClusterClass and can be referenced + // in the Cluster to create a managed MachinePool. + Class string `json:"class"` + + // Template is a local struct containing a collection of templates for creation of + // MachinePools objects representing a pool of worker nodes. + Template MachinePoolClassTemplate `json:"template"` + + // FailureDomains is the list of failure domains the MachinePool should be attached to. + // Must match a key in the FailureDomains map stored on the cluster object. + // NOTE: This value can be overridden while defining a Cluster.Topology using this MachinePoolClass. + // +optional + FailureDomains []string `json:"failureDomains,omitempty"` + + // NamingStrategy allows changing the naming pattern used when creating the MachinePool. + // +optional + NamingStrategy *MachinePoolClassNamingStrategy `json:"namingStrategy,omitempty"` + + // NodeDrainTimeout is the total amount of time that the controller will spend on draining a node. + // The default value is 0, meaning that the node can be drained without any time limitations. + // NOTE: NodeDrainTimeout is different from `kubectl drain --timeout` + // NOTE: This value can be overridden while defining a Cluster.Topology using this MachinePoolClass. + // +optional + NodeDrainTimeout *metav1.Duration `json:"nodeDrainTimeout,omitempty"` + + // NodeVolumeDetachTimeout is the total amount of time that the controller will spend on waiting for all volumes + // to be detached. The default value is 0, meaning that the volumes can be detached without any time limitations. + // NOTE: This value can be overridden while defining a Cluster.Topology using this MachinePoolClass. + // +optional + NodeVolumeDetachTimeout *metav1.Duration `json:"nodeVolumeDetachTimeout,omitempty"` + + // NodeDeletionTimeout defines how long the controller will attempt to delete the Node that the Machine + // hosts after the Machine Pool is marked for deletion. A duration of 0 will retry deletion indefinitely. + // Defaults to 10 seconds. + // NOTE: This value can be overridden while defining a Cluster.Topology using this MachinePoolClass. + // +optional + NodeDeletionTimeout *metav1.Duration `json:"nodeDeletionTimeout,omitempty"` + + // Minimum number of seconds for which a newly created machine pool should + // be ready. + // Defaults to 0 (machine will be considered available as soon as it + // is ready) + // NOTE: This value can be overridden while defining a Cluster.Topology using this MachinePoolClass. + MinReadySeconds *int32 `json:"minReadySeconds,omitempty"` +} + +// MachinePoolClassTemplate defines how a MachinePool generated from a MachinePoolClass +// should look like. +type MachinePoolClassTemplate struct { + // Metadata is the metadata applied to the MachinePool. + // At runtime this metadata is merged with the corresponding metadata from the topology. + // +optional + Metadata ObjectMeta `json:"metadata,omitempty"` + + // Bootstrap contains the bootstrap template reference to be used + // for the creation of the Machines in the MachinePool. + Bootstrap LocalObjectTemplate `json:"bootstrap"` + + // Infrastructure contains the infrastructure template reference to be used + // for the creation of the MachinePool. + Infrastructure LocalObjectTemplate `json:"infrastructure"` +} + +// MachinePoolClassNamingStrategy defines the naming strategy for machine pool objects. +type MachinePoolClassNamingStrategy struct { + // Template defines the template to use for generating the name of the MachinePool object. + // If not defined, it will fallback to `{{ .cluster.name }}-{{ .machinePool.topologyName }}-{{ .random }}`. + // If the templated string exceeds 63 characters, it will be trimmed to 58 characters and will + // get concatenated with a random suffix of length 5. + // The templating mechanism provides the following arguments: + // * `.cluster.name`: The name of the cluster object. + // * `.random`: A random alphanumeric string, without vowels, of length 5. + // * `.machinePool.topologyName`: The name of the MachinePool topology (Cluster.spec.topology.workers.machinePools[].name). + // +optional + Template *string `json:"template,omitempty"` +} + // IsZero returns true if none of the values of MachineHealthCheckClass are defined. func (m MachineHealthCheckClass) IsZero() bool { return reflect.ValueOf(m).IsZero() @@ -507,6 +593,11 @@ type PatchSelectorMatch struct { // .spec.workers.machineDeployments. // +optional MachineDeploymentClass *PatchSelectorMatchMachineDeploymentClass `json:"machineDeploymentClass,omitempty"` + + // MachinePoolClass selects templates referenced in specific MachinePoolClasses in + // .spec.workers.machinePools. + // +optional + MachinePoolClass *PatchSelectorMatchMachinePoolClass `json:"machinePoolClass,omitempty"` } // PatchSelectorMatchMachineDeploymentClass selects templates referenced @@ -517,6 +608,14 @@ type PatchSelectorMatchMachineDeploymentClass struct { Names []string `json:"names,omitempty"` } +// PatchSelectorMatchMachinePoolClass selects templates referenced +// in specific MachinePoolClasses in .spec.workers.machinePools. +type PatchSelectorMatchMachinePoolClass struct { + // Names selects templates by class names. + // +optional + Names []string `json:"names,omitempty"` +} + // JSONPatch defines a JSON patch. type JSONPatch struct { // Op defines the operation of the patch. @@ -660,5 +759,5 @@ type ClusterClassList struct { } func init() { - SchemeBuilder.Register(&ClusterClass{}, &ClusterClassList{}) + objectTypes = append(objectTypes, &ClusterClass{}, &ClusterClassList{}) } diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/common_types.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/common_types.go index 6edc7e5bed..017f7f6757 100644 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/common_types.go +++ b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/common_types.go @@ -18,7 +18,10 @@ package v1beta1 import ( corev1 "k8s.io/api/core/v1" + apivalidation "k8s.io/apimachinery/pkg/api/validation" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + metav1validation "k8s.io/apimachinery/pkg/apis/meta/v1/validation" + "k8s.io/apimachinery/pkg/util/validation/field" ) const ( @@ -57,6 +60,10 @@ const ( // a classy Cluster to define the maximum concurrency while upgrading MachineDeployments. ClusterTopologyUpgradeConcurrencyAnnotation = "topology.cluster.x-k8s.io/upgrade-concurrency" + // ClusterTopologyMachinePoolNameLabel is the label set on the generated MachinePool objects + // to track the name of the MachinePool topology it represents. + ClusterTopologyMachinePoolNameLabel = "topology.cluster.x-k8s.io/pool-name" + // ClusterTopologyUnsafeUpdateClassNameAnnotation can be used to disable the webhook check on // update that disallows a pre-existing Cluster to be populated with Topology information and Class. ClusterTopologyUnsafeUpdateClassNameAnnotation = "unsafe.topology.cluster.x-k8s.io/disable-update-class-name-check" @@ -297,3 +304,16 @@ type ObjectMeta struct { // +optional Annotations map[string]string `json:"annotations,omitempty"` } + +// Validate validates the labels and annotations in ObjectMeta. +func (metadata *ObjectMeta) Validate(parent *field.Path) field.ErrorList { + allErrs := metav1validation.ValidateLabels( + metadata.Labels, + parent.Child("labels"), + ) + allErrs = append(allErrs, apivalidation.ValidateAnnotations( + metadata.Annotations, + parent.Child("annotations"), + )...) + return allErrs +} diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/condition_consts.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/condition_consts.go index 7b1a5483b7..5e2bc212ec 100644 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/condition_consts.go +++ b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/condition_consts.go @@ -299,6 +299,19 @@ const ( // not yet completed because the upgrade for at least one of the MachineDeployments has been deferred. TopologyReconciledMachineDeploymentsUpgradeDeferredReason = "MachineDeploymentsUpgradeDeferred" + // TopologyReconciledMachinePoolsUpgradePendingReason (Severity=Info) documents reconciliation of a Cluster topology + // not yet completed because at least one of the MachinePools is not yet updated to match the desired topology spec. + TopologyReconciledMachinePoolsUpgradePendingReason = "MachinePoolsUpgradePending" + + // TopologyReconciledMachinePoolsCreatePendingReason (Severity=Info) documents reconciliation of a Cluster topology + // not yet completed because at least one of the MachinePools is yet to be created. + // This generally happens because new MachinePool creations are held off while the ControlPlane is not stable. + TopologyReconciledMachinePoolsCreatePendingReason = "MachinePoolsCreatePending" + + // TopologyReconciledMachinePoolsUpgradeDeferredReason (Severity=Info) documents reconciliation of a Cluster topology + // not yet completed because the upgrade for at least one of the MachinePools has been deferred. + TopologyReconciledMachinePoolsUpgradeDeferredReason = "MachinePoolsUpgradeDeferred" + // TopologyReconciledHookBlockingReason (Severity=Info) documents reconciliation of a Cluster topology // not yet completed because at least one of the lifecycle hooks is blocking. TopologyReconciledHookBlockingReason = "LifecycleHookBlocking" diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/groupversion_info.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/groupversion_info.go index 2d118b8de8..95968743c6 100644 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/groupversion_info.go +++ b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/groupversion_info.go @@ -20,17 +20,26 @@ limitations under the License. package v1beta1 import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" - "sigs.k8s.io/controller-runtime/pkg/scheme" ) var ( // GroupVersion is group version used to register these objects. GroupVersion = schema.GroupVersion{Group: "cluster.x-k8s.io", Version: "v1beta1"} - // SchemeBuilder is used to add go types to the GroupVersionKind scheme. - SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion} + // schemeBuilder is used to add go types to the GroupVersionKind scheme. + schemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) // AddToScheme adds the types in this group-version to the given scheme. - AddToScheme = SchemeBuilder.AddToScheme + AddToScheme = schemeBuilder.AddToScheme + + objectTypes = []runtime.Object{} ) + +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(GroupVersion, objectTypes...) + metav1.AddToGroupVersion(scheme, GroupVersion) + return nil +} diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machine_types.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machine_types.go index ee9597306c..e6e0fa8fe0 100644 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machine_types.go +++ b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machine_types.go @@ -307,5 +307,5 @@ type MachineList struct { } func init() { - SchemeBuilder.Register(&Machine{}, &MachineList{}) + objectTypes = append(objectTypes, &Machine{}, &MachineList{}) } diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machine_webhook.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machine_webhook.go deleted file mode 100644 index c5d9ea4bb0..0000000000 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machine_webhook.go +++ /dev/null @@ -1,158 +0,0 @@ -/* -Copyright 2021 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1beta1 - -import ( - "fmt" - "strings" - "time" - - apierrors "k8s.io/apimachinery/pkg/api/errors" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime" - "k8s.io/apimachinery/pkg/util/validation/field" - ctrl "sigs.k8s.io/controller-runtime" - "sigs.k8s.io/controller-runtime/pkg/webhook" - "sigs.k8s.io/controller-runtime/pkg/webhook/admission" - - "sigs.k8s.io/cluster-api/util/version" -) - -const defaultNodeDeletionTimeout = 10 * time.Second - -func (m *Machine) SetupWebhookWithManager(mgr ctrl.Manager) error { - return ctrl.NewWebhookManagedBy(mgr). - For(m). - Complete() -} - -// +kubebuilder:webhook:verbs=create;update,path=/validate-cluster-x-k8s-io-v1beta1-machine,mutating=false,failurePolicy=fail,matchPolicy=Equivalent,groups=cluster.x-k8s.io,resources=machines,versions=v1beta1,name=validation.machine.cluster.x-k8s.io,sideEffects=None,admissionReviewVersions=v1;v1beta1 -// +kubebuilder:webhook:verbs=create;update,path=/mutate-cluster-x-k8s-io-v1beta1-machine,mutating=true,failurePolicy=fail,matchPolicy=Equivalent,groups=cluster.x-k8s.io,resources=machines,versions=v1beta1,name=default.machine.cluster.x-k8s.io,sideEffects=None,admissionReviewVersions=v1;v1beta1 - -var _ webhook.Validator = &Machine{} -var _ webhook.Defaulter = &Machine{} - -// Default implements webhook.Defaulter so a webhook will be registered for the type. -func (m *Machine) Default() { - if m.Labels == nil { - m.Labels = make(map[string]string) - } - m.Labels[ClusterNameLabel] = m.Spec.ClusterName - - if m.Spec.Bootstrap.ConfigRef != nil && m.Spec.Bootstrap.ConfigRef.Namespace == "" { - m.Spec.Bootstrap.ConfigRef.Namespace = m.Namespace - } - - if m.Spec.InfrastructureRef.Namespace == "" { - m.Spec.InfrastructureRef.Namespace = m.Namespace - } - - if m.Spec.Version != nil && !strings.HasPrefix(*m.Spec.Version, "v") { - normalizedVersion := "v" + *m.Spec.Version - m.Spec.Version = &normalizedVersion - } - - if m.Spec.NodeDeletionTimeout == nil { - m.Spec.NodeDeletionTimeout = &metav1.Duration{Duration: defaultNodeDeletionTimeout} - } -} - -// ValidateCreate implements webhook.Validator so a webhook will be registered for the type. -func (m *Machine) ValidateCreate() (admission.Warnings, error) { - return nil, m.validate(nil) -} - -// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type. -func (m *Machine) ValidateUpdate(old runtime.Object) (admission.Warnings, error) { - oldM, ok := old.(*Machine) - if !ok { - return nil, apierrors.NewBadRequest(fmt.Sprintf("expected a Machine but got a %T", old)) - } - return nil, m.validate(oldM) -} - -// ValidateDelete implements webhook.Validator so a webhook will be registered for the type. -func (m *Machine) ValidateDelete() (admission.Warnings, error) { - return nil, nil -} - -func (m *Machine) validate(old *Machine) error { - var allErrs field.ErrorList - specPath := field.NewPath("spec") - if m.Spec.Bootstrap.ConfigRef == nil && m.Spec.Bootstrap.DataSecretName == nil { - // MachinePool Machines don't have a bootstrap configRef, so don't require it. The bootstrap config is instead owned by the MachinePool. - if !isMachinePoolMachine(m) { - allErrs = append( - allErrs, - field.Required( - specPath.Child("bootstrap", "data"), - "expected either spec.bootstrap.dataSecretName or spec.bootstrap.configRef to be populated", - ), - ) - } - } - - if m.Spec.Bootstrap.ConfigRef != nil && m.Spec.Bootstrap.ConfigRef.Namespace != m.Namespace { - allErrs = append( - allErrs, - field.Invalid( - specPath.Child("bootstrap", "configRef", "namespace"), - m.Spec.Bootstrap.ConfigRef.Namespace, - "must match metadata.namespace", - ), - ) - } - - if m.Spec.InfrastructureRef.Namespace != m.Namespace { - allErrs = append( - allErrs, - field.Invalid( - specPath.Child("infrastructureRef", "namespace"), - m.Spec.InfrastructureRef.Namespace, - "must match metadata.namespace", - ), - ) - } - - if old != nil && old.Spec.ClusterName != m.Spec.ClusterName { - allErrs = append( - allErrs, - field.Forbidden(specPath.Child("clusterName"), "field is immutable"), - ) - } - - if m.Spec.Version != nil { - if !version.KubeSemver.MatchString(*m.Spec.Version) { - allErrs = append(allErrs, field.Invalid(specPath.Child("version"), *m.Spec.Version, "must be a valid semantic version")) - } - } - - if len(allErrs) == 0 { - return nil - } - return apierrors.NewInvalid(GroupVersion.WithKind("Machine").GroupKind(), m.Name, allErrs) -} - -func isMachinePoolMachine(m *Machine) bool { - for _, owner := range m.OwnerReferences { - if owner.Kind == "MachinePool" { - return true - } - } - - return false -} diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machinedeployment_types.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machinedeployment_types.go index 3bd0109fbc..13a023d07a 100644 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machinedeployment_types.go +++ b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machinedeployment_types.go @@ -152,8 +152,8 @@ type MachineDeploymentSpec struct { // MachineDeploymentStrategy describes how to replace existing machines // with new ones. type MachineDeploymentStrategy struct { - // Type of deployment. - // Default is RollingUpdate. + // Type of deployment. Allowed values are RollingUpdate and OnDelete. + // The default is RollingUpdate. // +kubebuilder:validation:Enum=RollingUpdate;OnDelete // +optional Type MachineDeploymentStrategyType `json:"type,omitempty"` @@ -337,7 +337,7 @@ type MachineDeploymentList struct { } func init() { - SchemeBuilder.Register(&MachineDeployment{}, &MachineDeploymentList{}) + objectTypes = append(objectTypes, &MachineDeployment{}, &MachineDeploymentList{}) } // GetConditions returns the set of conditions for the machinedeployment. diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machinedeployment_webhook.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machinedeployment_webhook.go deleted file mode 100644 index 472c01afd5..0000000000 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machinedeployment_webhook.go +++ /dev/null @@ -1,375 +0,0 @@ -/* -Copyright 2021 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1beta1 - -import ( - "context" - "fmt" - "strconv" - "strings" - - "github.com/pkg/errors" - v1 "k8s.io/api/admission/v1" - apierrors "k8s.io/apimachinery/pkg/api/errors" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/labels" - "k8s.io/apimachinery/pkg/runtime" - "k8s.io/apimachinery/pkg/util/intstr" - "k8s.io/apimachinery/pkg/util/validation" - "k8s.io/apimachinery/pkg/util/validation/field" - "k8s.io/utils/pointer" - ctrl "sigs.k8s.io/controller-runtime" - "sigs.k8s.io/controller-runtime/pkg/webhook" - "sigs.k8s.io/controller-runtime/pkg/webhook/admission" - - "sigs.k8s.io/cluster-api/feature" - "sigs.k8s.io/cluster-api/util/version" -) - -func (m *MachineDeployment) SetupWebhookWithManager(mgr ctrl.Manager) error { - // This registers MachineDeployment as a validating webhook and - // machineDeploymentDefaulter as a defaulting webhook. - return ctrl.NewWebhookManagedBy(mgr). - For(m). - WithDefaulter(MachineDeploymentDefaulter(mgr.GetScheme())). - Complete() -} - -// +kubebuilder:webhook:verbs=create;update,path=/validate-cluster-x-k8s-io-v1beta1-machinedeployment,mutating=false,failurePolicy=fail,matchPolicy=Equivalent,groups=cluster.x-k8s.io,resources=machinedeployments,versions=v1beta1,name=validation.machinedeployment.cluster.x-k8s.io,sideEffects=None,admissionReviewVersions=v1;v1beta1 -// +kubebuilder:webhook:verbs=create;update,path=/mutate-cluster-x-k8s-io-v1beta1-machinedeployment,mutating=true,failurePolicy=fail,matchPolicy=Equivalent,groups=cluster.x-k8s.io,resources=machinedeployments,versions=v1beta1,name=default.machinedeployment.cluster.x-k8s.io,sideEffects=None,admissionReviewVersions=v1;v1beta1 - -var _ webhook.CustomDefaulter = &machineDeploymentDefaulter{} -var _ webhook.Validator = &MachineDeployment{} - -// MachineDeploymentDefaulter creates a new CustomDefaulter for MachineDeployments. -func MachineDeploymentDefaulter(scheme *runtime.Scheme) webhook.CustomDefaulter { - return &machineDeploymentDefaulter{ - decoder: admission.NewDecoder(scheme), - } -} - -// machineDeploymentDefaulter implements a defaulting webhook for MachineDeployment. -type machineDeploymentDefaulter struct { - decoder *admission.Decoder -} - -// Default implements webhook.CustomDefaulter. -func (webhook *machineDeploymentDefaulter) Default(ctx context.Context, obj runtime.Object) error { - m, ok := obj.(*MachineDeployment) - if !ok { - return apierrors.NewBadRequest(fmt.Sprintf("expected a MachineDeployment but got a %T", obj)) - } - - req, err := admission.RequestFromContext(ctx) - if err != nil { - return err - } - dryRun := false - if req.DryRun != nil { - dryRun = *req.DryRun - } - - var oldMD *MachineDeployment - if req.Operation == v1.Update { - oldMD = &MachineDeployment{} - if err := webhook.decoder.DecodeRaw(req.OldObject, oldMD); err != nil { - return errors.Wrapf(err, "failed to decode oldObject to MachineDeployment") - } - } - - if m.Labels == nil { - m.Labels = make(map[string]string) - } - m.Labels[ClusterNameLabel] = m.Spec.ClusterName - - replicas, err := calculateMachineDeploymentReplicas(ctx, oldMD, m, dryRun) - if err != nil { - return err - } - m.Spec.Replicas = pointer.Int32(replicas) - - if m.Spec.MinReadySeconds == nil { - m.Spec.MinReadySeconds = pointer.Int32(0) - } - - if m.Spec.RevisionHistoryLimit == nil { - m.Spec.RevisionHistoryLimit = pointer.Int32(1) - } - - if m.Spec.ProgressDeadlineSeconds == nil { - m.Spec.ProgressDeadlineSeconds = pointer.Int32(600) - } - - if m.Spec.Selector.MatchLabels == nil { - m.Spec.Selector.MatchLabels = make(map[string]string) - } - - if m.Spec.Strategy == nil { - m.Spec.Strategy = &MachineDeploymentStrategy{} - } - - if m.Spec.Strategy.Type == "" { - m.Spec.Strategy.Type = RollingUpdateMachineDeploymentStrategyType - } - - if m.Spec.Template.Labels == nil { - m.Spec.Template.Labels = make(map[string]string) - } - - // Default RollingUpdate strategy only if strategy type is RollingUpdate. - if m.Spec.Strategy.Type == RollingUpdateMachineDeploymentStrategyType { - if m.Spec.Strategy.RollingUpdate == nil { - m.Spec.Strategy.RollingUpdate = &MachineRollingUpdateDeployment{} - } - if m.Spec.Strategy.RollingUpdate.MaxSurge == nil { - ios1 := intstr.FromInt(1) - m.Spec.Strategy.RollingUpdate.MaxSurge = &ios1 - } - if m.Spec.Strategy.RollingUpdate.MaxUnavailable == nil { - ios0 := intstr.FromInt(0) - m.Spec.Strategy.RollingUpdate.MaxUnavailable = &ios0 - } - } - - // If no selector has been provided, add label and selector for the - // MachineDeployment's name as a default way of providing uniqueness. - if len(m.Spec.Selector.MatchLabels) == 0 && len(m.Spec.Selector.MatchExpressions) == 0 { - m.Spec.Selector.MatchLabels[MachineDeploymentNameLabel] = m.Name - m.Spec.Template.Labels[MachineDeploymentNameLabel] = m.Name - } - // Make sure selector and template to be in the same cluster. - m.Spec.Selector.MatchLabels[ClusterNameLabel] = m.Spec.ClusterName - m.Spec.Template.Labels[ClusterNameLabel] = m.Spec.ClusterName - - // tolerate version strings without a "v" prefix: prepend it if it's not there - if m.Spec.Template.Spec.Version != nil && !strings.HasPrefix(*m.Spec.Template.Spec.Version, "v") { - normalizedVersion := "v" + *m.Spec.Template.Spec.Version - m.Spec.Template.Spec.Version = &normalizedVersion - } - - return nil -} - -// ValidateCreate implements webhook.Validator so a webhook will be registered for the type. -func (m *MachineDeployment) ValidateCreate() (admission.Warnings, error) { - return nil, m.validate(nil) -} - -// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type. -func (m *MachineDeployment) ValidateUpdate(old runtime.Object) (admission.Warnings, error) { - oldMD, ok := old.(*MachineDeployment) - if !ok { - return nil, apierrors.NewBadRequest(fmt.Sprintf("expected a MachineDeployment but got a %T", old)) - } - return nil, m.validate(oldMD) -} - -// ValidateDelete implements webhook.Validator so a webhook will be registered for the type. -func (m *MachineDeployment) ValidateDelete() (admission.Warnings, error) { - return nil, nil -} - -func (m *MachineDeployment) validate(old *MachineDeployment) error { - var allErrs field.ErrorList - // The MachineDeployment name is used as a label value. This check ensures names which are not be valid label values are rejected. - if errs := validation.IsValidLabelValue(m.Name); len(errs) != 0 { - for _, err := range errs { - allErrs = append( - allErrs, - field.Invalid( - field.NewPath("metadata", "name"), - m.Name, - fmt.Sprintf("must be a valid label value: %s", err), - ), - ) - } - } - specPath := field.NewPath("spec") - selector, err := metav1.LabelSelectorAsSelector(&m.Spec.Selector) - if err != nil { - allErrs = append( - allErrs, - field.Invalid(specPath.Child("selector"), m.Spec.Selector, err.Error()), - ) - } else if !selector.Matches(labels.Set(m.Spec.Template.Labels)) { - allErrs = append( - allErrs, - field.Forbidden( - specPath.Child("template", "metadata", "labels"), - fmt.Sprintf("must match spec.selector %q", selector.String()), - ), - ) - } - - // MachineSet preflight checks that should be skipped could also be set as annotation on the MachineDeployment - // since MachineDeployment annotations are synced to the MachineSet. - if feature.Gates.Enabled(feature.MachineSetPreflightChecks) { - if err := validateSkippedMachineSetPreflightChecks(m); err != nil { - allErrs = append(allErrs, err) - } - } - - if old != nil && old.Spec.ClusterName != m.Spec.ClusterName { - allErrs = append( - allErrs, - field.Forbidden( - specPath.Child("clusterName"), - "field is immutable", - ), - ) - } - - if m.Spec.Strategy != nil && m.Spec.Strategy.RollingUpdate != nil { - total := 1 - if m.Spec.Replicas != nil { - total = int(*m.Spec.Replicas) - } - - if m.Spec.Strategy.RollingUpdate.MaxSurge != nil { - if _, err := intstr.GetScaledValueFromIntOrPercent(m.Spec.Strategy.RollingUpdate.MaxSurge, total, true); err != nil { - allErrs = append( - allErrs, - field.Invalid(specPath.Child("strategy", "rollingUpdate", "maxSurge"), - m.Spec.Strategy.RollingUpdate.MaxSurge, fmt.Sprintf("must be either an int or a percentage: %v", err.Error())), - ) - } - } - - if m.Spec.Strategy.RollingUpdate.MaxUnavailable != nil { - if _, err := intstr.GetScaledValueFromIntOrPercent(m.Spec.Strategy.RollingUpdate.MaxUnavailable, total, true); err != nil { - allErrs = append( - allErrs, - field.Invalid(specPath.Child("strategy", "rollingUpdate", "maxUnavailable"), - m.Spec.Strategy.RollingUpdate.MaxUnavailable, fmt.Sprintf("must be either an int or a percentage: %v", err.Error())), - ) - } - } - } - - if m.Spec.Template.Spec.Version != nil { - if !version.KubeSemver.MatchString(*m.Spec.Template.Spec.Version) { - allErrs = append(allErrs, field.Invalid(specPath.Child("template", "spec", "version"), *m.Spec.Template.Spec.Version, "must be a valid semantic version")) - } - } - - if len(allErrs) == 0 { - return nil - } - - return apierrors.NewInvalid(GroupVersion.WithKind("MachineDeployment").GroupKind(), m.Name, allErrs) -} - -// calculateMachineDeploymentReplicas calculates the default value of the replicas field. -// The value will be calculated based on the following logic: -// * if replicas is already set on newMD, keep the current value -// * if the autoscaler min size and max size annotations are set: -// - if it's a new MachineDeployment, use min size -// - if the replicas field of the old MachineDeployment is < min size, use min size -// - if the replicas field of the old MachineDeployment is > max size, use max size -// - if the replicas field of the old MachineDeployment is in the (min size, max size) range, keep the value from the oldMD -// -// * otherwise use 1 -// -// The goal of this logic is to provide a smoother UX for clusters using the Kubernetes autoscaler. -// Note: Autoscaler only takes over control of the replicas field if the replicas value is in the (min size, max size) range. -// -// We are supporting the following use cases: -// * A new MD is created and replicas should be managed by the autoscaler -// - Either via the default annotation or via the min size and max size annotations the replicas field -// is defaulted to a value which is within the (min size, max size) range so the autoscaler can take control. -// -// * An existing MD which initially wasn't controlled by the autoscaler should be later controlled by the autoscaler -// - To adopt an existing MD users can use the default, min size and max size annotations to enable the autoscaler -// and to ensure the replicas field is within the (min size, max size) range. Without the annotations handing over -// control to the autoscaler by unsetting the replicas field would lead to the field being set to 1. This is very -// disruptive for existing Machines and if 1 is outside the (min size, max size) range the autoscaler won't take -// control. -// -// Notes: -// - While the min size and max size annotations of the autoscaler provide the best UX, other autoscalers can use the -// DefaultReplicasAnnotation if they have similar use cases. -func calculateMachineDeploymentReplicas(ctx context.Context, oldMD *MachineDeployment, newMD *MachineDeployment, dryRun bool) (int32, error) { - // If replicas is already set => Keep the current value. - if newMD.Spec.Replicas != nil { - return *newMD.Spec.Replicas, nil - } - - log := ctrl.LoggerFrom(ctx) - - // If both autoscaler annotations are set, use them to calculate the default value. - minSizeString, hasMinSizeAnnotation := newMD.Annotations[AutoscalerMinSizeAnnotation] - maxSizeString, hasMaxSizeAnnotation := newMD.Annotations[AutoscalerMaxSizeAnnotation] - if hasMinSizeAnnotation && hasMaxSizeAnnotation { - minSize, err := strconv.ParseInt(minSizeString, 10, 32) - if err != nil { - return 0, errors.Wrapf(err, "failed to caculate MachineDeployment replicas value: could not parse the value of the %q annotation", AutoscalerMinSizeAnnotation) - } - maxSize, err := strconv.ParseInt(maxSizeString, 10, 32) - if err != nil { - return 0, errors.Wrapf(err, "failed to caculate MachineDeployment replicas value: could not parse the value of the %q annotation", AutoscalerMaxSizeAnnotation) - } - - // If it's a new MachineDeployment => Use the min size. - // Note: This will result in a scale up to get into the range where autoscaler takes over. - if oldMD == nil { - if !dryRun { - log.V(2).Info(fmt.Sprintf("Replica field has been defaulted to %d based on the %s annotation (MD is a new MD)", minSize, AutoscalerMinSizeAnnotation)) - } - return int32(minSize), nil - } - - // Otherwise we are handing over the control for the replicas field for an existing MachineDeployment - // to the autoscaler. - - switch { - // If the old MachineDeployment doesn't have replicas set => Use the min size. - // Note: As defaulting always sets the replica field, this case should not be possible - // We only have this handling to be 100% safe against panics. - case oldMD.Spec.Replicas == nil: - if !dryRun { - log.V(2).Info(fmt.Sprintf("Replica field has been defaulted to %d based on the %s annotation (old MD didn't have replicas set)", minSize, AutoscalerMinSizeAnnotation)) - } - return int32(minSize), nil - // If the old MachineDeployment replicas are lower than min size => Use the min size. - // Note: This will result in a scale up to get into the range where autoscaler takes over. - case *oldMD.Spec.Replicas < int32(minSize): - if !dryRun { - log.V(2).Info(fmt.Sprintf("Replica field has been defaulted to %d based on the %s annotation (old MD had replicas below min size)", minSize, AutoscalerMinSizeAnnotation)) - } - return int32(minSize), nil - // If the old MachineDeployment replicas are higher than max size => Use the max size. - // Note: This will result in a scale down to get into the range where autoscaler takes over. - case *oldMD.Spec.Replicas > int32(maxSize): - if !dryRun { - log.V(2).Info(fmt.Sprintf("Replica field has been defaulted to %d based on the %s annotation (old MD had replicas above max size)", maxSize, AutoscalerMaxSizeAnnotation)) - } - return int32(maxSize), nil - // If the old MachineDeployment replicas are between min and max size => Keep the current value. - default: - if !dryRun { - log.V(2).Info(fmt.Sprintf("Replica field has been defaulted to %d based on replicas of the old MachineDeployment (old MD had replicas within min size / max size range)", *oldMD.Spec.Replicas)) - } - return *oldMD.Spec.Replicas, nil - } - } - - // If neither the default nor the autoscaler annotations are set => Default to 1. - if !dryRun { - log.V(2).Info("Replica field has been defaulted to 1") - } - return 1, nil -} diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machinehealthcheck_types.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machinehealthcheck_types.go index a8d1203518..4f17b5f9cc 100644 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machinehealthcheck_types.go +++ b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machinehealthcheck_types.go @@ -17,11 +17,21 @@ limitations under the License. package v1beta1 import ( + "time" + corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/util/intstr" ) +var ( + // DefaultNodeStartupTimeout is the time allowed for a node to start up. + // Can be made longer as part of spec if required for particular provider. + // 10 minutes should allow the instance to start and the node to join the + // cluster on most providers. + DefaultNodeStartupTimeout = metav1.Duration{Duration: 10 * time.Minute} +) + // ANCHOR: MachineHealthCheckSpec // MachineHealthCheckSpec defines the desired state of MachineHealthCheck. @@ -169,5 +179,5 @@ type MachineHealthCheckList struct { } func init() { - SchemeBuilder.Register(&MachineHealthCheck{}, &MachineHealthCheckList{}) + objectTypes = append(objectTypes, &MachineHealthCheck{}, &MachineHealthCheckList{}) } diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machinehealthcheck_webhook.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machinehealthcheck_webhook.go deleted file mode 100644 index 44c596feb5..0000000000 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machinehealthcheck_webhook.go +++ /dev/null @@ -1,188 +0,0 @@ -/* -Copyright 2021 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1beta1 - -import ( - "fmt" - "time" - - apierrors "k8s.io/apimachinery/pkg/api/errors" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime" - "k8s.io/apimachinery/pkg/util/intstr" - "k8s.io/apimachinery/pkg/util/validation/field" - ctrl "sigs.k8s.io/controller-runtime" - "sigs.k8s.io/controller-runtime/pkg/webhook" - "sigs.k8s.io/controller-runtime/pkg/webhook/admission" -) - -var ( - // DefaultNodeStartupTimeout is the time allowed for a node to start up. - // Can be made longer as part of spec if required for particular provider. - // 10 minutes should allow the instance to start and the node to join the - // cluster on most providers. - DefaultNodeStartupTimeout = metav1.Duration{Duration: 10 * time.Minute} - // Minimum time allowed for a node to start up. - minNodeStartupTimeout = metav1.Duration{Duration: 30 * time.Second} - // We allow users to disable the nodeStartupTimeout by setting the duration to 0. - disabledNodeStartupTimeout = ZeroDuration -) - -// SetMinNodeStartupTimeout allows users to optionally set a custom timeout -// for the validation webhook. -// -// This function is mostly used within envtest (integration tests), and should -// never be used in a production environment. -func SetMinNodeStartupTimeout(d metav1.Duration) { - minNodeStartupTimeout = d -} - -func (m *MachineHealthCheck) SetupWebhookWithManager(mgr ctrl.Manager) error { - return ctrl.NewWebhookManagedBy(mgr). - For(m). - Complete() -} - -// +kubebuilder:webhook:verbs=create;update,path=/validate-cluster-x-k8s-io-v1beta1-machinehealthcheck,mutating=false,failurePolicy=fail,matchPolicy=Equivalent,groups=cluster.x-k8s.io,resources=machinehealthchecks,versions=v1beta1,name=validation.machinehealthcheck.cluster.x-k8s.io,sideEffects=None,admissionReviewVersions=v1;v1beta1 -// +kubebuilder:webhook:verbs=create;update,path=/mutate-cluster-x-k8s-io-v1beta1-machinehealthcheck,mutating=true,failurePolicy=fail,matchPolicy=Equivalent,groups=cluster.x-k8s.io,resources=machinehealthchecks,versions=v1beta1,name=default.machinehealthcheck.cluster.x-k8s.io,sideEffects=None,admissionReviewVersions=v1;v1beta1 - -var _ webhook.Defaulter = &MachineHealthCheck{} -var _ webhook.Validator = &MachineHealthCheck{} - -// Default implements webhook.Defaulter so a webhook will be registered for the type. -func (m *MachineHealthCheck) Default() { - if m.Labels == nil { - m.Labels = make(map[string]string) - } - m.Labels[ClusterNameLabel] = m.Spec.ClusterName - - if m.Spec.MaxUnhealthy == nil { - defaultMaxUnhealthy := intstr.FromString("100%") - m.Spec.MaxUnhealthy = &defaultMaxUnhealthy - } - - if m.Spec.NodeStartupTimeout == nil { - m.Spec.NodeStartupTimeout = &DefaultNodeStartupTimeout - } - - if m.Spec.RemediationTemplate != nil && m.Spec.RemediationTemplate.Namespace == "" { - m.Spec.RemediationTemplate.Namespace = m.Namespace - } -} - -// ValidateCreate implements webhook.Validator so a webhook will be registered for the type. -func (m *MachineHealthCheck) ValidateCreate() (admission.Warnings, error) { - return nil, m.validate(nil) -} - -// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type. -func (m *MachineHealthCheck) ValidateUpdate(old runtime.Object) (admission.Warnings, error) { - mhc, ok := old.(*MachineHealthCheck) - if !ok { - return nil, apierrors.NewBadRequest(fmt.Sprintf("expected a MachineHealthCheck but got a %T", old)) - } - return nil, m.validate(mhc) -} - -// ValidateDelete implements webhook.Validator so a webhook will be registered for the type. -func (m *MachineHealthCheck) ValidateDelete() (admission.Warnings, error) { - return nil, nil -} - -func (m *MachineHealthCheck) validate(old *MachineHealthCheck) error { - var allErrs field.ErrorList - specPath := field.NewPath("spec") - - // Validate selector parses as Selector - selector, err := metav1.LabelSelectorAsSelector(&m.Spec.Selector) - if err != nil { - allErrs = append( - allErrs, - field.Invalid(specPath.Child("selector"), m.Spec.Selector, err.Error()), - ) - } - - // Validate that the selector isn't empty. - if selector != nil && selector.Empty() { - allErrs = append( - allErrs, - field.Required(specPath.Child("selector"), "selector must not be empty"), - ) - } - - if clusterName, ok := m.Spec.Selector.MatchLabels[ClusterNameLabel]; ok && clusterName != m.Spec.ClusterName { - allErrs = append( - allErrs, - field.Invalid(specPath.Child("selector"), m.Spec.Selector, "cannot specify a cluster selector other than the one specified by ClusterName")) - } - - if old != nil && old.Spec.ClusterName != m.Spec.ClusterName { - allErrs = append( - allErrs, - field.Forbidden(specPath.Child("clusterName"), "field is immutable"), - ) - } - - allErrs = append(allErrs, m.ValidateCommonFields(specPath)...) - - if len(allErrs) == 0 { - return nil - } - return apierrors.NewInvalid(GroupVersion.WithKind("MachineHealthCheck").GroupKind(), m.Name, allErrs) -} - -// ValidateCommonFields validates UnhealthyConditions NodeStartupTimeout, MaxUnhealthy, and RemediationTemplate of the MHC. -// These are the fields in common with other types which define MachineHealthChecks such as MachineHealthCheckClass and MachineHealthCheckTopology. -func (m *MachineHealthCheck) ValidateCommonFields(fldPath *field.Path) field.ErrorList { - var allErrs field.ErrorList - - if m.Spec.NodeStartupTimeout != nil && - m.Spec.NodeStartupTimeout.Seconds() != disabledNodeStartupTimeout.Seconds() && - m.Spec.NodeStartupTimeout.Seconds() < minNodeStartupTimeout.Seconds() { - allErrs = append( - allErrs, - field.Invalid(fldPath.Child("nodeStartupTimeout"), m.Spec.NodeStartupTimeout.String(), "must be at least 30s"), - ) - } - if m.Spec.MaxUnhealthy != nil { - if _, err := intstr.GetScaledValueFromIntOrPercent(m.Spec.MaxUnhealthy, 0, false); err != nil { - allErrs = append( - allErrs, - field.Invalid(fldPath.Child("maxUnhealthy"), m.Spec.MaxUnhealthy, fmt.Sprintf("must be either an int or a percentage: %v", err.Error())), - ) - } - } - if m.Spec.RemediationTemplate != nil && m.Spec.RemediationTemplate.Namespace != m.Namespace { - allErrs = append( - allErrs, - field.Invalid( - fldPath.Child("remediationTemplate", "namespace"), - m.Spec.RemediationTemplate.Namespace, - "must match metadata.namespace", - ), - ) - } - - if len(m.Spec.UnhealthyConditions) == 0 { - allErrs = append(allErrs, field.Forbidden( - fldPath.Child("unhealthyConditions"), - "must have at least one entry", - )) - } - - return allErrs -} diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machineset_types.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machineset_types.go index c888df5c45..843b343a45 100644 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machineset_types.go +++ b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machineset_types.go @@ -240,5 +240,5 @@ type MachineSetList struct { } func init() { - SchemeBuilder.Register(&MachineSet{}, &MachineSetList{}) + objectTypes = append(objectTypes, &MachineSet{}, &MachineSetList{}) } diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machineset_webhook.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machineset_webhook.go deleted file mode 100644 index 560ef68af5..0000000000 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/machineset_webhook.go +++ /dev/null @@ -1,194 +0,0 @@ -/* -Copyright 2021 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1beta1 - -import ( - "fmt" - "strings" - - apierrors "k8s.io/apimachinery/pkg/api/errors" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/labels" - "k8s.io/apimachinery/pkg/runtime" - "k8s.io/apimachinery/pkg/util/sets" - "k8s.io/apimachinery/pkg/util/validation/field" - ctrl "sigs.k8s.io/controller-runtime" - "sigs.k8s.io/controller-runtime/pkg/client" - "sigs.k8s.io/controller-runtime/pkg/webhook" - "sigs.k8s.io/controller-runtime/pkg/webhook/admission" - - "sigs.k8s.io/cluster-api/feature" - "sigs.k8s.io/cluster-api/util/labels/format" - "sigs.k8s.io/cluster-api/util/version" -) - -func (m *MachineSet) SetupWebhookWithManager(mgr ctrl.Manager) error { - return ctrl.NewWebhookManagedBy(mgr). - For(m). - Complete() -} - -// +kubebuilder:webhook:verbs=create;update,path=/validate-cluster-x-k8s-io-v1beta1-machineset,mutating=false,failurePolicy=fail,matchPolicy=Equivalent,groups=cluster.x-k8s.io,resources=machinesets,versions=v1beta1,name=validation.machineset.cluster.x-k8s.io,sideEffects=None,admissionReviewVersions=v1;v1beta1 -// +kubebuilder:webhook:verbs=create;update,path=/mutate-cluster-x-k8s-io-v1beta1-machineset,mutating=true,failurePolicy=fail,matchPolicy=Equivalent,groups=cluster.x-k8s.io,resources=machinesets,versions=v1beta1,name=default.machineset.cluster.x-k8s.io,sideEffects=None,admissionReviewVersions=v1;v1beta1 - -var _ webhook.Defaulter = &MachineSet{} -var _ webhook.Validator = &MachineSet{} - -// Default sets default MachineSet field values. -func (m *MachineSet) Default() { - if m.Labels == nil { - m.Labels = make(map[string]string) - } - m.Labels[ClusterNameLabel] = m.Spec.ClusterName - - if m.Spec.DeletePolicy == "" { - randomPolicy := string(RandomMachineSetDeletePolicy) - m.Spec.DeletePolicy = randomPolicy - } - - if m.Spec.Selector.MatchLabels == nil { - m.Spec.Selector.MatchLabels = make(map[string]string) - } - - if m.Spec.Template.Labels == nil { - m.Spec.Template.Labels = make(map[string]string) - } - - if len(m.Spec.Selector.MatchLabels) == 0 && len(m.Spec.Selector.MatchExpressions) == 0 { - // Note: MustFormatValue is used here as the value of this label will be a hash if the MachineSet name is longer than 63 characters. - m.Spec.Selector.MatchLabels[MachineSetNameLabel] = format.MustFormatValue(m.Name) - m.Spec.Template.Labels[MachineSetNameLabel] = format.MustFormatValue(m.Name) - } - - if m.Spec.Template.Spec.Version != nil && !strings.HasPrefix(*m.Spec.Template.Spec.Version, "v") { - normalizedVersion := "v" + *m.Spec.Template.Spec.Version - m.Spec.Template.Spec.Version = &normalizedVersion - } -} - -// ValidateCreate implements webhook.Validator so a webhook will be registered for the type. -func (m *MachineSet) ValidateCreate() (admission.Warnings, error) { - return nil, m.validate(nil) -} - -// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type. -func (m *MachineSet) ValidateUpdate(old runtime.Object) (admission.Warnings, error) { - oldMS, ok := old.(*MachineSet) - if !ok { - return nil, apierrors.NewBadRequest(fmt.Sprintf("expected a MachineSet but got a %T", old)) - } - return nil, m.validate(oldMS) -} - -// ValidateDelete implements webhook.Validator so a webhook will be registered for the type. -func (m *MachineSet) ValidateDelete() (admission.Warnings, error) { - return nil, nil -} - -func (m *MachineSet) validate(old *MachineSet) error { - var allErrs field.ErrorList - specPath := field.NewPath("spec") - selector, err := metav1.LabelSelectorAsSelector(&m.Spec.Selector) - if err != nil { - allErrs = append( - allErrs, - field.Invalid( - specPath.Child("selector"), - m.Spec.Selector, - err.Error(), - ), - ) - } else if !selector.Matches(labels.Set(m.Spec.Template.Labels)) { - allErrs = append( - allErrs, - field.Invalid( - specPath.Child("template", "metadata", "labels"), - m.Spec.Template.ObjectMeta.Labels, - fmt.Sprintf("must match spec.selector %q", selector.String()), - ), - ) - } - - if feature.Gates.Enabled(feature.MachineSetPreflightChecks) { - if err := validateSkippedMachineSetPreflightChecks(m); err != nil { - allErrs = append(allErrs, err) - } - } - - if old != nil && old.Spec.ClusterName != m.Spec.ClusterName { - allErrs = append( - allErrs, - field.Forbidden( - specPath.Child("clusterName"), - "field is immutable", - ), - ) - } - - if m.Spec.Template.Spec.Version != nil { - if !version.KubeSemver.MatchString(*m.Spec.Template.Spec.Version) { - allErrs = append( - allErrs, - field.Invalid( - specPath.Child("template", "spec", "version"), - *m.Spec.Template.Spec.Version, - "must be a valid semantic version", - ), - ) - } - } - - if len(allErrs) == 0 { - return nil - } - - return apierrors.NewInvalid(GroupVersion.WithKind("MachineSet").GroupKind(), m.Name, allErrs) -} - -func validateSkippedMachineSetPreflightChecks(o client.Object) *field.Error { - if o == nil { - return nil - } - skip := o.GetAnnotations()[MachineSetSkipPreflightChecksAnnotation] - if skip == "" { - return nil - } - - supported := sets.New[MachineSetPreflightCheck]( - MachineSetPreflightCheckAll, - MachineSetPreflightCheckKubeadmVersionSkew, - MachineSetPreflightCheckKubernetesVersionSkew, - MachineSetPreflightCheckControlPlaneIsStable, - ) - - skippedList := strings.Split(skip, ",") - invalid := []MachineSetPreflightCheck{} - for i := range skippedList { - skipped := MachineSetPreflightCheck(strings.TrimSpace(skippedList[i])) - if !supported.Has(skipped) { - invalid = append(invalid, skipped) - } - } - if len(invalid) > 0 { - return field.Invalid( - field.NewPath("metadata", "annotations", MachineSetSkipPreflightChecksAnnotation), - invalid, - fmt.Sprintf("skipped preflight check(s) must be among: %v", sets.List(supported)), - ) - } - return nil -} diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/zz_generated.deepcopy.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/zz_generated.deepcopy.go index cc8fd8d59c..7eb9648459 100644 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/zz_generated.deepcopy.go +++ b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright The Kubernetes Authors. @@ -1440,6 +1439,163 @@ func (in *MachineList) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MachinePoolClass) DeepCopyInto(out *MachinePoolClass) { + *out = *in + in.Template.DeepCopyInto(&out.Template) + if in.FailureDomains != nil { + in, out := &in.FailureDomains, &out.FailureDomains + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.NamingStrategy != nil { + in, out := &in.NamingStrategy, &out.NamingStrategy + *out = new(MachinePoolClassNamingStrategy) + (*in).DeepCopyInto(*out) + } + if in.NodeDrainTimeout != nil { + in, out := &in.NodeDrainTimeout, &out.NodeDrainTimeout + *out = new(metav1.Duration) + **out = **in + } + if in.NodeVolumeDetachTimeout != nil { + in, out := &in.NodeVolumeDetachTimeout, &out.NodeVolumeDetachTimeout + *out = new(metav1.Duration) + **out = **in + } + if in.NodeDeletionTimeout != nil { + in, out := &in.NodeDeletionTimeout, &out.NodeDeletionTimeout + *out = new(metav1.Duration) + **out = **in + } + if in.MinReadySeconds != nil { + in, out := &in.MinReadySeconds, &out.MinReadySeconds + *out = new(int32) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MachinePoolClass. +func (in *MachinePoolClass) DeepCopy() *MachinePoolClass { + if in == nil { + return nil + } + out := new(MachinePoolClass) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MachinePoolClassNamingStrategy) DeepCopyInto(out *MachinePoolClassNamingStrategy) { + *out = *in + if in.Template != nil { + in, out := &in.Template, &out.Template + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MachinePoolClassNamingStrategy. +func (in *MachinePoolClassNamingStrategy) DeepCopy() *MachinePoolClassNamingStrategy { + if in == nil { + return nil + } + out := new(MachinePoolClassNamingStrategy) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MachinePoolClassTemplate) DeepCopyInto(out *MachinePoolClassTemplate) { + *out = *in + in.Metadata.DeepCopyInto(&out.Metadata) + in.Bootstrap.DeepCopyInto(&out.Bootstrap) + in.Infrastructure.DeepCopyInto(&out.Infrastructure) +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MachinePoolClassTemplate. +func (in *MachinePoolClassTemplate) DeepCopy() *MachinePoolClassTemplate { + if in == nil { + return nil + } + out := new(MachinePoolClassTemplate) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MachinePoolTopology) DeepCopyInto(out *MachinePoolTopology) { + *out = *in + in.Metadata.DeepCopyInto(&out.Metadata) + if in.FailureDomains != nil { + in, out := &in.FailureDomains, &out.FailureDomains + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.NodeDrainTimeout != nil { + in, out := &in.NodeDrainTimeout, &out.NodeDrainTimeout + *out = new(metav1.Duration) + **out = **in + } + if in.NodeVolumeDetachTimeout != nil { + in, out := &in.NodeVolumeDetachTimeout, &out.NodeVolumeDetachTimeout + *out = new(metav1.Duration) + **out = **in + } + if in.NodeDeletionTimeout != nil { + in, out := &in.NodeDeletionTimeout, &out.NodeDeletionTimeout + *out = new(metav1.Duration) + **out = **in + } + if in.MinReadySeconds != nil { + in, out := &in.MinReadySeconds, &out.MinReadySeconds + *out = new(int32) + **out = **in + } + if in.Replicas != nil { + in, out := &in.Replicas, &out.Replicas + *out = new(int32) + **out = **in + } + if in.Variables != nil { + in, out := &in.Variables, &out.Variables + *out = new(MachinePoolVariables) + (*in).DeepCopyInto(*out) + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MachinePoolTopology. +func (in *MachinePoolTopology) DeepCopy() *MachinePoolTopology { + if in == nil { + return nil + } + out := new(MachinePoolTopology) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MachinePoolVariables) DeepCopyInto(out *MachinePoolVariables) { + *out = *in + if in.Overrides != nil { + in, out := &in.Overrides, &out.Overrides + *out = make([]ClusterVariable, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MachinePoolVariables. +func (in *MachinePoolVariables) DeepCopy() *MachinePoolVariables { + if in == nil { + return nil + } + out := new(MachinePoolVariables) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *MachineRollingUpdateDeployment) DeepCopyInto(out *MachineRollingUpdateDeployment) { *out = *in @@ -1798,6 +1954,11 @@ func (in *PatchSelectorMatch) DeepCopyInto(out *PatchSelectorMatch) { *out = new(PatchSelectorMatchMachineDeploymentClass) (*in).DeepCopyInto(*out) } + if in.MachinePoolClass != nil { + in, out := &in.MachinePoolClass, &out.MachinePoolClass + *out = new(PatchSelectorMatchMachinePoolClass) + (*in).DeepCopyInto(*out) + } } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PatchSelectorMatch. @@ -1830,6 +1991,26 @@ func (in *PatchSelectorMatchMachineDeploymentClass) DeepCopy() *PatchSelectorMat return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *PatchSelectorMatchMachinePoolClass) DeepCopyInto(out *PatchSelectorMatchMachinePoolClass) { + *out = *in + if in.Names != nil { + in, out := &in.Names, &out.Names + *out = make([]string, len(*in)) + copy(*out, *in) + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PatchSelectorMatchMachinePoolClass. +func (in *PatchSelectorMatchMachinePoolClass) DeepCopy() *PatchSelectorMatchMachinePoolClass { + if in == nil { + return nil + } + out := new(PatchSelectorMatchMachinePoolClass) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *Topology) DeepCopyInto(out *Topology) { *out = *in @@ -1904,6 +2085,13 @@ func (in *WorkersClass) DeepCopyInto(out *WorkersClass) { (*in)[i].DeepCopyInto(&(*out)[i]) } } + if in.MachinePools != nil { + in, out := &in.MachinePools, &out.MachinePools + *out = make([]MachinePoolClass, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkersClass. @@ -1926,6 +2114,13 @@ func (in *WorkersTopology) DeepCopyInto(out *WorkersTopology) { (*in)[i].DeepCopyInto(&(*out)[i]) } } + if in.MachinePools != nil { + in, out := &in.MachinePools, &out.MachinePools + *out = make([]MachinePoolTopology, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkersTopology. diff --git a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/zz_generated.openapi.go b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/zz_generated.openapi.go index a54ed09374..d49f8303a8 100644 --- a/vendor/sigs.k8s.io/cluster-api/api/v1beta1/zz_generated.openapi.go +++ b/vendor/sigs.k8s.io/cluster-api/api/v1beta1/zz_generated.openapi.go @@ -75,6 +75,11 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "sigs.k8s.io/cluster-api/api/v1beta1.MachineHealthCheckStatus": schema_sigsk8sio_cluster_api_api_v1beta1_MachineHealthCheckStatus(ref), "sigs.k8s.io/cluster-api/api/v1beta1.MachineHealthCheckTopology": schema_sigsk8sio_cluster_api_api_v1beta1_MachineHealthCheckTopology(ref), "sigs.k8s.io/cluster-api/api/v1beta1.MachineList": schema_sigsk8sio_cluster_api_api_v1beta1_MachineList(ref), + "sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolClass": schema_sigsk8sio_cluster_api_api_v1beta1_MachinePoolClass(ref), + "sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolClassNamingStrategy": schema_sigsk8sio_cluster_api_api_v1beta1_MachinePoolClassNamingStrategy(ref), + "sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolClassTemplate": schema_sigsk8sio_cluster_api_api_v1beta1_MachinePoolClassTemplate(ref), + "sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolTopology": schema_sigsk8sio_cluster_api_api_v1beta1_MachinePoolTopology(ref), + "sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolVariables": schema_sigsk8sio_cluster_api_api_v1beta1_MachinePoolVariables(ref), "sigs.k8s.io/cluster-api/api/v1beta1.MachineRollingUpdateDeployment": schema_sigsk8sio_cluster_api_api_v1beta1_MachineRollingUpdateDeployment(ref), "sigs.k8s.io/cluster-api/api/v1beta1.MachineSet": schema_sigsk8sio_cluster_api_api_v1beta1_MachineSet(ref), "sigs.k8s.io/cluster-api/api/v1beta1.MachineSetList": schema_sigsk8sio_cluster_api_api_v1beta1_MachineSetList(ref), @@ -89,12 +94,12 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "sigs.k8s.io/cluster-api/api/v1beta1.PatchSelector": schema_sigsk8sio_cluster_api_api_v1beta1_PatchSelector(ref), "sigs.k8s.io/cluster-api/api/v1beta1.PatchSelectorMatch": schema_sigsk8sio_cluster_api_api_v1beta1_PatchSelectorMatch(ref), "sigs.k8s.io/cluster-api/api/v1beta1.PatchSelectorMatchMachineDeploymentClass": schema_sigsk8sio_cluster_api_api_v1beta1_PatchSelectorMatchMachineDeploymentClass(ref), + "sigs.k8s.io/cluster-api/api/v1beta1.PatchSelectorMatchMachinePoolClass": schema_sigsk8sio_cluster_api_api_v1beta1_PatchSelectorMatchMachinePoolClass(ref), "sigs.k8s.io/cluster-api/api/v1beta1.Topology": schema_sigsk8sio_cluster_api_api_v1beta1_Topology(ref), "sigs.k8s.io/cluster-api/api/v1beta1.UnhealthyCondition": schema_sigsk8sio_cluster_api_api_v1beta1_UnhealthyCondition(ref), "sigs.k8s.io/cluster-api/api/v1beta1.VariableSchema": schema_sigsk8sio_cluster_api_api_v1beta1_VariableSchema(ref), "sigs.k8s.io/cluster-api/api/v1beta1.WorkersClass": schema_sigsk8sio_cluster_api_api_v1beta1_WorkersClass(ref), "sigs.k8s.io/cluster-api/api/v1beta1.WorkersTopology": schema_sigsk8sio_cluster_api_api_v1beta1_WorkersTopology(ref), - "sigs.k8s.io/cluster-api/api/v1beta1.machineDeploymentDefaulter": schema_sigsk8sio_cluster_api_api_v1beta1_machineDeploymentDefaulter(ref), } } @@ -1919,7 +1924,7 @@ func schema_sigsk8sio_cluster_api_api_v1beta1_MachineDeploymentStrategy(ref comm Properties: map[string]spec.Schema{ "type": { SchemaProps: spec.SchemaProps{ - Description: "Type of deployment. Default is RollingUpdate.", + Description: "Type of deployment. Allowed values are RollingUpdate and OnDelete. The default is RollingUpdate.", Type: []string{"string"}, Format: "", }, @@ -2470,6 +2475,261 @@ func schema_sigsk8sio_cluster_api_api_v1beta1_MachineList(ref common.ReferenceCa } } +func schema_sigsk8sio_cluster_api_api_v1beta1_MachinePoolClass(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "MachinePoolClass serves as a template to define a pool of worker nodes of the cluster provisioned using `ClusterClass`.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "class": { + SchemaProps: spec.SchemaProps{ + Description: "Class denotes a type of machine pool present in the cluster, this name MUST be unique within a ClusterClass and can be referenced in the Cluster to create a managed MachinePool.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "template": { + SchemaProps: spec.SchemaProps{ + Description: "Template is a local struct containing a collection of templates for creation of MachinePools objects representing a pool of worker nodes.", + Default: map[string]interface{}{}, + Ref: ref("sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolClassTemplate"), + }, + }, + "failureDomains": { + SchemaProps: spec.SchemaProps{ + Description: "FailureDomains is the list of failure domains the MachinePool should be attached to. Must match a key in the FailureDomains map stored on the cluster object. NOTE: This value can be overridden while defining a Cluster.Topology using this MachinePoolClass.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "namingStrategy": { + SchemaProps: spec.SchemaProps{ + Description: "NamingStrategy allows changing the naming pattern used when creating the MachinePool.", + Ref: ref("sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolClassNamingStrategy"), + }, + }, + "nodeDrainTimeout": { + SchemaProps: spec.SchemaProps{ + Description: "NodeDrainTimeout is the total amount of time that the controller will spend on draining a node. The default value is 0, meaning that the node can be drained without any time limitations. NOTE: NodeDrainTimeout is different from `kubectl drain --timeout` NOTE: This value can be overridden while defining a Cluster.Topology using this MachinePoolClass.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "nodeVolumeDetachTimeout": { + SchemaProps: spec.SchemaProps{ + Description: "NodeVolumeDetachTimeout is the total amount of time that the controller will spend on waiting for all volumes to be detached. The default value is 0, meaning that the volumes can be detached without any time limitations. NOTE: This value can be overridden while defining a Cluster.Topology using this MachinePoolClass.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "nodeDeletionTimeout": { + SchemaProps: spec.SchemaProps{ + Description: "NodeDeletionTimeout defines how long the controller will attempt to delete the Node that the Machine hosts after the Machine Pool is marked for deletion. A duration of 0 will retry deletion indefinitely. Defaults to 10 seconds. NOTE: This value can be overridden while defining a Cluster.Topology using this MachinePoolClass.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "minReadySeconds": { + SchemaProps: spec.SchemaProps{ + Description: "Minimum number of seconds for which a newly created machine pool should be ready. Defaults to 0 (machine will be considered available as soon as it is ready) NOTE: This value can be overridden while defining a Cluster.Topology using this MachinePoolClass.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + Required: []string{"class", "template"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.Duration", "sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolClassNamingStrategy", "sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolClassTemplate"}, + } +} + +func schema_sigsk8sio_cluster_api_api_v1beta1_MachinePoolClassNamingStrategy(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "MachinePoolClassNamingStrategy defines the naming strategy for machine pool objects.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "template": { + SchemaProps: spec.SchemaProps{ + Description: "Template defines the template to use for generating the name of the MachinePool object. If not defined, it will fallback to `{{ .cluster.name }}-{{ .machinePool.topologyName }}-{{ .random }}`. If the templated string exceeds 63 characters, it will be trimmed to 58 characters and will get concatenated with a random suffix of length 5. The templating mechanism provides the following arguments: * `.cluster.name`: The name of the cluster object. * `.random`: A random alphanumeric string, without vowels, of length 5. * `.machinePool.topologyName`: The name of the MachinePool topology (Cluster.spec.topology.workers.machinePools[].name).", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_sigsk8sio_cluster_api_api_v1beta1_MachinePoolClassTemplate(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "MachinePoolClassTemplate defines how a MachinePool generated from a MachinePoolClass should look like.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Metadata is the metadata applied to the MachinePool. At runtime this metadata is merged with the corresponding metadata from the topology.", + Default: map[string]interface{}{}, + Ref: ref("sigs.k8s.io/cluster-api/api/v1beta1.ObjectMeta"), + }, + }, + "bootstrap": { + SchemaProps: spec.SchemaProps{ + Description: "Bootstrap contains the bootstrap template reference to be used for the creation of the Machines in the MachinePool.", + Default: map[string]interface{}{}, + Ref: ref("sigs.k8s.io/cluster-api/api/v1beta1.LocalObjectTemplate"), + }, + }, + "infrastructure": { + SchemaProps: spec.SchemaProps{ + Description: "Infrastructure contains the infrastructure template reference to be used for the creation of the MachinePool.", + Default: map[string]interface{}{}, + Ref: ref("sigs.k8s.io/cluster-api/api/v1beta1.LocalObjectTemplate"), + }, + }, + }, + Required: []string{"bootstrap", "infrastructure"}, + }, + }, + Dependencies: []string{ + "sigs.k8s.io/cluster-api/api/v1beta1.LocalObjectTemplate", "sigs.k8s.io/cluster-api/api/v1beta1.ObjectMeta"}, + } +} + +func schema_sigsk8sio_cluster_api_api_v1beta1_MachinePoolTopology(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "MachinePoolTopology specifies the different parameters for a pool of worker nodes in the topology. This pool of nodes is managed by a MachinePool object whose lifecycle is managed by the Cluster controller.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Metadata is the metadata applied to the MachinePool. At runtime this metadata is merged with the corresponding metadata from the ClusterClass.", + Default: map[string]interface{}{}, + Ref: ref("sigs.k8s.io/cluster-api/api/v1beta1.ObjectMeta"), + }, + }, + "class": { + SchemaProps: spec.SchemaProps{ + Description: "Class is the name of the MachinePoolClass used to create the pool of worker nodes. This should match one of the deployment classes defined in the ClusterClass object mentioned in the `Cluster.Spec.Class` field.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name is the unique identifier for this MachinePoolTopology. The value is used with other unique identifiers to create a MachinePool's Name (e.g. cluster's name, etc). In case the name is greater than the allowed maximum length, the values are hashed together.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "failureDomains": { + SchemaProps: spec.SchemaProps{ + Description: "FailureDomains is the list of failure domains the machine pool will be created in. Must match a key in the FailureDomains map stored on the cluster object.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "nodeDrainTimeout": { + SchemaProps: spec.SchemaProps{ + Description: "NodeDrainTimeout is the total amount of time that the controller will spend on draining a node. The default value is 0, meaning that the node can be drained without any time limitations. NOTE: NodeDrainTimeout is different from `kubectl drain --timeout`", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "nodeVolumeDetachTimeout": { + SchemaProps: spec.SchemaProps{ + Description: "NodeVolumeDetachTimeout is the total amount of time that the controller will spend on waiting for all volumes to be detached. The default value is 0, meaning that the volumes can be detached without any time limitations.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "nodeDeletionTimeout": { + SchemaProps: spec.SchemaProps{ + Description: "NodeDeletionTimeout defines how long the controller will attempt to delete the Node that the MachinePool hosts after the MachinePool is marked for deletion. A duration of 0 will retry deletion indefinitely. Defaults to 10 seconds.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "minReadySeconds": { + SchemaProps: spec.SchemaProps{ + Description: "Minimum number of seconds for which a newly created machine pool should be ready. Defaults to 0 (machine will be considered available as soon as it is ready)", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "replicas": { + SchemaProps: spec.SchemaProps{ + Description: "Replicas is the number of nodes belonging to this pool. If the value is nil, the MachinePool is created without the number of Replicas (defaulting to 1) and it's assumed that an external entity (like cluster autoscaler) is responsible for the management of this value.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "variables": { + SchemaProps: spec.SchemaProps{ + Description: "Variables can be used to customize the MachinePool through patches.", + Ref: ref("sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolVariables"), + }, + }, + }, + Required: []string{"class", "name"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.Duration", "sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolVariables", "sigs.k8s.io/cluster-api/api/v1beta1.ObjectMeta"}, + } +} + +func schema_sigsk8sio_cluster_api_api_v1beta1_MachinePoolVariables(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "MachinePoolVariables can be used to provide variables for a specific MachinePool.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "overrides": { + SchemaProps: spec.SchemaProps{ + Description: "Overrides can be used to override Cluster level variables.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("sigs.k8s.io/cluster-api/api/v1beta1.ClusterVariable"), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + "sigs.k8s.io/cluster-api/api/v1beta1.ClusterVariable"}, + } +} + func schema_sigsk8sio_cluster_api_api_v1beta1_MachineRollingUpdateDeployment(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -3140,11 +3400,17 @@ func schema_sigsk8sio_cluster_api_api_v1beta1_PatchSelectorMatch(ref common.Refe Ref: ref("sigs.k8s.io/cluster-api/api/v1beta1.PatchSelectorMatchMachineDeploymentClass"), }, }, + "machinePoolClass": { + SchemaProps: spec.SchemaProps{ + Description: "MachinePoolClass selects templates referenced in specific MachinePoolClasses in .spec.workers.machinePools.", + Ref: ref("sigs.k8s.io/cluster-api/api/v1beta1.PatchSelectorMatchMachinePoolClass"), + }, + }, }, }, }, Dependencies: []string{ - "sigs.k8s.io/cluster-api/api/v1beta1.PatchSelectorMatchMachineDeploymentClass"}, + "sigs.k8s.io/cluster-api/api/v1beta1.PatchSelectorMatchMachineDeploymentClass", "sigs.k8s.io/cluster-api/api/v1beta1.PatchSelectorMatchMachinePoolClass"}, } } @@ -3176,6 +3442,34 @@ func schema_sigsk8sio_cluster_api_api_v1beta1_PatchSelectorMatchMachineDeploymen } } +func schema_sigsk8sio_cluster_api_api_v1beta1_PatchSelectorMatchMachinePoolClass(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PatchSelectorMatchMachinePoolClass selects templates referenced in specific MachinePoolClasses in .spec.workers.machinePools.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "names": { + SchemaProps: spec.SchemaProps{ + Description: "Names selects templates by class names.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + } +} + func schema_sigsk8sio_cluster_api_api_v1beta1_Topology(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -3321,11 +3615,25 @@ func schema_sigsk8sio_cluster_api_api_v1beta1_WorkersClass(ref common.ReferenceC }, }, }, + "machinePools": { + SchemaProps: spec.SchemaProps{ + Description: "MachinePools is a list of machine pool classes that can be used to create a set of worker nodes.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolClass"), + }, + }, + }, + }, + }, }, }, }, Dependencies: []string{ - "sigs.k8s.io/cluster-api/api/v1beta1.MachineDeploymentClass"}, + "sigs.k8s.io/cluster-api/api/v1beta1.MachineDeploymentClass", "sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolClass"}, } } @@ -3350,31 +3658,24 @@ func schema_sigsk8sio_cluster_api_api_v1beta1_WorkersTopology(ref common.Referen }, }, }, - }, - }, - }, - Dependencies: []string{ - "sigs.k8s.io/cluster-api/api/v1beta1.MachineDeploymentTopology"}, - } -} - -func schema_sigsk8sio_cluster_api_api_v1beta1_machineDeploymentDefaulter(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "machineDeploymentDefaulter implements a defaulting webhook for MachineDeployment.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "decoder": { + "machinePools": { SchemaProps: spec.SchemaProps{ - Ref: ref("sigs.k8s.io/controller-runtime/pkg/webhook/admission.Decoder"), + Description: "MachinePools is a list of machine pools in the cluster.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolTopology"), + }, + }, + }, }, }, }, - Required: []string{"decoder"}, }, }, Dependencies: []string{ - "sigs.k8s.io/controller-runtime/pkg/webhook/admission.Decoder"}, + "sigs.k8s.io/cluster-api/api/v1beta1.MachineDeploymentTopology", "sigs.k8s.io/cluster-api/api/v1beta1.MachinePoolTopology"}, } } diff --git a/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/annotations.go b/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/annotations.go index eb818ee181..a9436dec3f 100644 --- a/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/annotations.go +++ b/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/annotations.go @@ -31,4 +31,14 @@ const ( // // It will help any validation webhook to take decision based on it. DeleteForMoveAnnotation = "clusterctl.cluster.x-k8s.io/delete-for-move" + + // BlockMoveAnnotation prevents the cluster move operation from starting if it is defined on at least one + // of the objects in scope. + // Provider controllers are expected to set the annotation on resources that cannot be instantaneously + // paused and remove the annotation when the resource has been actually paused. + // + // e.g. If this annotation is defined with any value on an InfraMachine resource to be moved when + // `clusterctl move` is invoked, then NO resources for ANY workload cluster will be created on the + // destination management cluster until the annotation is removed. + BlockMoveAnnotation = "clusterctl.cluster.x-k8s.io/block-move" ) diff --git a/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/groupversion_info.go b/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/groupversion_info.go index b5510698cd..dffa6182d0 100644 --- a/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/groupversion_info.go +++ b/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/groupversion_info.go @@ -20,17 +20,26 @@ limitations under the License. package v1alpha3 import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" - "sigs.k8s.io/controller-runtime/pkg/scheme" ) var ( // GroupVersion is group version used to register these objects. GroupVersion = schema.GroupVersion{Group: "clusterctl.cluster.x-k8s.io", Version: "v1alpha3"} - // SchemeBuilder is used to add go types to the GroupVersionKind scheme. - SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion} + // schemeBuilder is used to add go types to the GroupVersionKind scheme. + schemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) // AddToScheme adds the types in this group-version to the given scheme. - AddToScheme = SchemeBuilder.AddToScheme + AddToScheme = schemeBuilder.AddToScheme + + objectTypes = []runtime.Object{} ) + +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(GroupVersion, objectTypes...) + metav1.AddToGroupVersion(scheme, GroupVersion) + return nil +} diff --git a/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/metadata_type.go b/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/metadata_type.go index 0eacecbf43..e2ab85a630 100644 --- a/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/metadata_type.go +++ b/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/metadata_type.go @@ -17,7 +17,7 @@ limitations under the License. package v1alpha3 import ( - "github.com/blang/semver" + "github.com/blang/semver/v4" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/util/version" ) @@ -54,7 +54,7 @@ func (rs ReleaseSeries) newer(release ReleaseSeries) bool { } func init() { - SchemeBuilder.Register(&Metadata{}) + objectTypes = append(objectTypes, &Metadata{}) } // GetReleaseSeriesForVersion returns the release series for a given version. diff --git a/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/provider_type.go b/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/provider_type.go index 824861c154..0c923646d6 100644 --- a/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/provider_type.go +++ b/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/provider_type.go @@ -222,5 +222,5 @@ func (l *ProviderList) filterBy(predicate func(p Provider) bool) []Provider { } func init() { - SchemeBuilder.Register(&Provider{}, &ProviderList{}) + objectTypes = append(objectTypes, &Provider{}, &ProviderList{}) } diff --git a/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/zz_generated.deepcopy.go b/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/zz_generated.deepcopy.go index aa0625d17f..47ff729662 100644 --- a/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/zz_generated.deepcopy.go +++ b/vendor/sigs.k8s.io/cluster-api/cmd/clusterctl/api/v1alpha3/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright The Kubernetes Authors. @@ -22,7 +21,7 @@ limitations under the License. package v1alpha3 import ( - runtime "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" ) // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. diff --git a/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/.import-restrictions b/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/.import-restrictions new file mode 100644 index 0000000000..a2e1dfd081 --- /dev/null +++ b/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/.import-restrictions @@ -0,0 +1,5 @@ +rules: + - selectorRegexp: sigs[.]k8s[.]io/controller-runtime + allowedPrefixes: [] + forbiddenPrefixes: + - "sigs.k8s.io/controller-runtime" diff --git a/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/clusterresourceset_types.go b/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/clusterresourceset_types.go index e64dccd297..2800bf1905 100644 --- a/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/clusterresourceset_types.go +++ b/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/clusterresourceset_types.go @@ -140,5 +140,5 @@ type ClusterResourceSetList struct { } func init() { - SchemeBuilder.Register(&ClusterResourceSet{}, &ClusterResourceSetList{}) + objectTypes = append(objectTypes, &ClusterResourceSet{}, &ClusterResourceSetList{}) } diff --git a/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/clusterresourceset_webhook.go b/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/clusterresourceset_webhook.go deleted file mode 100644 index 61f8f6dc5c..0000000000 --- a/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/clusterresourceset_webhook.go +++ /dev/null @@ -1,118 +0,0 @@ -/* -Copyright 2021 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1beta1 - -import ( - "fmt" - "reflect" - - apierrors "k8s.io/apimachinery/pkg/api/errors" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime" - "k8s.io/apimachinery/pkg/util/validation/field" - ctrl "sigs.k8s.io/controller-runtime" - "sigs.k8s.io/controller-runtime/pkg/webhook" - "sigs.k8s.io/controller-runtime/pkg/webhook/admission" - - "sigs.k8s.io/cluster-api/feature" -) - -func (m *ClusterResourceSet) SetupWebhookWithManager(mgr ctrl.Manager) error { - return ctrl.NewWebhookManagedBy(mgr). - For(m). - Complete() -} - -// +kubebuilder:webhook:verbs=create;update,path=/validate-addons-cluster-x-k8s-io-v1beta1-clusterresourceset,mutating=false,failurePolicy=fail,matchPolicy=Equivalent,groups=addons.cluster.x-k8s.io,resources=clusterresourcesets,versions=v1beta1,name=validation.clusterresourceset.addons.cluster.x-k8s.io,sideEffects=None,admissionReviewVersions=v1;v1beta1 -// +kubebuilder:webhook:verbs=create;update,path=/mutate-addons-cluster-x-k8s-io-v1beta1-clusterresourceset,mutating=true,failurePolicy=fail,matchPolicy=Equivalent,groups=addons.cluster.x-k8s.io,resources=clusterresourcesets,versions=v1beta1,name=default.clusterresourceset.addons.cluster.x-k8s.io,sideEffects=None,admissionReviewVersions=v1;v1beta1 - -var _ webhook.Defaulter = &ClusterResourceSet{} -var _ webhook.Validator = &ClusterResourceSet{} - -// Default implements webhook.Defaulter so a webhook will be registered for the type. -func (m *ClusterResourceSet) Default() { - // ClusterResourceSet Strategy defaults to ApplyOnce. - if m.Spec.Strategy == "" { - m.Spec.Strategy = string(ClusterResourceSetStrategyApplyOnce) - } -} - -// ValidateCreate implements webhook.Validator so a webhook will be registered for the type. -func (m *ClusterResourceSet) ValidateCreate() (admission.Warnings, error) { - return nil, m.validate(nil) -} - -// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type. -func (m *ClusterResourceSet) ValidateUpdate(old runtime.Object) (admission.Warnings, error) { - oldCRS, ok := old.(*ClusterResourceSet) - if !ok { - return nil, apierrors.NewBadRequest(fmt.Sprintf("expected a ClusterResourceSet but got a %T", old)) - } - return nil, m.validate(oldCRS) -} - -// ValidateDelete implements webhook.Validator so a webhook will be registered for the type. -func (m *ClusterResourceSet) ValidateDelete() (admission.Warnings, error) { - return nil, nil -} - -func (m *ClusterResourceSet) validate(old *ClusterResourceSet) error { - // NOTE: ClusterResourceSet is behind ClusterResourceSet feature gate flag; the web hook - // must prevent creating new objects when the feature flag is disabled. - if !feature.Gates.Enabled(feature.ClusterResourceSet) { - return field.Forbidden( - field.NewPath("spec"), - "can be set only if the ClusterResourceSet feature flag is enabled", - ) - } - var allErrs field.ErrorList - // Validate selector parses as Selector - selector, err := metav1.LabelSelectorAsSelector(&m.Spec.ClusterSelector) - if err != nil { - allErrs = append( - allErrs, - field.Invalid(field.NewPath("spec", "clusterSelector"), m.Spec.ClusterSelector, err.Error()), - ) - } - - // Validate that the selector isn't empty as null selectors do not select any objects. - if selector != nil && selector.Empty() { - allErrs = append( - allErrs, - field.Invalid(field.NewPath("spec", "clusterSelector"), m.Spec.ClusterSelector, "selector must not be empty"), - ) - } - - if old != nil && old.Spec.Strategy != "" && old.Spec.Strategy != m.Spec.Strategy { - allErrs = append( - allErrs, - field.Invalid(field.NewPath("spec", "strategy"), m.Spec.Strategy, "field is immutable"), - ) - } - - if old != nil && !reflect.DeepEqual(old.Spec.ClusterSelector, m.Spec.ClusterSelector) { - allErrs = append( - allErrs, - field.Invalid(field.NewPath("spec", "clusterSelector"), m.Spec.ClusterSelector, "field is immutable"), - ) - } - - if len(allErrs) == 0 { - return nil - } - return apierrors.NewInvalid(GroupVersion.WithKind("ClusterResourceSet").GroupKind(), m.Name, allErrs) -} diff --git a/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/clusterresourcesetbinding_types.go b/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/clusterresourcesetbinding_types.go index d58c46461c..37591da520 100644 --- a/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/clusterresourcesetbinding_types.go +++ b/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/clusterresourcesetbinding_types.go @@ -20,8 +20,7 @@ import ( "reflect" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - - "sigs.k8s.io/cluster-api/util" + "k8s.io/apimachinery/pkg/runtime/schema" ) // ANCHOR: ResourceBinding @@ -97,7 +96,20 @@ func (c *ClusterResourceSetBinding) GetOrCreateBinding(clusterResourceSet *Clust return binding } +// RemoveBinding removes the ClusterResourceSet from the ClusterResourceSetBinding Bindings list. +func (c *ClusterResourceSetBinding) RemoveBinding(clusterResourceSet *ClusterResourceSet) { + for i, binding := range c.Spec.Bindings { + if binding.ClusterResourceSetName == clusterResourceSet.Name { + copy(c.Spec.Bindings[i:], c.Spec.Bindings[i+1:]) + c.Spec.Bindings = c.Spec.Bindings[:len(c.Spec.Bindings)-1] + break + } + } +} + // DeleteBinding removes the ClusterResourceSet from the ClusterResourceSetBinding Bindings list. +// +// Deprecated: This function is deprecated and will be removed in an upcoming release of Cluster API. func (c *ClusterResourceSetBinding) DeleteBinding(clusterResourceSet *ClusterResourceSet) { for i, binding := range c.Spec.Bindings { if binding.ClusterResourceSetName == clusterResourceSet.Name { @@ -106,13 +118,53 @@ func (c *ClusterResourceSetBinding) DeleteBinding(clusterResourceSet *ClusterRes break } } - c.OwnerReferences = util.RemoveOwnerRef(c.GetOwnerReferences(), metav1.OwnerReference{ + c.OwnerReferences = removeOwnerRef(c.GetOwnerReferences(), metav1.OwnerReference{ APIVersion: clusterResourceSet.APIVersion, Kind: clusterResourceSet.Kind, Name: clusterResourceSet.Name, }) } +// removeOwnerRef returns the slice of owner references after removing the supplied owner ref. +// Note: removeOwnerRef ignores apiVersion and UID. It will remove the passed ownerReference where it matches Name, Group and Kind. +// +// Deprecated: This function is deprecated and will be removed in an upcoming release of Cluster API. +func removeOwnerRef(ownerReferences []metav1.OwnerReference, inputRef metav1.OwnerReference) []metav1.OwnerReference { + if index := indexOwnerRef(ownerReferences, inputRef); index != -1 { + return append(ownerReferences[:index], ownerReferences[index+1:]...) + } + return ownerReferences +} + +// indexOwnerRef returns the index of the owner reference in the slice if found, or -1. +// +// Deprecated: This function is deprecated and will be removed in an upcoming release of Cluster API. +func indexOwnerRef(ownerReferences []metav1.OwnerReference, ref metav1.OwnerReference) int { + for index, r := range ownerReferences { + if referSameObject(r, ref) { + return index + } + } + return -1 +} + +// Returns true if a and b point to the same object based on Group, Kind and Name. +// +// Deprecated: This function is deprecated and will be removed in an upcoming release of Cluster API. +func referSameObject(a, b metav1.OwnerReference) bool { + aGV, err := schema.ParseGroupVersion(a.APIVersion) + if err != nil { + return false + } + + bGV, err := schema.ParseGroupVersion(b.APIVersion) + if err != nil { + return false + } + + return aGV.Group == bGV.Group && a.Kind == b.Kind && a.Name == b.Name +} + // +kubebuilder:object:root=true // +kubebuilder:resource:path=clusterresourcesetbindings,scope=Namespaced,categories=cluster-api // +kubebuilder:subresource:status @@ -152,5 +204,5 @@ type ClusterResourceSetBindingList struct { } func init() { - SchemeBuilder.Register(&ClusterResourceSetBinding{}, &ClusterResourceSetBindingList{}) + objectTypes = append(objectTypes, &ClusterResourceSetBinding{}, &ClusterResourceSetBindingList{}) } diff --git a/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/clusterresourcesetbinding_webhook.go b/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/clusterresourcesetbinding_webhook.go deleted file mode 100644 index 1f51795173..0000000000 --- a/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/clusterresourcesetbinding_webhook.go +++ /dev/null @@ -1,79 +0,0 @@ -/* -Copyright 2022 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1beta1 - -import ( - "fmt" - - apierrors "k8s.io/apimachinery/pkg/api/errors" - "k8s.io/apimachinery/pkg/runtime" - "k8s.io/apimachinery/pkg/util/validation/field" - ctrl "sigs.k8s.io/controller-runtime" - "sigs.k8s.io/controller-runtime/pkg/webhook" - "sigs.k8s.io/controller-runtime/pkg/webhook/admission" - - "sigs.k8s.io/cluster-api/feature" -) - -func (c *ClusterResourceSetBinding) SetupWebhookWithManager(mgr ctrl.Manager) error { - return ctrl.NewWebhookManagedBy(mgr). - For(c). - Complete() -} - -// +kubebuilder:webhook:verbs=create;update,path=/validate-addons-cluster-x-k8s-io-v1beta1-clusterresourcesetbinding,mutating=false,failurePolicy=fail,matchPolicy=Equivalent,groups=addons.cluster.x-k8s.io,resources=clusterresourcesetbindings,versions=v1beta1,name=validation.clusterresourcesetbinding.addons.cluster.x-k8s.io,sideEffects=None,admissionReviewVersions=v1;v1beta1 - -var _ webhook.Validator = &ClusterResourceSetBinding{} - -// ValidateCreate implements webhook.Validator so a webhook will be registered for the type. -func (c *ClusterResourceSetBinding) ValidateCreate() (admission.Warnings, error) { - return nil, c.validate(nil) -} - -// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type. -func (c *ClusterResourceSetBinding) ValidateUpdate(old runtime.Object) (admission.Warnings, error) { - oldBinding, ok := old.(*ClusterResourceSetBinding) - if !ok { - return nil, apierrors.NewBadRequest(fmt.Sprintf("expected a ClusterResourceSetBinding but got a %T", old)) - } - return nil, c.validate(oldBinding) -} - -// ValidateDelete implements webhook.Validator so a webhook will be registered for the type. -func (c *ClusterResourceSetBinding) ValidateDelete() (admission.Warnings, error) { - return nil, nil -} - -func (c *ClusterResourceSetBinding) validate(old *ClusterResourceSetBinding) error { - // NOTE: ClusterResourceSet is behind ClusterResourceSet feature gate flag; the web hook - // must prevent creating new objects in case the feature flag is disabled. - if !feature.Gates.Enabled(feature.ClusterResourceSet) { - return field.Forbidden( - field.NewPath("spec"), - "can be set only if the ClusterResourceSet feature flag is enabled", - ) - } - var allErrs field.ErrorList - if old != nil && old.Spec.ClusterName != "" && old.Spec.ClusterName != c.Spec.ClusterName { - allErrs = append(allErrs, - field.Invalid(field.NewPath("spec", "clusterName"), c.Spec.ClusterName, "field is immutable")) - } - if len(allErrs) == 0 { - return nil - } - return apierrors.NewInvalid(GroupVersion.WithKind("ClusterResourceSetBinding").GroupKind(), c.Name, allErrs) -} diff --git a/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/groupversion_info.go b/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/groupversion_info.go index c21f20bded..f02006147e 100644 --- a/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/groupversion_info.go +++ b/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/groupversion_info.go @@ -20,17 +20,26 @@ limitations under the License. package v1beta1 import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" - "sigs.k8s.io/controller-runtime/pkg/scheme" ) var ( // GroupVersion is group version used to register these objects. GroupVersion = schema.GroupVersion{Group: "addons.cluster.x-k8s.io", Version: "v1beta1"} - // SchemeBuilder is used to add go types to the GroupVersionKind scheme. - SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion} + // schemeBuilder is used to add go types to the GroupVersionKind scheme. + schemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) // AddToScheme adds the types in this group-version to the given scheme. - AddToScheme = SchemeBuilder.AddToScheme + AddToScheme = schemeBuilder.AddToScheme + + objectTypes = []runtime.Object{} ) + +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(GroupVersion, objectTypes...) + metav1.AddToGroupVersion(scheme, GroupVersion) + return nil +} diff --git a/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/zz_generated.deepcopy.go b/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/zz_generated.deepcopy.go index 7f6788462f..eaee808480 100644 --- a/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/zz_generated.deepcopy.go +++ b/vendor/sigs.k8s.io/cluster-api/exp/addons/api/v1beta1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright The Kubernetes Authors. diff --git a/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/.import-restrictions b/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/.import-restrictions new file mode 100644 index 0000000000..a2e1dfd081 --- /dev/null +++ b/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/.import-restrictions @@ -0,0 +1,5 @@ +rules: + - selectorRegexp: sigs[.]k8s[.]io/controller-runtime + allowedPrefixes: [] + forbiddenPrefixes: + - "sigs.k8s.io/controller-runtime" diff --git a/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/groupversion_info.go b/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/groupversion_info.go index c92eaed360..fd5c24e955 100644 --- a/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/groupversion_info.go +++ b/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/groupversion_info.go @@ -20,17 +20,26 @@ limitations under the License. package v1beta1 import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" - "sigs.k8s.io/controller-runtime/pkg/scheme" ) var ( // GroupVersion is group version used to register these objects. GroupVersion = schema.GroupVersion{Group: "cluster.x-k8s.io", Version: "v1beta1"} - // SchemeBuilder is used to add go types to the GroupVersionKind scheme. - SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion} + // schemeBuilder is used to add go types to the GroupVersionKind scheme. + schemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) // AddToScheme adds the types in this group-version to the given scheme. - AddToScheme = SchemeBuilder.AddToScheme + AddToScheme = schemeBuilder.AddToScheme + + objectTypes = []runtime.Object{} ) + +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(GroupVersion, objectTypes...) + metav1.AddToGroupVersion(scheme, GroupVersion) + return nil +} diff --git a/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/machinepool_types.go b/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/machinepool_types.go index 3d08de8260..a2fc2957ba 100644 --- a/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/machinepool_types.go +++ b/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/machinepool_types.go @@ -249,5 +249,5 @@ type MachinePoolList struct { } func init() { - SchemeBuilder.Register(&MachinePool{}, &MachinePoolList{}) + objectTypes = append(objectTypes, &MachinePool{}, &MachinePoolList{}) } diff --git a/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/machinepool_webhook.go b/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/machinepool_webhook.go deleted file mode 100644 index 58dc05ef77..0000000000 --- a/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/machinepool_webhook.go +++ /dev/null @@ -1,159 +0,0 @@ -/* -Copyright 2021 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1beta1 - -import ( - "fmt" - "strings" - - apierrors "k8s.io/apimachinery/pkg/api/errors" - "k8s.io/apimachinery/pkg/runtime" - "k8s.io/apimachinery/pkg/util/validation/field" - "k8s.io/utils/pointer" - ctrl "sigs.k8s.io/controller-runtime" - "sigs.k8s.io/controller-runtime/pkg/webhook" - "sigs.k8s.io/controller-runtime/pkg/webhook/admission" - - clusterv1 "sigs.k8s.io/cluster-api/api/v1beta1" - "sigs.k8s.io/cluster-api/feature" - "sigs.k8s.io/cluster-api/util/version" -) - -func (m *MachinePool) SetupWebhookWithManager(mgr ctrl.Manager) error { - return ctrl.NewWebhookManagedBy(mgr). - For(m). - Complete() -} - -// +kubebuilder:webhook:verbs=create;update,path=/validate-cluster-x-k8s-io-v1beta1-machinepool,mutating=false,failurePolicy=fail,matchPolicy=Equivalent,groups=cluster.x-k8s.io,resources=machinepools,versions=v1beta1,name=validation.machinepool.cluster.x-k8s.io,sideEffects=None,admissionReviewVersions=v1;v1beta1 -// +kubebuilder:webhook:verbs=create;update,path=/mutate-cluster-x-k8s-io-v1beta1-machinepool,mutating=true,failurePolicy=fail,matchPolicy=Equivalent,groups=cluster.x-k8s.io,resources=machinepools,versions=v1beta1,name=default.machinepool.cluster.x-k8s.io,sideEffects=None,admissionReviewVersions=v1;v1beta1 - -var _ webhook.Defaulter = &MachinePool{} -var _ webhook.Validator = &MachinePool{} - -// Default implements webhook.Defaulter so a webhook will be registered for the type. -func (m *MachinePool) Default() { - if m.Labels == nil { - m.Labels = make(map[string]string) - } - m.Labels[clusterv1.ClusterNameLabel] = m.Spec.ClusterName - - if m.Spec.Replicas == nil { - m.Spec.Replicas = pointer.Int32(1) - } - - if m.Spec.MinReadySeconds == nil { - m.Spec.MinReadySeconds = pointer.Int32(0) - } - - if m.Spec.Template.Spec.Bootstrap.ConfigRef != nil && m.Spec.Template.Spec.Bootstrap.ConfigRef.Namespace == "" { - m.Spec.Template.Spec.Bootstrap.ConfigRef.Namespace = m.Namespace - } - - if m.Spec.Template.Spec.InfrastructureRef.Namespace == "" { - m.Spec.Template.Spec.InfrastructureRef.Namespace = m.Namespace - } - - // tolerate version strings without a "v" prefix: prepend it if it's not there. - if m.Spec.Template.Spec.Version != nil && !strings.HasPrefix(*m.Spec.Template.Spec.Version, "v") { - normalizedVersion := "v" + *m.Spec.Template.Spec.Version - m.Spec.Template.Spec.Version = &normalizedVersion - } -} - -// ValidateCreate implements webhook.Validator so a webhook will be registered for the type. -func (m *MachinePool) ValidateCreate() (admission.Warnings, error) { - return nil, m.validate(nil) -} - -// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type. -func (m *MachinePool) ValidateUpdate(old runtime.Object) (admission.Warnings, error) { - oldMP, ok := old.(*MachinePool) - if !ok { - return nil, apierrors.NewBadRequest(fmt.Sprintf("expected a MachinePool but got a %T", old)) - } - return nil, m.validate(oldMP) -} - -// ValidateDelete implements webhook.Validator so a webhook will be registered for the type. -func (m *MachinePool) ValidateDelete() (admission.Warnings, error) { - return nil, m.validate(nil) -} - -func (m *MachinePool) validate(old *MachinePool) error { - // NOTE: MachinePool is behind MachinePool feature gate flag; the web hook - // must prevent creating new objects when the feature flag is disabled. - specPath := field.NewPath("spec") - if !feature.Gates.Enabled(feature.MachinePool) { - return field.Forbidden( - specPath, - "can be set only if the MachinePool feature flag is enabled", - ) - } - var allErrs field.ErrorList - if m.Spec.Template.Spec.Bootstrap.ConfigRef == nil && m.Spec.Template.Spec.Bootstrap.DataSecretName == nil { - allErrs = append( - allErrs, - field.Required( - specPath.Child("template", "spec", "bootstrap", "data"), - "expected either spec.bootstrap.dataSecretName or spec.bootstrap.configRef to be populated", - ), - ) - } - - if m.Spec.Template.Spec.Bootstrap.ConfigRef != nil && m.Spec.Template.Spec.Bootstrap.ConfigRef.Namespace != m.Namespace { - allErrs = append( - allErrs, - field.Invalid( - specPath.Child("template", "spec", "bootstrap", "configRef", "namespace"), - m.Spec.Template.Spec.Bootstrap.ConfigRef.Namespace, - "must match metadata.namespace", - ), - ) - } - - if m.Spec.Template.Spec.InfrastructureRef.Namespace != m.Namespace { - allErrs = append( - allErrs, - field.Invalid( - specPath.Child("infrastructureRef", "namespace"), - m.Spec.Template.Spec.InfrastructureRef.Namespace, - "must match metadata.namespace", - ), - ) - } - - if old != nil && old.Spec.ClusterName != m.Spec.ClusterName { - allErrs = append( - allErrs, - field.Forbidden( - specPath.Child("clusterName"), - "field is immutable"), - ) - } - - if m.Spec.Template.Spec.Version != nil { - if !version.KubeSemver.MatchString(*m.Spec.Template.Spec.Version) { - allErrs = append(allErrs, field.Invalid(specPath.Child("template", "spec", "version"), *m.Spec.Template.Spec.Version, "must be a valid semantic version")) - } - } - - if len(allErrs) == 0 { - return nil - } - return apierrors.NewInvalid(GroupVersion.WithKind("MachinePool").GroupKind(), m.Name, allErrs) -} diff --git a/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/zz_generated.deepcopy.go b/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/zz_generated.deepcopy.go index 164680e089..68cfe8fc8c 100644 --- a/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/zz_generated.deepcopy.go +++ b/vendor/sigs.k8s.io/cluster-api/exp/api/v1beta1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright The Kubernetes Authors. diff --git a/vendor/sigs.k8s.io/cluster-api/util/labels/format/helpers.go b/vendor/sigs.k8s.io/cluster-api/util/labels/format/helpers.go deleted file mode 100644 index 500f4225f6..0000000000 --- a/vendor/sigs.k8s.io/cluster-api/util/labels/format/helpers.go +++ /dev/null @@ -1,52 +0,0 @@ -/* -Copyright 2021 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package format contains functions to format and compare formatted values used in Kubernetes labels. -package format - -import ( - "encoding/base64" - "fmt" - "hash/fnv" - - "k8s.io/apimachinery/pkg/util/validation" -) - -// MustFormatValue returns the passed inputLabelValue if it meets the standards for a Kubernetes label value. -// If the name is not a valid label value this function returns a hash which meets the requirements. -func MustFormatValue(str string) string { - // a valid Kubernetes label value must: - // - be less than 64 characters long. - // - be an empty string OR consist of alphanumeric characters, '-', '_' or '.'. - // - start and end with an alphanumeric character - if len(validation.IsValidLabelValue(str)) == 0 { - return str - } - hasher := fnv.New32a() - _, err := hasher.Write([]byte(str)) - if err != nil { - // At time of writing the implementation of fnv's Write function can never return an error. - // If this changes in a future go version this function will panic. - panic(err) - } - return fmt.Sprintf("hash_%s_z", base64.URLEncoding.WithPadding(base64.NoPadding).EncodeToString(hasher.Sum(nil))) -} - -// MustEqualValue returns true if the actualLabelValue equals either the inputLabelValue or the hashed -// value of the inputLabelValue. -func MustEqualValue(str, labelValue string) bool { - return labelValue == MustFormatValue(str) -} diff --git a/vendor/sigs.k8s.io/cluster-api/util/patch/patch.go b/vendor/sigs.k8s.io/cluster-api/util/patch/patch.go index a6559f6cd4..dcf693495e 100644 --- a/vendor/sigs.k8s.io/cluster-api/util/patch/patch.go +++ b/vendor/sigs.k8s.io/cluster-api/util/patch/patch.go @@ -48,7 +48,8 @@ type Helper struct { isConditionsSetter bool } -// NewHelper returns an initialized Helper. +// NewHelper returns an initialized Helper. Use NewHelper before changing +// obj. After changing obj use Helper.Patch to persist your changes. func NewHelper(obj client.Object, crClient client.Client) (*Helper, error) { // Return early if the object is nil. if util.IsNil(obj) { diff --git a/vendor/sigs.k8s.io/cluster-api/util/retry.go b/vendor/sigs.k8s.io/cluster-api/util/retry.go index 378476a0bd..fe87875e07 100644 --- a/vendor/sigs.k8s.io/cluster-api/util/retry.go +++ b/vendor/sigs.k8s.io/cluster-api/util/retry.go @@ -46,21 +46,3 @@ func Retry(fn wait.ConditionFunc, initialBackoffSec int) error { } return nil } - -// Poll tries a condition func until it returns true, an error, or the timeout -// is reached. -// -// Deprecated: This function has been deprecated and will be removed in a future release. -// Please use utils from "k8s.io/apimachinery/pkg/util/wait" instead. -func Poll(interval, timeout time.Duration, condition wait.ConditionFunc) error { - return wait.Poll(interval, timeout, condition) -} - -// PollImmediate tries a condition func until it returns true, an error, or the timeout -// is reached. -// -// Deprecated: This function has been deprecated and will be removed in a future release. -// Please use utils from "k8s.io/apimachinery/pkg/util/wait" instead. -func PollImmediate(interval, timeout time.Duration, condition wait.ConditionFunc) error { - return wait.PollImmediate(interval, timeout, condition) -} diff --git a/vendor/sigs.k8s.io/cluster-api/util/util.go b/vendor/sigs.k8s.io/cluster-api/util/util.go index 93267f160e..d72947ecfd 100644 --- a/vendor/sigs.k8s.io/cluster-api/util/util.go +++ b/vendor/sigs.k8s.io/cluster-api/util/util.go @@ -27,7 +27,7 @@ import ( "strings" "time" - "github.com/blang/semver" + "github.com/blang/semver/v4" "github.com/pkg/errors" corev1 "k8s.io/api/core/v1" apiextensionsv1 "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1" @@ -467,56 +467,6 @@ func (k KubeAwareAPIVersions) Less(i, j int) bool { return k8sversion.CompareKubeAwareVersionStrings(k[i], k[j]) < 0 } -// ClusterToObjectsMapper returns a mapper function that gets a cluster and lists all objects for the object passed in -// and returns a list of requests. -// NB: The objects are required to have `clusterv1.ClusterNameLabel` applied. -// -// Deprecated: This function is deprecated and will be removed in a future release, use ClusterToTypedObjectsMapper instead. -// The problem with this function is that it uses UnstructuredList to retrieve objects, with the default client configuration -// this will lead to uncached List calls, which is a major performance issue. -func ClusterToObjectsMapper(c client.Client, ro client.ObjectList, scheme *runtime.Scheme) (handler.MapFunc, error) { - gvk, err := apiutil.GVKForObject(ro, scheme) - if err != nil { - return nil, err - } - - isNamespaced, err := isAPINamespaced(gvk, c.RESTMapper()) - if err != nil { - return nil, err - } - - return func(ctx context.Context, o client.Object) []ctrl.Request { - cluster, ok := o.(*clusterv1.Cluster) - if !ok { - return nil - } - - listOpts := []client.ListOption{ - client.MatchingLabels{ - clusterv1.ClusterNameLabel: cluster.Name, - }, - } - - if isNamespaced { - listOpts = append(listOpts, client.InNamespace(cluster.Namespace)) - } - - list := &unstructured.UnstructuredList{} - list.SetGroupVersionKind(gvk) - if err := c.List(ctx, list, listOpts...); err != nil { - return nil - } - - results := []ctrl.Request{} - for _, obj := range list.Items { - results = append(results, ctrl.Request{ - NamespacedName: client.ObjectKey{Namespace: obj.GetNamespace(), Name: obj.GetName()}, - }) - } - return results - }, nil -} - // ClusterToTypedObjectsMapper returns a mapper function that gets a cluster and lists all objects for the object passed in // and returns a list of requests. // Note: This function uses the passed in typed ObjectList and thus with the default client configuration all list calls diff --git a/vendor/sigs.k8s.io/cluster-api/util/version/version.go b/vendor/sigs.k8s.io/cluster-api/util/version/version.go deleted file mode 100644 index 277ed61050..0000000000 --- a/vendor/sigs.k8s.io/cluster-api/util/version/version.go +++ /dev/null @@ -1,238 +0,0 @@ -/* -Copyright 2021 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package version implements version handling. -package version - -import ( - "regexp" - "strconv" - "strings" - - "github.com/blang/semver" - "github.com/pkg/errors" -) - -var ( - // KubeSemver is the regex for Kubernetes versions. It requires the "v" prefix. - KubeSemver = regexp.MustCompile(`^v(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)([-0-9a-zA-Z_\.+]*)?$`) - // KubeSemverTolerant is the regex for Kubernetes versions with an optional "v" prefix. - KubeSemverTolerant = regexp.MustCompile(`^v?(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)([-0-9a-zA-Z_\.+]*)?$`) -) - -// ParseMajorMinorPatch returns a semver.Version from the string provided -// by looking only at major.minor.patch and stripping everything else out. -// It requires the version to have a "v" prefix. -func ParseMajorMinorPatch(version string) (semver.Version, error) { - return parseMajorMinorPatch(version, false) -} - -// ParseMajorMinorPatchTolerant returns a semver.Version from the string provided -// by looking only at major.minor.patch and stripping everything else out. -// It does not require the version to have a "v" prefix. -func ParseMajorMinorPatchTolerant(version string) (semver.Version, error) { - return parseMajorMinorPatch(version, true) -} - -// parseMajorMinorPatch returns a semver.Version from the string provided -// by looking only at major.minor.patch and stripping everything else out. -func parseMajorMinorPatch(version string, tolerant bool) (semver.Version, error) { - groups := KubeSemver.FindStringSubmatch(version) - if tolerant { - groups = KubeSemverTolerant.FindStringSubmatch(version) - } - if len(groups) < 4 { - return semver.Version{}, errors.Errorf("failed to parse major.minor.patch from %q", version) - } - major, err := strconv.ParseUint(groups[1], 10, 64) - if err != nil { - return semver.Version{}, errors.Wrapf(err, "failed to parse major version from %q", version) - } - minor, err := strconv.ParseUint(groups[2], 10, 64) - if err != nil { - return semver.Version{}, errors.Wrapf(err, "failed to parse minor version from %q", version) - } - patch, err := strconv.ParseUint(groups[3], 10, 64) - if err != nil { - return semver.Version{}, errors.Wrapf(err, "failed to parse patch version from %q", version) - } - return semver.Version{ - Major: major, - Minor: minor, - Patch: patch, - }, nil -} - -const ( - numbers = "01234567890" -) - -func containsOnly(s string, set string) bool { - return strings.IndexFunc(s, func(r rune) bool { - return !strings.ContainsRune(set, r) - }) == -1 -} - -type buildIdentifiers []buildIdentifier - -func newBuildIdentifiers(ids []string) buildIdentifiers { - bis := make(buildIdentifiers, 0, len(ids)) - for _, id := range ids { - bis = append(bis, newBuildIdentifier(id)) - } - return bis -} - -// compare compares 2 builidentifiers v and 0. -// -1 == v is less than o. -// 0 == v is equal to o. -// 1 == v is greater than o. -// Note: If everything else is equal the longer build identifier is greater. -func (v buildIdentifiers) compare(o buildIdentifiers) int { - i := 0 - for ; i < len(v) && i < len(o); i++ { - comp := v[i].compare(o[i]) - if comp != 0 { - return comp - } - } - - // if everything is equal till now the longer is greater - if i == len(v) && i == len(o) { //nolint: gocritic - return 0 - } else if i == len(v) && i < len(o) { - return -1 - } else { - return 1 - } -} - -type buildIdentifier struct { - IdentifierInt uint64 - IdentifierStr string - IsNum bool -} - -func newBuildIdentifier(s string) buildIdentifier { - bi := buildIdentifier{} - if containsOnly(s, numbers) { - num, _ := strconv.ParseUint(s, 10, 64) - bi.IdentifierInt = num - bi.IsNum = true - } else { - bi.IdentifierStr = s - bi.IsNum = false - } - return bi -} - -// compare compares v and o. -// -1 == v is less than o. -// 0 == v is equal to o. -// 1 == v is greater than o. -// 2 == v is different than o (it is not possible to identify if lower or greater). -// Note: number is considered lower than string. -func (v buildIdentifier) compare(o buildIdentifier) int { - if v.IsNum && !o.IsNum { - return -1 - } - if !v.IsNum && o.IsNum { - return 1 - } - if v.IsNum && o.IsNum { // both are numbers - switch { - case v.IdentifierInt < o.IdentifierInt: - return -1 - case v.IdentifierInt == o.IdentifierInt: - return 0 - default: - return 1 - } - } else { // both are strings - if v.IdentifierStr == o.IdentifierStr { - return 0 - } - // In order to support random build identifiers, like commit hashes, - // we return 2 when the strings are different to signal the - // build identifiers are different but we can't determine the precedence - return 2 - } -} - -type comparer struct { - buildTags bool - withoutPreReleases bool -} - -// CompareOption is a configuration option for Compare. -type CompareOption func(*comparer) - -// WithBuildTags modifies the version comparison to also consider build tags -// when comparing versions. -// Performs a standard version compare between a and b. If the versions -// are equal, build identifiers will be used to compare further; precedence for two build -// identifiers is determined by comparing each dot-separated identifier from left to right -// until a difference is found as follows: -// - Identifiers consisting of only digits are compared numerically. -// - Numeric identifiers always have lower precedence than non-numeric identifiers. -// - Identifiers with letters or hyphens are compared only for equality, otherwise, 2 is returned given -// that it is not possible to identify if lower or greater (non-numeric identifiers could be random build -// identifiers). -// -// -1 == a is less than b. -// 0 == a is equal to b. -// 1 == a is greater than b. -// 2 == v is different than o (it is not possible to identify if lower or greater). -func WithBuildTags() CompareOption { - return func(c *comparer) { - c.buildTags = true - } -} - -// WithoutPreReleases modifies the version comparison to not consider pre-releases -// when comparing versions. -func WithoutPreReleases() CompareOption { - return func(c *comparer) { - c.withoutPreReleases = true - } -} - -// Compare 2 semver versions. -// Defaults to doing the standard semver comparison when no options are specified. -// The comparison logic can be modified by passing additional compare options. -// Example: using the WithBuildTags() option modifies the compare logic to also -// consider build tags when comparing versions. -func Compare(a, b semver.Version, options ...CompareOption) int { - c := &comparer{} - for _, o := range options { - o(c) - } - - if c.withoutPreReleases { - a.Pre = nil - b.Pre = nil - } - - if c.buildTags { - if comp := a.Compare(b); comp != 0 { - return comp - } - biA := newBuildIdentifiers(a.Build) - biB := newBuildIdentifiers(b.Build) - return biA.compare(biB) - } - return a.Compare(b) -}