-
Notifications
You must be signed in to change notification settings - Fork 260
Fix CNS Program iptables for delegated IPAM #1499
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
Conversation
rbtr
left a comment
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.
the conflist needs to exist
| COPY --from=azure-ipam /azure-ipam/*.conflist pkg/embed/fs |
For the cns image? |
|
for the dropgz build. you've deleted that unrelated file in this change, it needs to be put back. |
cns/restserver/internalapi.go
Outdated
| iptables.RuleExists(iptables.V4, iptables.Nat, iptables.Swift, azureIMDSMatch, snatHostIPJump) { | ||
| // Only check for existence of other iptables rule if SWIFT chain exists. | ||
| if chainExist { | ||
| postroutingToSwiftJumpexist, err := ipt.Exists(iptables.Nat, iptables.Postrouting, "-j", "SWIFT-POSTROUTING") |
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.
why the change from iptables.Swift to "SWIFT-POSTROUTING"? that really should be a const since it is reused so much
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.
@tamilmani1989 thinks we should term it like that instead of SWIFT. I can make it a const.
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
dd5c973 to
5d33af7
Compare
cns/restserver/internalapi.go
Outdated
| return types.FailedToRunIPTableCmd, "[Azure CNS] failed to create SWIFT chain : " + err.Error() | ||
| } | ||
| logger.Printf("[Azure CNS] Append SWIFT Chain to POSTROUTING ...") | ||
| err = ipt.Append(iptables.Nat, iptables.Postrouting, "-j", SwiftChainName) |
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.
what if this rule exist in this chain? will it return failure if rule exists?
823684f to
14742bb
Compare
rbtr
left a comment
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, aks-e tests are broken and won't pass
44b2837 to
b208476
Compare
b208476 to
55c35b0
Compare
tamilmani1989
left a comment
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
|
bypassing broken aks-e check |
^