Skip to content

Commit

Permalink
Update Ansible error message; default to 30s interval
Browse files Browse the repository at this point in the history
  • Loading branch information
LRitzdorf committed Jun 25, 2024
1 parent 9d9ed7d commit d706fc9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ func main() {

// Configure and parse arguments
port := flag.Int("port", 27780, "port on which to listen for POSTs")
interval := flag.Duration("interval", 5*time.Minute, "how frequently to run Ansible, regardless of buffer length")
interval := flag.Duration("interval", 30*time.Second, "how frequently to run Ansible, regardless of buffer length")
batchSize := flag.Int("batch-size", 100, "how full the node buffer must be to trigger a non-timed push")
playbook := flag.String("playbook", "main.yaml", "Ansible playbook to run against nodes")
debug := flag.Bool("debug", false, "sets log level to debug")
Expand Down Expand Up @@ -199,6 +199,6 @@ func ansibleHost(args *[]string, wg *sync.WaitGroup) {
ansible.Stdout = os.Stdout
ansible.Stderr = os.Stdout
if err := ansible.Run(); err != nil {
log.Error().Err(err).Msg("Failed to launch Ansible!")
log.Error().Err(err).Msg("An Ansible error occurred!")
}
}

0 comments on commit d706fc9

Please sign in to comment.