Seed the RNG at startup
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
e410b629ed
commit
768f930f50
1 changed files with 5 additions and 0 deletions
5
main.go
5
main.go
|
@ -3,9 +3,11 @@ package main
|
||||||
import (
|
import (
|
||||||
"crypto/tls"
|
"crypto/tls"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"math/rand"
|
||||||
"net/http"
|
"net/http"
|
||||||
"os"
|
"os"
|
||||||
"strings"
|
"strings"
|
||||||
|
"time"
|
||||||
|
|
||||||
"git.fromouter.space/mcg/mlp-server-tools/draftbot"
|
"git.fromouter.space/mcg/mlp-server-tools/draftbot"
|
||||||
|
|
||||||
|
@ -57,6 +59,9 @@ func main() {
|
||||||
|
|
||||||
initTemplates()
|
initTemplates()
|
||||||
|
|
||||||
|
// Seed RNG
|
||||||
|
rand.Seed(time.Now().UnixNano())
|
||||||
|
|
||||||
logger = log.NewLogfmtLogger(os.Stderr)
|
logger = log.NewLogfmtLogger(os.Stderr)
|
||||||
logger = log.With(logger, "ts", log.DefaultTimestampUTC)
|
logger = log.With(logger, "ts", log.DefaultTimestampUTC)
|
||||||
logger = log.With(logger, "caller", log.DefaultCaller)
|
logger = log.With(logger, "caller", log.DefaultCaller)
|
||||||
|
|
Loading…
Reference in a new issue