Skip to content
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

✨ Filter CNI subnets when creating EKS NodeGroup #4800

Merged
merged 1 commit into from
May 20, 2024

Conversation

mnitchev
Copy link
Contributor

@mnitchev mnitchev commented Feb 20, 2024

What type of PR is this?

/kind feature

What this PR does / why we need it:

Not sure if this is a bug or a feature. I don't think it's intended for nodes to land on the subnets intended for CNI, but if it is then I can also change this PR to add another AZSubnetType.

Special notes for your reviewer:

Checklist:

  • squashed commits
  • includes documentation
  • includes emojis
  • adds unit tests - I've updated the unit test
  • adds or updates e2e tests

Release note:

Exclude CNI subnets when creating EKS NodeGroup with private availability zone subnet type.

@k8s-ci-robot k8s-ci-robot added release-note Denotes a PR that will be considered when it comes time to generate release notes. kind/feature Categorizes issue or PR as related to a new feature. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-priority needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Feb 20, 2024
@k8s-ci-robot
Copy link
Contributor

Hi @mnitchev. Thanks for your PR.

I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

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/test-infra repository.

@k8s-ci-robot k8s-ci-robot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Feb 20, 2024
@nrb
Copy link
Contributor

nrb commented Feb 20, 2024

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Feb 20, 2024
@Ankitasw
Copy link
Member

/test pull-cluster-api-provider-aws-e2e

@mnitchev
Copy link
Contributor Author

mnitchev commented Mar 5, 2024

/retest

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Mar 6, 2024
@k8s-ci-robot
Copy link
Contributor

PR needs rebase.

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/test-infra repository.

@k8s-ci-robot k8s-ci-robot added do-not-merge/contains-merge-commits and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Mar 13, 2024
@mnitchev
Copy link
Contributor Author

@cnmcavoy @dlipovetsky Can you please review? CI is green

@Ankitasw
Copy link
Member

/test pull-cluster-api-provider-aws-e2e

api/v1beta2/network_types.go Outdated Show resolved Hide resolved
pkg/cloud/scope/shared.go Outdated Show resolved Hide resolved
Copy link
Contributor

@AndiDog AndiDog left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

Can we make the release notes clearer? The word "filter" can mean different things (include vs. exclude). Suggestion:

Exclude CNI subnets when creating EKS NodeGroup with private availability zone subnet type.

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 9, 2024
@AndiDog
Copy link
Contributor

AndiDog commented Apr 9, 2024

I stumbled over the problem as well that the subnet filtering functions can return subnets from secondary CIDR blocks (as part of #4898). In most places of CAPA, most likely the code only assumes subnets from the primary CIDR. Maybe FilterPublic and FilterPrivate should always only return the primary ones? For EKS, and other future cases where secondary CIDRs may be used, specific functions could be used.

@richardcase or other maintainers, do you have experience with this networking code?

@AndiDog
Copy link
Contributor

AndiDog commented Apr 15, 2024

Some more occurrences must be fixed so CAPA doesn't choose subnets from the secondary CIDR by mistake, e.g. to run EC2 instances. But I can take care of those via #4898.

/lgtm

@AndiDog
Copy link
Contributor

AndiDog commented Apr 15, 2024

/assign @Ankitasw
/assign @richardcase

for approval if you don't have concerns

@richardcase
Copy link
Member

/test ?

@k8s-ci-robot
Copy link
Contributor

@richardcase: The following commands are available to trigger required jobs:

  • /test pull-cluster-api-provider-aws-build
  • /test pull-cluster-api-provider-aws-build-docker
  • /test pull-cluster-api-provider-aws-test
  • /test pull-cluster-api-provider-aws-verify

The following commands are available to trigger optional jobs:

  • /test pull-cluster-api-provider-aws-apidiff-main
  • /test pull-cluster-api-provider-aws-e2e
  • /test pull-cluster-api-provider-aws-e2e-blocking
  • /test pull-cluster-api-provider-aws-e2e-clusterclass
  • /test pull-cluster-api-provider-aws-e2e-conformance
  • /test pull-cluster-api-provider-aws-e2e-conformance-with-ci-artifacts
  • /test pull-cluster-api-provider-aws-e2e-eks
  • /test pull-cluster-api-provider-aws-e2e-eks-gc
  • /test pull-cluster-api-provider-aws-e2e-eks-testing

Use /test all to run the following jobs that were automatically triggered:

  • pull-cluster-api-provider-aws-apidiff-main
  • pull-cluster-api-provider-aws-build
  • pull-cluster-api-provider-aws-build-docker
  • pull-cluster-api-provider-aws-test
  • pull-cluster-api-provider-aws-verify

In response to this:

/test ?

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/test-infra repository.

@richardcase
Copy link
Member

/test pull-cluster-api-provider-aws-e2e
/test pull-cluster-api-provider-aws-e2e-eks

@nrb
Copy link
Contributor

nrb commented Apr 22, 2024

Failed due to timeouts.

/retest

@richardcase
Copy link
Member

/test pull-cluster-api-provider-aws-e2e

@AndiDog
Copy link
Contributor

AndiDog commented Apr 25, 2024

@richardcase tests seem to have worked fine now.

@Ankitasw
Copy link
Member

/approve

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: Ankitasw

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

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label May 20, 2024
@k8s-ci-robot k8s-ci-robot merged commit 2d2371f into kubernetes-sigs:main May 20, 2024
24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/feature Categorizes issue or PR as related to a new feature. lgtm "Looks good to me", indicates that a PR is ready to be merged. needs-priority ok-to-test Indicates a non-member PR verified by an org member that is safe to test. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants