mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2025-02-17 03:45:13 +00:00
custom session expiration
This commit is contained in:
parent
c30198e412
commit
10b47c69e4
1 changed files with 1 additions and 1 deletions
|
@ -152,7 +152,7 @@ func GetLoginToken(c *gin.Context) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
exp := time.Now().Add(time.Hour * 72).Unix()
|
exp := time.Now().Add(Config.Server.SessionExpires).Unix()
|
||||||
token := token.New(token.SessToken, user.Login)
|
token := token.New(token.SessToken, user.Login)
|
||||||
tokenstr, err := token.SignExpires(user.Hash, exp)
|
tokenstr, err := token.SignExpires(user.Hash, exp)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
Loading…
Reference in a new issue