Auth: You can now authenicate against api with username / password using basic auth, Closes #2218

This commit is contained in:
Torkel Ödegaard
2015-06-30 09:37:52 +02:00
parent d0e7d53c69
commit ae0f8c77d1
8 changed files with 126 additions and 0 deletions
+6
View File
@@ -94,6 +94,9 @@ var (
AuthProxyHeaderProperty string
AuthProxyAutoSignUp bool
// Basic Auth
BasicAuthEnabled bool
// Session settings.
SessionOptions session.Options
@@ -398,6 +401,9 @@ func NewConfigContext(args *CommandLineArgs) {
AuthProxyHeaderProperty = authProxy.Key("header_property").String()
AuthProxyAutoSignUp = authProxy.Key("auto_sign_up").MustBool(true)
authBasic := Cfg.Section("auth.basic")
AuthProxyEnabled = authBasic.Key("enabled").MustBool(true)
// PhantomJS rendering
ImagesDir = filepath.Join(DataPath, "png")
PhantomDir = filepath.Join(HomePath, "vendor/phantomjs")