mirror of
https://github.com/discourse/discourse.git
synced 2024-12-01 03:53:43 +08:00
0ed42707cc
Hardcoding the Redis DB and Redis Caching DB to 0 and 2 in `config/database.yml` makes an unsafe assumption that Discourse is the only application using that install of redis-server. Instead of forcing users to undergo yet another form of configuration, allow Discourse admins a nicer way to configure the Redis databases used. Signed-off-by: David Celis <me@davidcel.is>
23 lines
374 B
YAML
23 lines
374 B
YAML
defaults: &defaults
|
|
host: <%= GlobalSetting.redis_host %>
|
|
port: <%= GlobalSetting.redis_port %>
|
|
password: <%= GlobalSetting.redis_password %>
|
|
db: <%= GlobalSetting.redis_db %>
|
|
cache_db: <%= GlobalSetting.redis_cache_db %>
|
|
|
|
development:
|
|
<<: *defaults
|
|
|
|
profile:
|
|
<<: *defaults
|
|
|
|
test:
|
|
<<: *defaults
|
|
db: 1
|
|
|
|
staging:
|
|
<<: *defaults
|
|
|
|
production:
|
|
<<: *defaults
|