优化nftables相关代码

This commit is contained in:
刘祥超
2022-06-09 19:12:10 +08:00
parent 74f1bf330d
commit 885defbf31
4 changed files with 40 additions and 3 deletions
+6
View File
@@ -257,6 +257,12 @@ func (this *ListenerManager) addToFirewalld(groupAddrs []string) {
return
}
// 检查状态
err = exec.Command(firewallCmd, "--state").Run()
if err != nil {
return
}
remotelogs.Println("FIREWALLD", "open ports automatically")
for _, port := range ports {
{