From 0d03aea5d9ac235f35b30d3ae53046c499e7f462 Mon Sep 17 00:00:00 2001 From: rabi Date: Thu, 3 Oct 2024 20:29:58 +0530 Subject: [PATCH] Remove PreprovisioningNetworkDataName jira: https://issues.redhat.com/browse/OSPRH-10442 Signed-off-by: rabi --- ...plane.openstack.org_openstackdataplanenodesets.yaml | 2 -- apis/dataplane/v1beta1/common.go | 4 ---- .../v1beta1/openstackdataplanenodeset_webhook.go | 1 - ...plane.openstack.org_openstackdataplanenodesets.yaml | 2 -- .../openstackdataplanenodeset_controller_test.go | 10 ---------- 5 files changed, 19 deletions(-) diff --git a/apis/bases/dataplane.openstack.org_openstackdataplanenodesets.yaml b/apis/bases/dataplane.openstack.org_openstackdataplanenodesets.yaml index fe509a1bb..53ffb5fbd 100644 --- a/apis/bases/dataplane.openstack.org_openstackdataplanenodesets.yaml +++ b/apis/bases/dataplane.openstack.org_openstackdataplanenodesets.yaml @@ -1197,8 +1197,6 @@ spec: - subnetName type: object type: array - preprovisioningNetworkDataName: - type: string userData: properties: name: diff --git a/apis/dataplane/v1beta1/common.go b/apis/dataplane/v1beta1/common.go index eef607d35..673486873 100644 --- a/apis/dataplane/v1beta1/common.go +++ b/apis/dataplane/v1beta1/common.go @@ -130,10 +130,6 @@ type NodeSection struct { // ManagementNetwork - Name of network to use for management (SSH/Ansible) // +kubebuilder:validation:Optional ManagementNetwork string `json:"managementNetwork,omitempty"` - - // +kubebuilder:validation:Optional - // PreprovisioningNetworkDataName - NetworkData secret name in the local namespace for pre-provisioing - PreprovisioningNetworkDataName string `json:"preprovisioningNetworkDataName,omitempty"` } // NodeTemplate is a specification of the node attributes that override top level attributes. diff --git a/apis/dataplane/v1beta1/openstackdataplanenodeset_webhook.go b/apis/dataplane/v1beta1/openstackdataplanenodeset_webhook.go index 32057d770..06ca5c380 100644 --- a/apis/dataplane/v1beta1/openstackdataplanenodeset_webhook.go +++ b/apis/dataplane/v1beta1/openstackdataplanenodeset_webhook.go @@ -93,7 +93,6 @@ func (spec *OpenStackDataPlaneNodeSetSpec) Default() { instanceSpec.BmhLabelSelector = node.BmhLabelSelector instanceSpec.UserData = node.UserData instanceSpec.NetworkData = node.NetworkData - instanceSpec.PreprovisioningNetworkDataName = node.PreprovisioningNetworkDataName nodeSetHostMap[node.HostName] = instanceSpec } spec.BaremetalSetTemplate.BaremetalHosts = nodeSetHostMap diff --git a/config/crd/bases/dataplane.openstack.org_openstackdataplanenodesets.yaml b/config/crd/bases/dataplane.openstack.org_openstackdataplanenodesets.yaml index fe509a1bb..53ffb5fbd 100644 --- a/config/crd/bases/dataplane.openstack.org_openstackdataplanenodesets.yaml +++ b/config/crd/bases/dataplane.openstack.org_openstackdataplanenodesets.yaml @@ -1197,8 +1197,6 @@ spec: - subnetName type: object type: array - preprovisioningNetworkDataName: - type: string userData: properties: name: diff --git a/tests/functional/dataplane/openstackdataplanenodeset_controller_test.go b/tests/functional/dataplane/openstackdataplanenodeset_controller_test.go index fbf5a0f18..b93586e5c 100644 --- a/tests/functional/dataplane/openstackdataplanenodeset_controller_test.go +++ b/tests/functional/dataplane/openstackdataplanenodeset_controller_test.go @@ -255,8 +255,6 @@ var _ = Describe("Dataplane NodeSet Test", func() { BaremetalSetTemplate: baremetalv1.OpenStackBaremetalSetSpec{ BaremetalHosts: nil, OSImage: "", - UserData: nil, - NetworkData: nil, AutomatedCleaningMode: "metadata", ProvisionServerName: "", ProvisioningInterface: "", @@ -294,8 +292,6 @@ var _ = Describe("Dataplane NodeSet Test", func() { AnsibleVars: nil, }, ExtraMounts: nil, - UserData: nil, - NetworkData: nil, Networks: []infrav1.IPSetNetwork{{ Name: "ctlplane", SubnetName: "subnet1", @@ -393,8 +389,6 @@ var _ = Describe("Dataplane NodeSet Test", func() { BaremetalSetTemplate: baremetalv1.OpenStackBaremetalSetSpec{ BaremetalHosts: nil, OSImage: "", - UserData: nil, - NetworkData: nil, AutomatedCleaningMode: "metadata", ProvisionServerName: "", ProvisioningInterface: "", @@ -437,8 +431,6 @@ var _ = Describe("Dataplane NodeSet Test", func() { AnsibleVars: nil, }, ExtraMounts: nil, - UserData: nil, - NetworkData: nil, }, Env: nil, PreProvisioned: true, @@ -839,8 +831,6 @@ var _ = Describe("Dataplane NodeSet Test", func() { BaremetalSetTemplate: baremetalv1.OpenStackBaremetalSetSpec{ BaremetalHosts: nil, OSImage: "", - UserData: nil, - NetworkData: nil, AutomatedCleaningMode: "metadata", ProvisionServerName: "", ProvisioningInterface: "",