-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathconfig.go
35 lines (29 loc) · 1.17 KB
/
config.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
package idp
type Config struct {
Host string `mapstructure:"host"`
Services []Service `mapstructure:"services"`
Users []User `mapstructure:"users"`
LoginPage LoginPageOptions `mapstructure:"login_page"`
// Optional. If empty, an auto-generated certificate and key will be used
CertificatePath string `mapstructure:"certificate"`
KeyPath string `mapstructure:"key"`
// Optional. The number of minutes that the SAML session is valid for. Defaults to 60
SessionMaxAge int `mapstructure:"session_max_age"`
}
type Service struct {
EntityId string `mapstructure:"entity_id"`
AssertionConsumerService string `mapstructure:"assertion_consumer_service"`
}
type User struct {
Username string `mapstructure:"username"`
Email string `mapstructure:"email"`
Password string `mapstructure:"password"`
FirstName string `mapstructure:"first_name"`
LastName string `mapstructure:"last_name"`
Groups []string `mapstructure:"groups"`
}
type LoginPageOptions struct {
Title string `mapstructure:"title"`
Description string `mapstructure:"description"`
DumpUsers bool `mapstructure:"dump_users"`
}