setting_oauth.go 360 B

1234567891011121314151617
  1. package setting
  2. type OAuthInfo struct {
  3. ClientId, ClientSecret string
  4. Scopes []string
  5. AuthUrl, TokenUrl string
  6. Enabled bool
  7. AllowedDomains []string
  8. ApiUrl string
  9. }
  10. type OAuther struct {
  11. GitHub, Google, Twitter bool
  12. OAuthInfos map[string]*OAuthInfo
  13. }
  14. var OAuthService *OAuther