-
Notifications
You must be signed in to change notification settings - Fork 214
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
Allow configuring RKE ACI network provider #912
Allow configuring RKE ACI network provider #912
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please update the following
Thanks! I've updated the fields and the corresponding docs. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the changes! I see a whole bunch of fields here not listed in the rke_docs.
Could you explain why they are added and if they aren't needed, remove them?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, fields wise. We may need end-to-end acceptance tests for a basic implementation of the aci_network_provider
field in the tf config for RKE clusters using the rancher2 provider. Merging this PR is pending some internal discussions on our end. Thank you for your patience.
Thanks! We have environments running with Rancher managing RKE clusters using the ACI CNI provider, and provisioning them using the Terraform provider with this code is working. I'd be happy to assist with end-to-end testing. |
Blocked by rancher/kontainer-driver-metadata#922. Waiting on all feedback comments to be addressed and tested before reviewing with another tf SME. Once that PR is merged then this one can be re-reviewed and merged for ACI support in the Terraform provider |
ACI support rancher/kontainer-driver-metadata#922 (KDM) and rancher/rke#2963 (rke) have been merged, unblocking |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add tf structure tests for aci_network_provider
fields to make sure expansion and flatteners work correctly. Also provision an RKE cluster and import it into rancher with a simple ACI configuration to make sure that works. Then this will good to merge
Apologies! Tests have already been added The rke PR rancher/rke#2963 has added extra fields to CNI version 5.2.3.2 here https://github.com/rancher/rke/pull/2963/files#diff-d6d39102a5c2432600e3ffac3abe79885d842926704befe5bdb3063be71518b7R653-R663. Please add these fields to this PR and update the tests, thank you |
Before I can add the fields, I think they also need to be added here: https://github.com/rancher/rancher/blob/release/v2.6/pkg/client/generated/management/v3/zz_generated_aci_network_provider.go
I'm not sure how those files are generated in the rancher/rancher repo, but according to the latest commit to the file, it's based on the rancher/rke go dependency. Perhaps the rke package needs to be released first? |
@fpants Correct, the tf rancher2 provider uses rancher, which uses rke under the hood. The ACI field support is not in a released version of rke yet so rancher doesn't know about them. Go ahead and add the fields/tests to this PR. I'll make sure the latest version of rke is released before this PR gets merged. Merge blocked by rke v1.3.14 release https://github.com/rancher/rke/releases |
Thanks @annablender, that makes sense. I have added the fields introduced in ACI-CNI 5.2.3.2. |
@fpants Thank you! I see the build is failing
This is happening because rancher does not have the additional ACI fields supported in the latest rke in its types structure. We are releasing rke |
c0705ee
to
d943312
Compare
RKE 1.3.14 has been merged rancher/rancher#38295 and started being used by rancher on July 15, which should fix the above types error. Dependencies also needed to be bumped. The PR for that #959 has also been merged. Waiting on CI... will ping reviewers when this passes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, build is passing
Issue: #922
This PR adds logic for configuring RKE clusters with the ACI network provider.
The Rancher API already supports this (see https:///v3/schemas/aciNetworkProvider), so this is only to also expose this in the Rancher Terraform provider.
Similar ACI configuration is already available in the RKE Terraform provider: https://registry.terraform.io/providers/rancher/rke/latest/docs/resources/cluster#aci_network_provider
I'm not entirely sure everything is covered, so please make suggestions for any improvements.