OCPBUGS-88035: Add e2e test verifying CAPI EC2 instance ownership tag#594
OCPBUGS-88035: Add e2e test verifying CAPI EC2 instance ownership tag#594matzew wants to merge 1 commit into
Conversation
|
@matzew: This pull request references Jira Issue OCPBUGS-88035, which is invalid:
Comment The bug has been updated to refer to the pull request using the external bug tracker. DetailsIn response to this:
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 openshift-eng/jira-lifecycle-plugin repository. |
|
Warning Review limit reached
More reviews will be available in 11 minutes and 15 seconds. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more credits in the billing tab to continue. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Repository YAML (base), Central YAML (inherited) Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (2)
WalkthroughThis PR adds a test helper function that verifies EC2 instances created by Cluster API contain the Kubernetes cluster ownership tag, then calls this verification in the AWS E2E test after creating and confirming MachineSet readiness. ChangesCAPI Instance Ownership Tag Verification
🎯 2 (Simple) | ⏱️ ~15 minutes 🚥 Pre-merge checks | ✅ 13 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (13 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Pipeline controller notification For optional jobs, comment This repository is configured in: LGTM mode |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@e2e/aws_helpers.go`:
- Around line 224-235: The single-shot assertion on EC2 tags can flake due to
propagation lag; wrap the ownership-tag check in an Eventually block that
re-fetches the instance each poll using getCAPICreatedInstance(awsClient,
capiMsName), inspect instance.Tags for the expectedTagKey
(fmt.Sprintf("kubernetes.io/cluster/%s", infraName)) and value "owned", and
assert Expect(found).To(BeTrue()) inside Eventually with a reasonable timeout
and poll interval so the test retries until the tag appears.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository YAML (base), Central YAML (inherited)
Review profile: CHILL
Plan: Enterprise
Run ID: 076f6d18-6e47-4e93-9bb9-d5143ffd5b5f
📒 Files selected for processing (2)
e2e/aws_helpers.goe2e/aws_test.go
Verify that a CAPI-created EC2 instance has the kubernetes.io/cluster/<infraID>=owned tag that openshift-install destroy cluster relies on to identify and clean up cloud resources. CAPA may already add this tag automatically via its Build() + WithCloudProvider() tag pipeline. This test confirms whether the tag is present without any explicit AdditionalTags on the AWSCluster object. Signed-off-by: Matthias Wessendorf <mwessend@redhat.com>
6a9fe4a to
eaf2b33
Compare
|
/retest |
|
/lgtm |
|
Scheduling tests matching the |
|
/jira refresh |
|
@matzew: This pull request references Jira Issue OCPBUGS-88035, which is invalid:
Comment DetailsIn response to this:
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 openshift-eng/jira-lifecycle-plugin repository. |
|
/jira refresh |
|
@matzew: This pull request references Jira Issue OCPBUGS-88035, which is invalid:
Comment DetailsIn response to this:
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 openshift-eng/jira-lifecycle-plugin repository. |
|
/jira refresh |
|
@matzew: This pull request references Jira Issue OCPBUGS-88035, which is valid. The bug has been moved to the POST state. 3 validation(s) were run on this bug
DetailsIn response to this:
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 openshift-eng/jira-lifecycle-plugin repository. |
|
/retest |
|
Permafailing: |
|
@mdbooth: Overrode contexts on behalf of mdbooth: ci/prow/e2e-openstack-ovn-techpreview DetailsIn response to this:
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. |
|
@matzew: The following tests failed, say
Full PR test history. Your PR dashboard. DetailsInstructions 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. I understand the commands that are listed here. |
|
@mdbooth as this change only affects the CAPI e2e operator tests, I think we can override all the other unrelated failures presubs. |
Verify that a CAPI-created EC2 instance has the
kubernetes.io/cluster/=owned tag that openshift-install destroy cluster relies on to identify and clean up cloud resources.
CAPA may already add this tag automatically via its Build() + WithCloudProvider() tag pipeline. This test confirms whether the tag is present without any explicit AdditionalTags on the AWSCluster object.
Summary by CodeRabbit