aboutsummaryrefslogtreecommitdiff
path: root/node_simple.js
diff options
context:
space:
mode:
authorNana Nosirova <nargiza.nosirova@mail.utoronto.ca>2018-07-17 02:44:10 +0000
committerGitHub <noreply@github.com>2018-07-17 02:44:10 +0000
commitc9f4e0e9df821c305b9606bd9575d3092384205b (patch)
treea0e68cc4687d3ffa8245fdeffd5eb81434779be8 /node_simple.js
parent541341598d5ed0e5c8ef9b2325dc6bbec958463a (diff)
parentcbccf154d96abadd5bf3dc0bdcf379d02101f221 (diff)
Merge pull request #2 from kdam0/feat/SR-1
Feat/sr-1
Diffstat (limited to 'node_simple.js')
-rw-r--r--node_simple.js10
1 files changed, 8 insertions, 2 deletions
diff --git a/node_simple.js b/node_simple.js
index 2f49360..f7d2289 100644
--- a/node_simple.js
+++ b/node_simple.js
@@ -103,8 +103,14 @@ var _ = require('underscore');
var db;
// Standard URI format: mongodb://[dbuser:dbpassword@]host:port/dbname
-var uri = exports.uri = 'mongodb://general:assignment4@ds057862.mlab.com:57862/solutions_repo';
-
+if (process.env.NODE_ENV == 'staging') {
+ var uri = exports.uri = 'mongodb://root:solutions_repo@ds023624.mlab.com:23624/solutions_staging';
+} else if (process.env.NODE_ENV == 'production') {
+ var uri = exports.uri = 'mongodb://general:assignment4@ds057862.mlab.com:57862/solutions_repo';
+} else if (process.env.NODE_ENV == 'development') {
+ // Keep this for testing on local machine, do not remove. - Humair
+ //var uri = 'mongodb://localhost:27017/db';
+}
// Keep this for testing on local machine, do not remove. - Humair
//var uri = 'mongodb://localhost:27017/db';