increase default token ttl to 6h

This commit is contained in:
David Zhao
2021-01-24 22:14:42 -08:00
parent 01d62edafa
commit b7a00a8a56
3 changed files with 5 additions and 3 deletions

View File

@@ -136,9 +136,9 @@ func Build() error {
}
// builds docker image for LiveKit server
func BuildDocker() error {
func Docker() error {
mg.Deps(Proto, generateWire)
cmd := exec.Command("docker", "build", ".", "-t", "livekit/livekit:v"+version.Version)
cmd := exec.Command("docker", "build", ".", "-t", "livekit/livekit-server:v"+version.Version)
connectStd(cmd)
if err := cmd.Run(); err != nil {
return err

View File

@@ -8,7 +8,7 @@ import (
)
const (
defaultValidDuration = 10 * time.Minute
defaultValidDuration = 6 * time.Hour
)
// Signer that produces token signed with API key and secret

View File

@@ -66,6 +66,8 @@ func (s *RTCService) ServeHTTP(w http.ResponseWriter, r *http.Request) {
return
}
// TODO: assign room to a node if for some reasons node isn't available
// upgrade only once the basics are good to go
conn, err := s.upgrader.Upgrade(w, r, nil)
if err != nil {