1
0
mirror of https://github.com/muety/wakapi.git synced 2023-08-10 21:12:56 +03:00

Trigger summary generation on server startup.

This commit is contained in:
Ferdinand Mütsch 2019-10-11 09:16:42 +02:00
parent b7616a7457
commit 9b17cde420

View File

@ -44,6 +44,9 @@ func (srv *AggregationService) Schedule() {
go srv.persistWorker(summaries)
}
// Run once initially
srv.trigger(jobs)
gocron.Every(1).Day().At("02:15").Do(srv.trigger, jobs)
<-gocron.Start()
}