summaryrefslogtreecommitdiffstats
path: root/routers/install.go
diff options
context:
space:
mode:
authorUnknwon <u@gogs.io>2015-09-13 12:14:32 -0400
committerUnknwon <u@gogs.io>2015-09-13 12:14:32 -0400
commit5f1183cecf4f3c6bf677369c4e2a2788b795ab15 (patch)
tree84d66a1f584aebb3ec2a8e9e4e53c7ee6d8d738d /routers/install.go
parentb0bf4cc1cb6e68968fa4a6076f57045a268026e9 (diff)
downloadgitea-5f1183cecf4f3c6bf677369c4e2a2788b795ab15.tar.gz
gitea-5f1183cecf4f3c6bf677369c4e2a2788b795ab15.zip
#697 add install option
Diffstat (limited to 'routers/install.go')
-rw-r--r--routers/install.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/routers/install.go b/routers/install.go
index 8daf889687..b6ac99cd7a 100644
--- a/routers/install.go
+++ b/routers/install.go
@@ -151,6 +151,7 @@ func Install(ctx *middleware.Context) {
form.OfflineMode = setting.OfflineMode
form.DisableGravatar = setting.DisableGravatar
form.DisableRegistration = setting.Service.DisableRegistration
+ form.EnableCaptcha = setting.Service.EnableCaptcha
form.RequireSignInView = setting.Service.RequireSignInView
auth.AssignForm(form, ctx.Data)
@@ -301,6 +302,7 @@ func InstallPost(ctx *middleware.Context, form auth.InstallForm) {
cfg.Section("server").Key("OFFLINE_MODE").SetValue(com.ToStr(form.OfflineMode))
cfg.Section("picture").Key("DISABLE_GRAVATAR").SetValue(com.ToStr(form.DisableGravatar))
cfg.Section("service").Key("DISABLE_REGISTRATION").SetValue(com.ToStr(form.DisableRegistration))
+ cfg.Section("service").Key("ENABLE_CAPTCHA").SetValue(com.ToStr(form.EnableCaptcha))
cfg.Section("service").Key("REQUIRE_SIGNIN_VIEW").SetValue(com.ToStr(form.RequireSignInView))
cfg.Section("").Key("RUN_MODE").SetValue("prod")