Skip to content

Remove PreprovisioningNetworkDataName #217

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 7, 2024

Conversation

rabi
Copy link
Contributor

@rabi rabi commented Oct 3, 2024

We had initially introduced preprovisioningNetworkDataName field in InstanceSpec for users to have flexibility of setting it in OpenStackDataPlaneNodeSet CR for the individual nodes. We have had the implementation to fallback to using preprovisioningNetworkDataName for provisioning networkData if the later is not provided and the former is set.

However, we've noticed that this does not work when using coreos IPA ramdisk image as ProvisioningImage Builder expects the preprovisioningNetworkDataName to be in nmstate format, however for us during provisioning cloud-init expects it to be in openstack network_data.json format.

Therefore we would not replicate the metal3 behavior of falling back to preprovisioningNetworkDataName if networkData is not provided. We instead will keep both network data for preprovisionig and provisoning separate. If networkData is not provided per BMH node, we would use the default networkData we generate using IPAM.

This also removes networkData/userData from the BaremetalSet spec as there is no way user can provide this data for a set of BMHs.

Depends-On: openstack-k8s-operators/openstack-operator#1116
jira: https://issues.redhat.com/browse/OSPRH-10442

@openshift-ci openshift-ci bot requested review from abays and olliewalsh October 3, 2024 14:24
Copy link
Contributor

openshift-ci bot commented Oct 3, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: rabi

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@rabi
Copy link
Contributor Author

rabi commented Oct 3, 2024

Putting this on hold to see if we want to update #211 instead.

Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/0fbe64a3a8f544d5bbcc47bc775c0d87

openstack-baremetal-operator-content-provider FAILURE in 13m 51s
⚠️ openstack-baremetal-operator-crc-podified-edpm-baremetal SKIPPED Skipped due to failed job openstack-baremetal-operator-content-provider

@rabi
Copy link
Contributor Author

rabi commented Oct 4, 2024

recheck

Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/af77385bf40b43f58d3aa508929daf34

openstack-baremetal-operator-content-provider FAILURE in 12m 34s
⚠️ openstack-baremetal-operator-crc-podified-edpm-baremetal SKIPPED Skipped due to failed job openstack-baremetal-operator-content-provider

We had initially introduced preprovisioningNetworkDataName
field in InstanceSpec for users to have flexibility of
setting it in OpenStackDataPlaneNodeSet CR for the individual
nodes. We have had the implementation to fallback to using
preprovisioningNetworkDataName for networkData if the later
is not provided and the former is set.

However, we've noticed that this does not work when using
coreos IPA ramdisk image as ProvisioningImage Builder expects
the preprovisioningNetworkDataName to be in nmstate format,
however for us during provisioning cloud-init expects it to be in
openstack network_data.json format.

Therefore we would not replicate the metal3 behavior of falling back
to preprovisioningNetworkDataName if networkData is not provided.
We instead will keep both network data for preprovisionig and
provisoning separate. If networkData is not provided per BMH node,
we would use the default networkData we generate using IPAM.

This also removes networkData/userData from the BaremetalSet spec
as there is no way user can provide this data for a set of BMHs.

jira: https://issues.redhat.com/browse/OSPRH-10442
Signed-off-by: rabi <[email protected]>
Copy link

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/232de0b0efcb4315b83aab3a3d43f038

openstack-baremetal-operator-content-provider FAILURE in 11m 57s
⚠️ openstack-baremetal-operator-crc-podified-edpm-baremetal SKIPPED Skipped due to failed job openstack-baremetal-operator-content-provider

@rabi
Copy link
Contributor Author

rabi commented Oct 4, 2024

recheck

@abays
Copy link
Contributor

abays commented Oct 4, 2024

Putting this on hold to see if we want to update #211 instead.

@rabi Does #211 incidentally solve the same problem that you describe in this PR's description?

@rabi
Copy link
Contributor Author

rabi commented Oct 4, 2024

Putting this on hold to see if we want to update #211 instead.

@rabi Does #211 incidentally solve the same problem that you describe in this PR's description?

No it does not in its current state. It needs to be reworked like this. The reason I mentioned that here is because it was started earlier and we discussed some of these things there too and it led to further investigation.

@rabi
Copy link
Contributor Author

rabi commented Oct 5, 2024

/test openstack-baremetal-operator-build-deploy

@rabi
Copy link
Contributor Author

rabi commented Oct 7, 2024

Putting this on hold to see if we want to update #211 instead.

@rabi Does #211 incidentally solve the same problem that you describe in this PR's description?

No it does not in its current state. It needs to be reworked like this. The reason I mentioned that here is because it was started earlier and we discussed some of these things there too and it led to further investigation.

@abays I've not seen any updates to the other PR. As we want this fix in 18.0.2 ASAP, I think we should merge and backport this.

@hjensas
Copy link
Contributor

hjensas commented Oct 7, 2024

/lgtm

@openshift-ci openshift-ci bot added the lgtm label Oct 7, 2024
@openshift-merge-bot openshift-merge-bot bot merged commit b5622e3 into openstack-k8s-operators:main Oct 7, 2024
6 checks passed
@rabi
Copy link
Contributor Author

rabi commented Oct 7, 2024

/cherrypick 18.0.0-proposed

@openshift-cherrypick-robot

@rabi: #217 failed to apply on top of branch "18.0.0-proposed":

Applying: Remove PreprovisioningNetworkData
Using index info to reconstruct a base tree...
M	api/bases/baremetal.openstack.org_openstackbaremetalsets.yaml
M	api/v1beta1/openstackbaremetalset_types.go
M	api/v1beta1/zz_generated.deepcopy.go
M	config/crd/bases/baremetal.openstack.org_openstackbaremetalsets.yaml
M	pkg/openstackbaremetalset/baremetalhost.go
M	tests/functional/openstackbaremetalset_controller_test.go
Falling back to patching base and 3-way merge...
Auto-merging tests/functional/openstackbaremetalset_controller_test.go
CONFLICT (content): Merge conflict in tests/functional/openstackbaremetalset_controller_test.go
Auto-merging pkg/openstackbaremetalset/baremetalhost.go
CONFLICT (content): Merge conflict in pkg/openstackbaremetalset/baremetalhost.go
Auto-merging config/crd/bases/baremetal.openstack.org_openstackbaremetalsets.yaml
Auto-merging api/v1beta1/zz_generated.deepcopy.go
Auto-merging api/v1beta1/openstackbaremetalset_types.go
Auto-merging api/bases/baremetal.openstack.org_openstackbaremetalsets.yaml
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0001 Remove PreprovisioningNetworkData
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".

In response to this:

/cherrypick 18.0.0-proposed

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants