-
Notifications
You must be signed in to change notification settings - Fork 372
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 Node SNAT for Static Egress case #6831
base: main
Are you sure you want to change the base?
Conversation
658ceb3
to
8dd6cfb
Compare
be099f9
to
1f5c419
Compare
62ff87c
to
c0bc9dd
Compare
eState.pods.Insert(pod) | ||
stalePods.Delete(pod) | ||
egress, _ = c.egressLister.Get(egressName) | ||
if egress.Status.EgressNode != "" { |
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.
As I pointed out before, I do feel like it is strange to consume .Status.EgressNode
as part of the controller, and I am not sure this feature is very useful, but I will let @tnqn review & decide.
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.
I'm not sure if this is an improvement either. Note that if this behavior change isn't wanted by all users, it would satisfy some while breaking others. The issue being addressed doesn't come from end users so I would prefer keeping it as was.
Instead of changing the behavior from one to another, I would prefer making it explicit and configurable, letting user know and decide what would happen.
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.
okay so in that case we can have a config variable set by user in antrea.yml and if that i set then we can allow normal Node SNAT if static egress is not assigned to any node, and if the variable is not set or is false then we will keep the behaviour as it is.
Is it what is expected @antoninbas @tnqn
7267a38
to
592fec7
Compare
Implemented best effort scenario, where in case of static Egress also, if there is no egress node then the packets will be sent using normal Node SNAT, as in case of dynamic Egress. Signed-off-by: Pulkit Jain <[email protected]>
592fec7
to
afe7285
Compare
Implemented best effort scenario, where in case of static Egress also, if there is no egress node then the packets will be sent using normal Node SNAT, as in case of dynamic Egress.
For #6228.