Add auto-login
This commit is contained in:
parent
59ffdbf6f8
commit
cb52f6d07d
6 changed files with 108 additions and 1 deletions
|
@ -38,6 +38,10 @@ var (
|
|||
RunUser string
|
||||
RepoRootPath string
|
||||
|
||||
LogInRememberDays int
|
||||
CookieUserName string
|
||||
CookieRememberName string
|
||||
|
||||
Cfg *goconfig.ConfigFile
|
||||
MailService *Mailer
|
||||
|
||||
|
@ -252,6 +256,10 @@ func NewConfigContext() {
|
|||
SecretKey = Cfg.MustValue("security", "SECRET_KEY")
|
||||
RunUser = Cfg.MustValue("", "RUN_USER")
|
||||
|
||||
LogInRememberDays = Cfg.MustInt("security", "LOGIN_REMEMBER_DAYS")
|
||||
CookieUserName = Cfg.MustValue("security", "COOKIE_USERNAME")
|
||||
CookieRememberName = Cfg.MustValue("security", "COOKIE_REMEMBER_NAME")
|
||||
|
||||
PictureService = Cfg.MustValue("picture", "SERVICE")
|
||||
PictureRootPath = Cfg.MustValue("picture", "PATH")
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue