I have registered a VPS with DirectAdmin, running CentOS and I'm using a domain which I registered from a different site. I've done the necessary configuration to make the domain display the default page of the VPS. I've also installed node.js and mongoDB using CentOS, but I'm stuck on getting to run the appliction. I've set a .conf file for MongoDB where bind_ip is set to the IP of the VPS and when I try to run MongoDB on port 27017, I get the following message:
service mongod start Starting mongod: [ OK ] bash: /var/log/mongodb/mongodb.log: Permission denied
I think this is caused by the fact that I didn't do any authorization for the VPS, but I couldn't find out how to do authorization. What am I doing wrong?
Also, I can't get node.js to run properly. When I run a basic node.js app on CentOS, port 3000, everything seems to be fine, but when I visit my domainname or VPS IP on port 3000, the server doesn't respond. How do I solve this? Do I need to configure ports on my VPS to make the server respond?
When opening the domain without specifying the port on a browser, how can I configure the VPS to connect to the node application, instead of showing the default index.html page?
I don't have any experience on configuring node.js on a VPS, so my final question: are there any tutorials on getting to run node.js with MongoDB on a VPS? Thanks in advance.
Edit: I solved the MongoDB issue by simply reinstalling it. I guess something went wrong during the installation the first time.