@@ -5,11 +5,7 @@ development:
5
5
default :
6
6
# Defines the name of the default database that Mongoid can connect to.
7
7
# (required).
8
- database : dashboard_development
9
- # Provides the hosts the default client can connect to. Must be an array
10
- # of host:port pairs. (required)
11
- hosts :
12
- - <%= ENV.fetch('MONGO_TCP_ADDR', '127.0.0.1') %>:<%= ENV.fetch('MONGO_TCP_PORT', '27017') %>
8
+ uri : <%= ENV.fetch('MONGODB_URI', 'mongodb://127.0.0.1:27017/dashboard_development') %>
13
9
options :
14
10
# Change the default write concern. (default = { w: 1 })
15
11
# write:
@@ -148,9 +144,7 @@ development:
148
144
test :
149
145
clients :
150
146
default :
151
- database : dashboard_test
152
- hosts :
153
- - <%= ENV.fetch('MONGO_TCP_ADDR', '127.0.0.1') %>:<%= ENV.fetch('MONGO_TCP_PORT', '27017') %>
147
+ uri : <%= ENV.fetch('MONGODB_URI', 'mongodb://127.0.0.1:27017/dashboard_test') %>
154
148
options :
155
149
raise_not_found_error : false
156
150
read :
@@ -166,10 +160,7 @@ production:
166
160
# A session can have any number of hosts. Usually 1 for a single
167
161
# server setup, and at least 3 for a replica set. Hosts must be
168
162
# an array of host:port pairs. This session is single server.
169
- hosts :
170
- - <%= ENV.fetch('MONGO_TCP_ADDR', '127.0.0.1') %>:<%= ENV.fetch('MONGO_TCP_PORT', '27017') %>
171
- # Define the default database name.
172
- database : heimdall2_production
163
+ uri : <%= ENV.fetch('MONGODB_URI', 'mongodb://127.0.0.1:27017/heimdall2_production') %>
173
164
# Since this database points at a session connected to MongoHQ, we must
174
165
# provide the authentication details.
175
166
# username: user
0 commit comments