I've recently setup an ec-2 instance to deploy a meteor application on AWS. My app works correctly with mongoDB database.
Now I want to connect my meteor project's database to the EC2 database and then I've tried some command lines :
start my meteor project with a new mongo url with the following command line : "MONGO_URL="mongodb://username:[email protected]:27017/Tasks" meteor" but it returns the following screen
connect to mongo with the other following command line : "meteor mongo --url xx.xx.xxx.xxx:27017" but it returns a timeout. I thought it was due to the lack of username and password however when I add this option meteor does not assume the command.
connect to mongo in my js collection file with "export const Tasks = mongoose.connect("mongodb://username:[email protected]:27017/Tasks").connection;" but it returns "Error: connect ECONNREFUSED" (second screen)
Is there any tips to manage to establish database connection from local meteor ?
Thank you for answer,
Martin
mongoose.connect
line, are you using mongoose? – corvid