diff options
| author | Lizzy Hunt <lizzy.hunt@usu.edu> | 2024-03-27 15:10:39 -0600 |
|---|---|---|
| committer | Lizzy Hunt <lizzy.hunt@usu.edu> | 2024-03-27 15:10:39 -0600 |
| commit | 97efd2a3740412ec78a018da4fe068c141c9d1ec (patch) | |
| tree | 73904689d6c69898bd834533d33b65106b14ce3e /main.go | |
| parent | 0dc2679005e70c50024bc49e750f3998a0c4c24b (diff) | |
| download | hatecomputers.club-97efd2a3740412ec78a018da4fe068c141c9d1ec.tar.gz hatecomputers.club-97efd2a3740412ec78a018da4fe068c141c9d1ec.zip | |
clean up old sessions every 500 seconds
Diffstat (limited to 'main.go')
| -rw-r--r-- | main.go | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -6,6 +6,7 @@ import ( "git.hatecomputers.club/hatecomputers/hatecomputers.club/api" "git.hatecomputers.club/hatecomputers/hatecomputers.club/args" "git.hatecomputers.club/hatecomputers/hatecomputers.club/database" + "git.hatecomputers.club/hatecomputers/hatecomputers.club/scheduler" "github.com/joho/godotenv" ) @@ -33,6 +34,10 @@ func main() { log.Println("database migrated successfully") } + if argv.Scheduler { + scheduler.StartScheduler(dbConn) + } + if argv.Server { server := api.MakeServer(argv, dbConn) err = server.ListenAndServe() |
