AshAuthentication.Oauth2Server.Supervisor (ash_authentication_oauth2_server v0.2.1)

Copy Markdown View Source

Supervises the background processes for an OAuth2 server.

Add this to your application's supervision tree, passing your OTP app name:

defmodule MyApp.Application do
  use Application

  def start(_type, _args) do
    children = [
      # ...
      {AshAuthentication.Oauth2Server.Supervisor, otp_app: :my_app}
    ]

    Supervisor.start_link(children, strategy: :one_for_one)
  end
end

Options

  • :otp_app (required) — your application's OTP app name.
  • :list_tenants — for apps using strategy :context multitenancy on the OAuth2 resources. Accepts a static list of tenant identifiers, a 0-arity function, or an {module, function, args} tuple. The expunger will run once per tenant per resource per interval. Defaults to [nil] (single tenant-less pass — correct for apps with no multitenancy or global? true attribute multitenancy).

Currently this supervisor starts:

Summary

Functions

Returns a specification to start this module under a supervisor.

Functions

child_spec(init_arg)

Returns a specification to start this module under a supervisor.

See Supervisor.