Maint: firewall and routing use logger.Debug

- Remove SetVerbose and SetDebug from both
- Log routing teardown
- Default logging level set to info
This commit is contained in:
Quentin McGaw (desktop)
2021-07-23 18:20:18 +00:00
parent b23eb8f29d
commit 94b60d9f70
7 changed files with 57 additions and 76 deletions

View File

@@ -38,9 +38,9 @@ func (c *configurator) runIP6tablesInstruction(ctx context.Context, instruction
}
c.ip6tablesMutex.Lock() // only one ip6tables command at once
defer c.ip6tablesMutex.Unlock()
if c.debug {
fmt.Println("ip6tables " + instruction)
}
c.logger.Debug("ip6tables " + instruction)
flags := strings.Fields(instruction)
cmd := exec.CommandContext(ctx, "ip6tables", flags...)
if output, err := c.commander.Run(cmd); err != nil {