223385d134
POSTGRES_PORT was not taking effect if provided separately instead of using DATABASE_URL. This adds support for using databases running on non-standard ports. #1145 #1147 Co-authored-by: Pranav Raj S <pranav@chatwoot.com>
24 lines
868 B
YAML
24 lines
868 B
YAML
default: &default
|
|
adapter: postgresql
|
|
encoding: unicode
|
|
pool: <%= ENV.fetch("RAILS_MAX_THREADS") { 5 } %>
|
|
host: <%= ENV.fetch('POSTGRES_HOST', 'localhost') %>
|
|
port: <%= ENV.fetch('POSTGRES_PORT', '5432') %>
|
|
|
|
development:
|
|
<<: *default
|
|
database: <%= ENV.fetch('POSTGRES_DATABASE', 'chatwoot_dev') %>
|
|
username: <%= ENV.fetch('POSTGRES_USERNAME', 'postgres') %>
|
|
password: <%= ENV.fetch('POSTGRES_PASSWORD', '') %>
|
|
|
|
test:
|
|
<<: *default
|
|
database: <%= ENV.fetch('POSTGRES_DATABASE', 'chatwoot_test') %>
|
|
username: <%= ENV.fetch('POSTGRES_USERNAME', 'postgres') %>
|
|
password: <%= ENV.fetch('POSTGRES_PASSWORD', '') %>
|
|
|
|
production:
|
|
<<: *default
|
|
database: <%= ENV.fetch('POSTGRES_DATABASE', 'chatwoot_production') %>
|
|
username: <%= ENV.fetch('POSTGRES_USERNAME', 'chatwoot_prod') %>
|
|
password: <%= ENV.fetch('POSTGRES_PASSWORD', 'chatwoot_prod') %>
|