yggdrasil_redis v4.1.0 Yggdrasil.Settings.Redis View Source
This module defines the available settings for Redis in Yggdrasil.
Link to this section Summary
Functions
Redis database. Defaults to 0
Redis hostname. Defaults to "localhost"
Redis password. Defaults to nil
Redis port. Defaults to 6379
Link to this section Functions
Redis database. Defaults to 0
.
It looks for the value following this order:
- The OS environment variable
$YGGDRASIL_REDIS_DATABASE
. - The configuration file.
- The default value
0
.
If the database is defined using a namespace, then the name of the OS
variable should be $<NAMESPACE>_YGGDRASIL_REDIS_DATABASE
where NAMESPACE
is the snake case version of the actual namespace e.g MyApp.Namespace
would
be MYAPP_NAMESPACE
.
config :yggdrasil, <NAMESPACE>
redis: [database: 0]
Redis hostname. Defaults to "localhost"
.
It looks for the value following this order:
- The OS environment variable
$YGGDRASIL_REDIS_HOSTNAME
. - The configuration file.
- The default value
"localhost"
If the hostname is defined using a namespace, then the name of the OS
variable should be $<NAMESPACE>_YGGDRASIL_REDIS_HOSTNAME
where NAMESPACE
is the snake case version of the actual namespace e.g MyApp.Namespace
would
be MYAPP_NAMESPACE
.
config :yggdrasil, <NAMESPACE>
redis: [hostname: "localhost"]
Redis password. Defaults to nil
.
It looks for the value following this order:
- The OS environment variable
$YGGDRASIL_REDIS_PASSWORD
. - The configuration file.
- The default value
nil
.
If the password is defined using a namespace, then the name of the OS
variable should be $<NAMESPACE>_YGGDRASIL_REDIS_PASSWORD
where NAMESPACE
is the snake case version of the actual namespace e.g MyApp.Namespace
would
be MYAPP_NAMESPACE
.
config :yggdrasil, <NAMESPACE>
redis: [password: nil]
Redis port. Defaults to 6379
.
It looks for the value following this order:
- The OS environment variable
$YGGDRASIL_REDIS_PORT
. - The configuration file.
- The default value
6379
.
If the port is defined using a namespace, then the name of the OS variable
should be $<NAMESPACE>_YGGDRASIL_REDIS_PORT
where NAMESPACE
is the snake
case version of the actual namespace e.g MyApp.Namespace
would
be MYAPP_NAMESPACE
.
config :yggdrasil, <NAMESPACE>
redis: [port: 6379]