diff options
author | Unknwon <joe2010xtmf@163.com> | 2015-02-11 19:25:59 -0500 |
---|---|---|
committer | Unknwon <joe2010xtmf@163.com> | 2015-02-11 19:25:59 -0500 |
commit | c5c467a9cd805c7cd0fb93f467e0205ee082cca3 (patch) | |
tree | b4e617b52918b38e589ec2221eaf2bededd23f79 /modules/setting/setting.go | |
parent | c7a042ef3682fce9f343faf5e8d3e4228feabb96 (diff) | |
parent | 0af74b36add865445ed1d6cd649910d8bb82fe5e (diff) |
Merge branch 'dev' of github.com:gogits/gogs into access
Diffstat (limited to 'modules/setting/setting.go')
-rw-r--r-- | modules/setting/setting.go | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/modules/setting/setting.go b/modules/setting/setting.go index 55e0a79a..6664c419 100644 --- a/modules/setting/setting.go +++ b/modules/setting/setting.go @@ -68,8 +68,11 @@ var ( ReverseProxyAuthUser string // Webhook settings. - WebhookTaskInterval int - WebhookDeliverTimeout int + Webhook struct { + TaskInterval int + DeliverTimeout int + SkipTLSVerify bool + } // Repository settings. RepoRootPath string @@ -508,8 +511,10 @@ func newNotifyMailService() { } func newWebhookService() { - WebhookTaskInterval = Cfg.Section("webhook").Key("TASK_INTERVAL").MustInt(1) - WebhookDeliverTimeout = Cfg.Section("webhook").Key("DELIVER_TIMEOUT").MustInt(5) + sec := Cfg.Section("webhook") + Webhook.TaskInterval = sec.Key("TASK_INTERVAL").MustInt(1) + Webhook.DeliverTimeout = sec.Key("DELIVER_TIMEOUT").MustInt(5) + Webhook.SkipTLSVerify = sec.Key("SKIP_TLS_VERIFY").MustBool() } func NewServices() { |