changed sso parameters
This commit is contained in:
@@ -17,8 +17,10 @@
|
|||||||
# After deploying Mastodon, register an OAuth application at
|
# After deploying Mastodon, register an OAuth application at
|
||||||
# https://social.wyattjmiller.com/settings/applications and write the
|
# https://social.wyattjmiller.com/settings/applications and write the
|
||||||
# client ID / secret to these paths (chmod 400, owned by the tuwunel user):
|
# client ID / secret to these paths (chmod 400, owned by the tuwunel user):
|
||||||
mastodonOauthClientIdFile = "/var/lib/tuwunel/mastodon-oauth-client-id";
|
mastodonOauthClientIdFile = "/var/lib/private/tuwunel/matrix-oauth-client-id";
|
||||||
mastodonOauthClientSecretFile = "/var/lib/tuwunel/mastodon-oauth-client-secret";
|
mastodonOauthClientSecretFile = "/var/lib/private/tuwunel/matrix-oauth-client-secret";
|
||||||
|
mastodonOauthClientId = builtins.readFile mastodonOauthClientIdFile;
|
||||||
|
mastodonOauthClientSecret = builtins.readFile mastodonOauthClientSecretFile;
|
||||||
in {
|
in {
|
||||||
imports = [
|
imports = [
|
||||||
../../pwrMgmt
|
../../pwrMgmt
|
||||||
@@ -200,10 +202,13 @@ in {
|
|||||||
{
|
{
|
||||||
brand = "Mastodon";
|
brand = "Mastodon";
|
||||||
issuer_url = "https://${mastodonFqdn}";
|
issuer_url = "https://${mastodonFqdn}";
|
||||||
id = "oidc-mastodon";
|
id = mastodonOauthClientId;
|
||||||
client_id = mastodonOauthClientIdFile;
|
callback_url = "https://${matrixFqdn}/_matrix/client/v3/login/sso/callback/${mastodonOauthClientId}";
|
||||||
client_secret = mastodonOauthClientSecretFile;
|
discovery_url = "https://${mastodonFqdn}/.well-known/oauth-authorization-server";
|
||||||
scope = ["openid" "read:accounts"];
|
client_id = mastodonOauthClientId;
|
||||||
|
client_secret = mastodonOauthClientSecret;
|
||||||
|
scope = ["profile"];
|
||||||
|
userid_claims = ["preferred_username"];
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user