Coherence v0.1.3 Coherence.Config
Coherence Configuration Module.
Provides a small wrapper around Application.get_env :coherence
, providing an accessor function for each configuration items.
Configuration items can be defined as either a single atom or {name, default} tuple. Each of the items can be included in your config/config.exs
file.
The following items are supported:
- :module: the name of project module (
module: MyProject
) - :repo: the module name of your Repo (
repo: MyProject.Repo
) - :user_schema
- :schema_key
- :logged_out_url
- :email_from
- :email_reply_to
- :site_name - The site name used for email
- :login_cookie (“coherence_login”) - The name of the login cookie
- :auth_module (Coherence.Authentication.Session)
- :create_login (:create_login)
- :delete_login (:delete_login})
- :opts ([])
- :reset_token_expire_days (2)
- :confirmation_token_expire_days (5)
- :max_failed_login_attempts (5)
- :unlock_timeout_minutes (20)
- :unlock_token_expire_minutes (5)
- :session_key (“session_auth”)
- :rememberable_cookie_expire_hours (2*24)
- :password_hash_field (:password_hash) - The field used to save the hashed password
- :login_field (:email) - The user model field used to login
Examples
alias Coherence.Config
Config.module