Commit b71a598b authored by Lukas Burgey's avatar Lukas Burgey
Browse files

Align log message

parent 613c5183
...@@ -118,7 +118,7 @@ func (k sshKey) String() string { ...@@ -118,7 +118,7 @@ func (k sshKey) String() string {
} }
func (t task) String() string { func (t task) String() string {
return fmt.Sprintf("%s:%s %s %s", t.Service, t.User, t.Action, t.Key) return fmt.Sprintf("%s:%s %8s %s", t.Service, t.User, t.Action, t.Key)
} }
func filterPermitted(permitted []service, wanted []service) (remainder []service) { func filterPermitted(permitted []service, wanted []service) (remainder []service) {
...@@ -190,13 +190,15 @@ func getConfig(configFile string) (c config, err error) { ...@@ -190,13 +190,15 @@ func getConfig(configFile string) (c config, err error) {
return return
} }
if err = json.Unmarshal(bs, &c); err != nil { err = json.Unmarshal(bs, &c)
if err != nil {
log.Printf("[Conf] Error parsing config file: %s", err) log.Printf("[Conf] Error parsing config file: %s", err)
return return
} }
if err = c.fetchConfig(); err != nil { err = c.fetchConfig()
log.Printf("[Conf] Error fetching remote config: %s", err) if err != nil {
log.Fatalf("[Conf] Error fetching remote config: %s", err)
return return
} }
if c.FetchInterval, err = time.ParseDuration(c.FetchIntervalString); err != nil { if c.FetchInterval, err = time.ParseDuration(c.FetchIntervalString); err != nil {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment