What are the steps for deploying a Node js app, with express.js framework and MongoDB as database on AWS? This is my first such activity and I am not able to find any reliable source over the net.
MongoDB is an AWS Partner. To launch a fully managed MongoDB cluster on AWS, try it for free from AWS Marketplace. AWS Service Catalog administrators can add this architecture to their own catalog.
To set up an AWS Node. js environment in which you can run your application, use any of the following methods: Choose an Amazon Machine Image (AMI) with Node. js pre-installed and create an Amazon EC2 instance using that AMI.
In the Amazon EC2 console, choose the instance, and then choose Connect. Once you connect to the bastion host instance by using SSH, you can connect to any of the MongoDB nodes in a similar fashion (choose the node, and then choose Connect to find the SSH command).
For a fully managed MongoDB cluster, try it for free on AWS Marketplace. This Quick Start is for developers and DevOps professionals who want to deploy a flexible, fully managed databases on AWS using MongoDB Atlas.
Deploy nodejs-express-mongoDB
backend on AWS EC2 Ubuntu(16.04)
Back-end is a private repo on Gitlab.
Steps: 1: Create EC2 Ubuntu server on AWS,
create EC2 instance
2: Connect personal computer with AWS server - use to control cloud Ubuntu server on personal computer,
Connecting Linux Instance from Windows Using PuTTY
3: Clone repo from Gitlab to Ubuntu server,
Configure ssh key on linux server
Clone gitlab repo to linux server
4: Install Nodejs and MongoDB on Ubuntu server,
Install Nodejs
Install MongoDB
Install MongoDB
5: Launch MongoDB and run Nodejs to start node server,
6: Test back-end server using Postman or Browser.
Other useful linkYouTube
AWS has a full documentation for this on their website. These documentations are extremely thorough and you should read these first.
Here's a tutorial from 2015.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With