tune update db
This commit is contained in:
6
main.go
6
main.go
@@ -6,6 +6,7 @@ import (
|
||||
"github.com/rs/zerolog/log"
|
||||
"os"
|
||||
"os/signal"
|
||||
"thuanle.me/ip-info/internal/data"
|
||||
"thuanle.me/ip-info/internal/services/api"
|
||||
"thuanle.me/ip-info/internal/services/db_updater"
|
||||
"time"
|
||||
@@ -21,6 +22,11 @@ func main() {
|
||||
log.Err(err).Msg("Error loading .env file")
|
||||
}
|
||||
|
||||
err = data.CleanTempFiles()
|
||||
if err != nil {
|
||||
log.Err(err).Msg("Failed to clean temp files")
|
||||
}
|
||||
|
||||
stop := make(chan os.Signal, 1)
|
||||
signal.Notify(stop, os.Interrupt)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user