Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make connection an environment variable instead of hard-coded #2

Open
OKNoah opened this issue Dec 12, 2015 · 1 comment
Open

Make connection an environment variable instead of hard-coded #2

OKNoah opened this issue Dec 12, 2015 · 1 comment

Comments

@OKNoah
Copy link
Contributor

OKNoah commented Dec 12, 2015

In api/config/databse.js it would be better to have a process.env.MONGO_URL or something rather than a hard-coded connection URL. Then the environment can be passed to the app like env MONGO_URL=mongodb://localhost/test or put in an env file, for example.

@OKNoah
Copy link
Contributor Author

OKNoah commented Dec 13, 2015

Also, I feel like it should support full mongo URLs, like mongodb://username:password@server.tld/database. If uploaded to Heroku, for example, the add-ons there will pass this in as an environmental variable in this format. I looked at doing this myself, but I haven't spent enough time with Waterline.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant