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

ingress: Correct FromGroups rule Parsing #32231

Merged
merged 2 commits into from
May 7, 2024

Conversation

Alex-Waring
Copy link
Contributor

@Alex-Waring Alex-Waring commented Apr 29, 2024

In #30708 I created a resource that translates to a K8s resource but not to an actual resource. This PR corrects that behaviour by adding in some tests and fixing when they break. You could argue I should have done this initially, you're right.

This should be backported to 1.16 so it goes out with the original PR.

@Alex-Waring Alex-Waring requested review from a team as code owners April 29, 2024 12:53
@maintainer-s-little-helper maintainer-s-little-helper bot added the dont-merge/needs-release-note-label The author needs to describe the release impact of these changes. label Apr 29, 2024
@github-actions github-actions bot added the kind/community-contribution This was a contribution made by a community member. label Apr 29, 2024
@joestringer
Copy link
Member

/test

@Alex-Waring
Copy link
Contributor Author

@learnitall / @joamaki I don't think the test failures are related, mind a review please?

Copy link
Contributor

@learnitall learnitall left a comment

Choose a reason for hiding this comment

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

The changes look good! I'm not too familiar with this part of cilium so it definitely would make sense to get more eyes on this.

@joestringer
Copy link
Member

This should be backported to 1.16 so it goes out with the original PR.

For now, v1.16 development continues on the main branch so no special process is required to ensure the above.

@aanm aanm requested review from a team, nebril and squeed and removed request for a team and nebril May 2, 2024 09:23
@squeed
Copy link
Contributor

squeed commented May 3, 2024

Unfortunately, this will need a rebase. But thanks for catching this!

Since this is fixing an unshipped bug, no release note is required.

Currently fromGroups, which was added in cilium#30708,
is correctly represented in the YAML but not being converted to a rule.
This commit fixes that by:
- Reporting that a rule requires derivation when an ingress component
  does, and making sure to clear ingress rules when creating that
  derivative.
- Adding FromGroups to parseToCiliumIngressCommonRule logic
- During validation make sure that fromGroups is not combined with other
  L3 rules.

Signed-off-by: Alex Waring <ajmwaring@gmail.com>
@Alex-Waring Alex-Waring force-pushed the AWar/ingress/corrections branch 2 times, most recently from 47e1e85 to c23a75e Compare May 3, 2024 13:14
In the previous commit and cilium#30708
the fromGroups resource was added, but testing was not covered properly.
This commit validates that we are working as expected.

Signed-off-by: Alex Waring <ajmwaring@gmail.com>
@aanm aanm enabled auto-merge May 3, 2024 14:12
@aanm
Copy link
Member

aanm commented May 3, 2024

/test

@aanm aanm added this pull request to the merge queue May 7, 2024
Merged via the queue into cilium:main with commit 87ed04b May 7, 2024
64 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/community-contribution This was a contribution made by a community member. release-note/misc This PR makes changes that have no direct user impact.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants