Update dependencies and fix some linter warnings
This commit is contained in:
@@ -141,7 +141,9 @@ func ActionServe(c *cli.Context) error {
|
||||
|
||||
go func() {
|
||||
loggers.rootLogger.Info("Starting ports server")
|
||||
portsServer.Start(portsCtx)
|
||||
if err := portsServer.Start(portsCtx); err != nil {
|
||||
loggers.rootLogger.Warnw("Ports server returned error", "err", err)
|
||||
}
|
||||
}()
|
||||
}
|
||||
|
||||
@@ -241,7 +243,9 @@ func ActionServe(c *cli.Context) error {
|
||||
select {
|
||||
case <-ticker.C:
|
||||
if healthy == nil {
|
||||
daemon.SdNotify(false, daemon.SdNotifyWatchdog)
|
||||
if _, err := daemon.SdNotify(false, daemon.SdNotifyWatchdog); err != nil {
|
||||
loggers.rootLogger.Warnw("Error notifying watchdog.", "err", err)
|
||||
}
|
||||
continue
|
||||
}
|
||||
// TODO: If unhealthy, should we retry healthcheck immediately, otherwise service will most likely get killed by watchdog.
|
||||
@@ -280,7 +284,6 @@ func ActionServe(c *cli.Context) error {
|
||||
<-rootCtx.Done()
|
||||
|
||||
return nil
|
||||
|
||||
}
|
||||
|
||||
type loggerCollection struct {
|
||||
@@ -332,7 +335,6 @@ func setupLoggers(cfg config.Config) *loggerCollection {
|
||||
portsLogger: rootLogger.Named("PRT").Sugar(),
|
||||
smtpLogger: rootLogger.Named("SMT").Sugar(),
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
func getConfig() (config.Config, error) {
|
||||
|
Reference in New Issue
Block a user