mirror of
https://github.com/gogs/gogs.git
synced 2025-12-21 15:50:00 +01:00
Set ProdMode in the correct place
Closes #3696, #3611 Previously, ProdMode can only be true for web server, which always prints dev mode log message to incoming SSH connections and leaks unexpected information.
This commit is contained in:
@@ -490,6 +490,8 @@ func NewContext() {
|
||||
}
|
||||
}
|
||||
|
||||
ProdMode = Cfg.Section("").Key("RUN_MODE").String() == "prod"
|
||||
|
||||
// Determine and create root git repository path.
|
||||
sec = Cfg.Section("repository")
|
||||
RepoRootPath = sec.Key("ROOT").MustString(path.Join(homeDir, "gogs-repositories"))
|
||||
|
||||
Reference in New Issue
Block a user