Access rules for the restriction chains, stored in Sovite's database
and managed with sovitectl access.
As a Sovite.Core.Lookup table, the handle names the kind of rule:
:client, :helo, :sender, or :recipient.
A lookup returns the action and its text, as an access(5) table
would.
Summary
Functions
Deletes the rule for kind and pattern.
Lists all rules, by kind and pattern.
Sets the rule for kind and pattern, replacing any earlier one.
Functions
@spec delete(Sovite.Core.Repo.t(), atom(), String.t()) :: :ok | {:error, :not_found}
Deletes the rule for kind and pattern.
@spec list(Sovite.Core.Repo.t()) :: [Sovite.Core.Repo.Schemas.AccessRule.t()]
Lists all rules, by kind and pattern.
@spec set( Sovite.Core.Repo.t(), atom() | String.t(), String.t(), String.t(), String.t() | nil ) :: {:ok, Sovite.Core.Repo.Schemas.AccessRule.t()} | {:error, Ecto.Changeset.t()}
Sets the rule for kind and pattern, replacing any earlier one.