From 311df9c521f05cdca880152e73dbed47afb74cde Mon Sep 17 00:00:00 2001 From: haixunlu Date: Tue, 18 Dec 2018 12:49:30 -0800 Subject: auth: add new authentication source: GitHub, including GitHub Enterprise (#5340) * Add new Authentication Source: GitHub, including GitHub Enterprise. * Add vendor dependencies. --- pkg/form/auth.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'pkg/form') diff --git a/pkg/form/auth.go b/pkg/form/auth.go index b2ee3ae8..65f5eac0 100644 --- a/pkg/form/auth.go +++ b/pkg/form/auth.go @@ -11,7 +11,7 @@ import ( type Authentication struct { ID int64 - Type int `binding:"Range(2,5)"` + Type int `binding:"Range(2,6)"` Name string `binding:"Required;MaxSize(30)"` Host string Port int @@ -41,6 +41,7 @@ type Authentication struct { TLS bool SkipVerify bool PAMServiceName string + GithubApiEndpoint string `binding:Required;Url` } func (f *Authentication) Validate(ctx *macaron.Context, errs binding.Errors) binding.Errors { -- cgit v1.2.3