mirror of
https://github.com/matrix-org/dendrite.git
synced 2026-01-07 06:03:09 -06:00
Enable SSO in CI.
This commit is contained in:
parent
ac706be242
commit
80fa0bcb4c
|
|
@ -82,6 +82,27 @@ func main() {
|
||||||
if *defaultsForCI {
|
if *defaultsForCI {
|
||||||
cfg.AppServiceAPI.DisableTLSValidation = true
|
cfg.AppServiceAPI.DisableTLSValidation = true
|
||||||
cfg.ClientAPI.RateLimiting.Enabled = false
|
cfg.ClientAPI.RateLimiting.Enabled = false
|
||||||
|
cfg.ClientAPI.Login.SSO.Enabled = true
|
||||||
|
cfg.ClientAPI.Login.SSO.Providers = []config.IdentityProvider{
|
||||||
|
{
|
||||||
|
ID: "github",
|
||||||
|
Name: "Fake GitHub",
|
||||||
|
OIDC: config.OIDC{
|
||||||
|
ClientID: "aclientid",
|
||||||
|
ClientSecret: "aclientsecret",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
ID: "google",
|
||||||
|
Name: "Fake Google",
|
||||||
|
Type: "oidc",
|
||||||
|
OIDC: config.OIDC{
|
||||||
|
ClientID: "aclientid",
|
||||||
|
ClientSecret: "aclientsecret",
|
||||||
|
DiscoveryURL: "https://accounts.google.com/.well-known/openid-configuration",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
cfg.FederationAPI.DisableTLSValidation = false
|
cfg.FederationAPI.DisableTLSValidation = false
|
||||||
// don't hit matrix.org when running tests!!!
|
// don't hit matrix.org when running tests!!!
|
||||||
cfg.FederationAPI.KeyPerspectives = config.KeyPerspectives{}
|
cfg.FederationAPI.KeyPerspectives = config.KeyPerspectives{}
|
||||||
|
|
|
||||||
|
|
@ -180,11 +180,13 @@ type IdentityProvider struct {
|
||||||
Type IdentityProviderType `yaml:"type"`
|
Type IdentityProviderType `yaml:"type"`
|
||||||
|
|
||||||
// OIDC contains settings for providers based on OpenID Connect (OAuth 2).
|
// OIDC contains settings for providers based on OpenID Connect (OAuth 2).
|
||||||
OIDC struct {
|
OIDC OIDC `yaml:"oidc"`
|
||||||
ClientID string `yaml:"client_id"`
|
}
|
||||||
ClientSecret string `yaml:"client_secret"`
|
|
||||||
DiscoveryURL string `yaml:"discovery_url"`
|
type OIDC struct {
|
||||||
} `yaml:"oidc"`
|
ClientID string `yaml:"client_id"`
|
||||||
|
ClientSecret string `yaml:"client_secret"`
|
||||||
|
DiscoveryURL string `yaml:"discovery_url"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (idp *IdentityProvider) Verify(configErrs *ConfigErrors) {
|
func (idp *IdentityProvider) Verify(configErrs *ConfigErrors) {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue