diff options
author | Unknwon <u@gogs.io> | 2016-08-27 12:25:22 -0700 |
---|---|---|
committer | Unknwon <u@gogs.io> | 2016-08-27 12:25:22 -0700 |
commit | 13a8823bd33e769565c0b505d9bb26f073c7e243 (patch) | |
tree | 10ba95a55dbd5148c47b608fe886d752b217e09e | |
parent | bbca2916f7d2df9088fc9e4d76fc71c905eb06f0 (diff) | |
download | gitea-13a8823bd33e769565c0b505d9bb26f073c7e243.tar.gz gitea-13a8823bd33e769565c0b505d9bb26f073c7e243.zip |
#3495 only start builtin SSH server after user finish installation
-rw-r--r-- | README.md | 2 | ||||
-rw-r--r-- | gogs.go | 2 | ||||
-rw-r--r-- | routers/install.go | 13 | ||||
-rw-r--r-- | templates/.VERSION | 2 |
4 files changed, 9 insertions, 10 deletions
@@ -3,7 +3,7 @@ Gogs - Go Git Service [ -##### Current tip version: 0.9.87 (see [Releases](https://github.com/gogits/gogs/releases) for binary versions) +##### Current tip version: 0.9.88 (see [Releases](https://github.com/gogits/gogs/releases) for binary versions) | Web | UI | Preview | |:-------------:|:-------:|:-------:| @@ -17,7 +17,7 @@ import ( "github.com/gogits/gogs/modules/setting" ) -const APP_VER = "0.9.87.0826" +const APP_VER = "0.9.88.0827" func init() { runtime.GOMAXPROCS(runtime.NumCPU()) diff --git a/routers/install.go b/routers/install.go index 54a98edcd2..9ab0a45968 100644 --- a/routers/install.go +++ b/routers/install.go @@ -57,21 +57,23 @@ func NewServices() { // GlobalInit is for global configuration reload-able. func GlobalInit() { setting.NewContext() - highlight.NewContext() log.Trace("Custom path: %s", setting.CustomPath) log.Trace("Log path: %s", setting.LogRootPath) models.LoadConfigs() NewServices() if setting.InstallLock { + highlight.NewContext() + markdown.BuildSanitizer() + models.LoadRepoConfig() models.NewRepoContext() - if err := models.NewEngine(); err != nil { log.Fatal(4, "Fail to initialize ORM engine: %v", err) } - models.HasEngine = true + + // Booting long running goroutines. cron.NewContext() models.InitDeliverHooks() models.InitTestPullRequests() @@ -88,13 +90,10 @@ func GlobalInit() { } checkRunMode() - if setting.SSH.StartBuiltinServer { + if setting.InstallLock && setting.SSH.StartBuiltinServer { ssh.Listen(setting.SSH.ListenPort) log.Info("SSH server started on :%v", setting.SSH.ListenPort) } - - // Build Sanitizer - markdown.BuildSanitizer() } func InstallInit(ctx *context.Context) { diff --git a/templates/.VERSION b/templates/.VERSION index 0337cf7ae9..a3ab1840a3 100644 --- a/templates/.VERSION +++ b/templates/.VERSION @@ -1 +1 @@ -0.9.87.0826
\ No newline at end of file +0.9.88.0827
\ No newline at end of file |