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

portmap: fix iptables conditions detection #1117

Conversation

champtar
Copy link
Contributor

@champtar champtar commented Nov 5, 2024

As show in the docs, iptables conditions can also start with '!'

Fixes 01a94e1
Fixes #1114

@champtar champtar force-pushed the portmap-detectBackendOfConditions-fix branch 2 times, most recently from c50b94c to 402e194 Compare November 5, 2024 22:37
@champtar
Copy link
Contributor Author

champtar commented Nov 6, 2024

Tested with

{
  "type": "portmap",
  "capabilities": {"portMappings": true},
  "externalSetMarkChain": "KUBE-MARK-MASQ",
  "conditionsV4": ["!", "-d", "127.0.0.0/8", "-m", "iprange", "!", "--dst-range", "198.19.254.254"]
},

@champtar champtar marked this pull request as ready for review November 6, 2024 00:12
@danwinship
Copy link
Contributor

ah, oops, yes
/lgtm
(but I'm not sure I can actually do that?)
/assign @squeed

@danwinship
Copy link
Contributor

(ah, lol, there's no prow at all here)

@champtar champtar force-pushed the portmap-detectBackendOfConditions-fix branch from 402e194 to cf2f081 Compare November 18, 2024 19:35
@champtar
Copy link
Contributor Author

@squeed this one is also ready to be merged (just rebased)

As show in the docs, iptables conditions can also start with '!'

Fixes 01a94e1

Signed-off-by: Etienne Champetier <[email protected]>
@champtar champtar force-pushed the portmap-detectBackendOfConditions-fix branch from cf2f081 to ccac6de Compare November 21, 2024 19:28
@champtar
Copy link
Contributor Author

@danwinship @squeed rebased and ready to merge

@squeed squeed merged commit 7f756b4 into containernetworking:main Dec 2, 2024
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

iptables backend was requested but configuration contains nftables-specific options [conditionsV4]
3 participants