mix ash_authentication.add_strategy.dynamic_oidc (ash_authentication v5.0.0-rc.9)

Copy Markdown View Source

Adds a data-driven OIDC strategy + OidcConnection resource

Generates a OidcConnection resource (in your accounts namespace) for storing per-tenant/per-customer OIDC client configuration, then wires a dynamic_oidc :sso strategy into your user resource that looks up the connection at request time.

The shape of the generated connection resource includes base_url, client_id, client_secret (sensitive), display_name, and icon_url string attributes plus a default bypass policy for AshAuthentication interactions. You're expected to add multitenancy and any custom write-side policies yourself.

See the AshAuthentication.Strategy.DynamicOidc and AshAuthentication.OidcConnection moduledocs for runtime details.

Example

mix ash_authentication.add_strategy.dynamic_oidc

Options

  • --user, -u — The user resource. Defaults to YourApp.Accounts.User.
  • --accounts, -a — The accounts domain. Defaults to YourApp.Accounts.
  • --identity-field, -i — The user attribute used to identify users. Defaults to email.
  • --connection, -c — The OidcConnection resource name. Defaults to <accounts>.OidcConnection.
  • --name, -n — The strategy name. Defaults to sso.

Summary

Functions

igniter(igniter)

Callback implementation for Igniter.Mix.Task.igniter/1.