MCPcopy Create free account
hub / github.com/apache/cloudstack / flushAllIptablesRules

Method flushAllIptablesRules

systemvm/debian/opt/cloud/bin/configure.py:650–660  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

648 self.fw.append([self.table, self.count, rstr])
649
650 def flushAllIptablesRules(self):
651 if not self.config.is_routed():
652 return
653 # Flush all iptables rules for routing networks, which are replaced by nftables rules
654 logging.info("Flush all iptables rules")
655 CsHelper.execute("iptables -F filter")
656 CsHelper.execute("iptables -F nat")
657 CsHelper.execute("iptables -F mangle")
658 CsHelper.execute("nft delete table ip filter")
659 CsHelper.execute("nft delete table ip nat")
660 CsHelper.execute("nft delete table ip mangle")
661
662 def flushAllowAllEgressRules(self):
663 if self.config.is_routed():

Callers 1

processMethod · 0.95

Calls 3

is_routedMethod · 0.80
executeMethod · 0.65
infoMethod · 0.45

Tested by

no test coverage detected