Guardian v1.0.0-beta.1 Guardian.Config View Source
Working with configuration for guardian.
Link to this section Summary
Types
Configuration values can be given using the following types
Functions
Resolves possible values from a configuration
Link to this section Types
Configuration values can be given using the following types:
{:system, "FOO"}
- Read from the system environment{MyModule, :function_name}
- To call a function and use the result{MyModule, :func, [:some, :args]}
Calls the function on the module with argsfn -> :some_value end
- an anonymous function whose result will be used- any other value
Link to this section Functions
Resolves possible values from a configuration.
{:system, "FOO"}
- reads “FOO” from the environment{m, f}
- Calls functionf
on modulem
and returns the result{m, f, a}
- Calls functionf
on modulem
with argumentsa
and returns the resultf
- Calls the functionf
and returns the result- value - Returns other values as is