Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // config/env/production.js
- module.exports = {
- connection: 'mongo_production'
- };
- // config/models.js
- module.exports.models = {
- // connection: 'localDiskDb'
- };
- // config/connections.js
- module.exports.connections = {
- mongo_development: {
- adapter: 'sails-mongo',
- host: 'localhost',
- port: 27017,
- user: '',
- password: '',
- database: 'my_local_db'
- },
- mongo_production: {
- adapter: 'sails-mongo',
- url: 'mongodb://me:mypw@foobar.mongohq.com:10052/my_production_db'
- }
- };
- module.exports = {
- models: {
- connection: 'mongo_production'
- }
- };
- module.exports = {
- // port: process.env.PORT || 1337, // comment this line if you want to set the different ports for different modes
- environment: process.env.NODE_ENV || 'development'
- };
- module.exports = {
- port: 8080, // will change from default port 1337 to 8080
- models: {
- connection: 'developement_db',
- migrate: 'alter'
- }
- };
- module.exports = {
- port: 9090, // will change from default port 1337 to 9090
- models: {
- connection: 'production_db',
- migrate: 'safe'
- }
- };
Add Comment
Please, Sign In to add comment