{"id":574,"date":"2022-09-27T10:42:22","date_gmt":"2022-09-27T10:42:22","guid":{"rendered":"https:\/\/www.niraltek.com\/?p=574"},"modified":"2023-03-17T05:39:56","modified_gmt":"2023-03-17T05:39:56","slug":"how-to-deploy-angular-node-js-on-aws-ec2-instance","status":"publish","type":"post","link":"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/","title":{"rendered":"How to deploy Angular and Node.js on AWS EC2 instance?"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-post\" data-elementor-id=\"574\" class=\"elementor elementor-574\">\n\t\t\t\t\t\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-5090a3a4 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"5090a3a4\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-1e7a53f7\" data-id=\"1e7a53f7\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t\t\t<div class=\"elementor-element elementor-element-382ade0e elementor-widget elementor-widget-text-editor\" data-id=\"382ade0e\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t<style>\/*! elementor - v3.8.0 - 30-10-2022 *\/\n.elementor-widget-text-editor.elementor-drop-cap-view-stacked .elementor-drop-cap{background-color:#818a91;color:#fff}.elementor-widget-text-editor.elementor-drop-cap-view-framed .elementor-drop-cap{color:#818a91;border:3px solid;background-color:transparent}.elementor-widget-text-editor:not(.elementor-drop-cap-view-default) .elementor-drop-cap{margin-top:8px}.elementor-widget-text-editor:not(.elementor-drop-cap-view-default) .elementor-drop-cap-letter{width:1em;height:1em}.elementor-widget-text-editor .elementor-drop-cap{float:left;text-align:center;line-height:1;font-size:50px}.elementor-widget-text-editor .elementor-drop-cap-letter{display:inline-block}<\/style>\t\t\t\t<p><style><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">\ufeff<\/span><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">\ufeff<\/span><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">\ufeff<\/span><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\"><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">\ufeff<\/span>\ufeff<\/span><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">\ufeff<\/span><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">\ufeff<\/span><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">\ufeff<\/span>img {margin: 0 !important;} p {margin: 0 0 1em}<\/style><\/p><h1 style=\"text-align: center;\">\u00a0<\/h1><h6><span style=\"font-family: helvetica;\">A<b>fter installing angular in your local system follow the below procedure.<\/b><\/span><\/h6><blockquote><p><span style=\"font-family: helvetica; font-size: 14pt; color: #000000;\"><strong>Step1:<\/strong><\/span><\/p><\/blockquote><p><span style=\"font-family: helvetica;\">Create a new angular application:<\/span><\/p><div style=\"background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 4px; padding: 15px; width: 85%; margin-bottom: 15px;\"><span style=\"font-size: 12pt;\"><code style=\"color: #333333; line-height: 1.4;\">ng new angular-app<\/code><\/span><\/div><div><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-327 size-full\" src=\"http:\/\/localhost:8080\/wp-content\/uploads\/2022\/11\/create-angular-app-1.png\" sizes=\"(max-width: 603px) 100vw, 603px\" srcset=\"http:\/\/localhost:8080\/wp-content\/uploads\/2022\/11\/create-angular-app-1.png 603w, http:\/\/localhost:8080\/wp-content\/uploads\/2022\/11\/create-angular-app-1-300x95.png 300w\" alt=\"\" width=\"603\" height=\"191\" \/><\/div><div><span style=\"font-family: helvetica; margin: 0;\">\u00a0<\/span><\/div><div>\u00a0<\/div><h6><span style=\"font-family: helvetica;\">Ang<b>ular application view<\/b><\/span><\/h6><div><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-706 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-1024x477.jpg\" alt=\"angular\" width=\"640\" height=\"298\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-1024x477.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-300x140.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-768x357.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-1536x715.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app.jpg 1919w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/div><p><strong style=\"color: #000000; font-family: var( --e-global-typography-text-font-family ), Sans-serif;\"><span style=\"font-family: helvetica; font-size: 14pt;\">\u00a0<\/span><\/strong><\/p><blockquote><p><strong style=\"color: #000000; font-family: var( --e-global-typography-text-font-family ), Sans-serif;\"><span style=\"font-family: helvetica; font-size: 14pt;\">Step:2<\/span><\/strong><\/p><\/blockquote><p><strong style=\"color: #000000; font-family: var( --e-global-typography-text-font-family ), Sans-serif;\"><span style=\"font-family: helvetica; font-size: 14pt;\">\u00a0<\/span><\/strong><\/p><h5><strong><span style=\"font-family: helvetica; color: #000000;\">MySQL Database:<\/span><\/strong><\/h5><p><span style=\"font-family: helvetica;\">To be able to experiment with the code examples, you should have MySQL installed on your computer.<\/span><\/p><p><span style=\"font-family: helvetica;\">You can download a free MySQL database at<span style=\"color: #333333;\">\u00a0<a style=\"color: #333333;\" href=\"https:\/\/www.mysql.com\/downloads\/\">https:\/\/www.mysql.com\/downloads\/<\/a>.<\/span><\/span><\/p><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica; font-size: 12pt;\">Install MySQL Driver:<\/span><\/strong><\/span><\/h5><p style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"font-size: 12pt; font-family: helvetica; color: #333333;\">Once you have MySQL up and running on your computer, you can access it by using Node.js.<\/span><\/p><p style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"font-size: 12pt; font-family: helvetica; color: #333333;\">To access a MySQL database with Node.js, you need a MySQL driver. This tutorial will use the &#8220;MySQL&#8221; module, downloaded from NPM.<\/span><\/p><p><span style=\"font-family: helvetica; font-size: 12pt;\">To download and install the &#8220;MySQL&#8221; module, open the Command Terminal and execute the following:<\/span><\/p><p><span style=\"font-family: helvetica; font-size: 12pt;\">First, install npm and then install MySQL<\/span><\/p><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Create Node.js App:<\/span><\/strong><\/span><\/h5><p><span style=\"font-family: helvetica; font-size: 12pt;\">First, create a folder and name it MySQL -database.<\/span><\/p><p><span style=\"font-family: helvetica;\">Next, we initialize the Node.js App with a\u00a0<em>package.json<\/em>\u00a0file:<\/span><\/p><p style=\"background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 4px; padding: 15px; width: 85%; margin-bottom: 15px;\"><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">npm init<br \/><\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">package name: (mysql-database)<br \/><\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">version: (1.0.0)<br \/><\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">description: none<br \/><\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">entry point: (index.js) db-connections.js<br \/><\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">test command:<br \/><\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">git repository:<br \/><\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">keywords: nodejs, express, sequelize, mysql, rest, api<br \/><\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">author: Niraltek Solutions<br \/><\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">license: (ISC)<br \/><\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">About to write to D:\\mysql-database\\package.json:<\/span><\/code><\/p><div>\u00a0<\/div><div><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-771\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/npm-init.jpg\" alt=\"npm\" width=\"800\" height=\"376\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/npm-init.jpg 1104w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/npm-init-300x141.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/npm-init-1024x481.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/npm-init-768x361.jpg 768w\" sizes=\"(max-width: 800px) 100vw, 800px\" \/><\/div><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">\u00a0<\/span><\/strong><\/span><\/h5><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">NPM Install MySQL:<\/span><\/strong><\/span><\/h5><p><span style=\"font-family: helvetica;\">We need to install the necessary modules: <code>express<\/code>,\u00a0<code>sequelize<\/code>,\u00a0<code>mysql2<\/code>. <\/span><span style=\"font-family: helvetica;\">Run the command:<\/span><\/p><p style=\"background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 4px; padding: 15px; width: 85%; margin-bottom: 15px;\"><span style=\"font-size: 12pt;\"><code style=\"color: #333333; line-height: 1.4;\">npm install express sequelize mysql2 cors --save<\/code><\/span><\/p><div>\u00a0<\/div><div><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-789\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-express.jpg\" alt=\"express\" width=\"800\" height=\"287\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-express.jpg 1103w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-express-300x108.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-express-1024x368.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-express-768x276.jpg 768w\" sizes=\"(max-width: 800px) 100vw, 800px\" \/><\/div><p style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"font-size: 12pt; font-family: helvetica; color: black;\">Now you have downloaded and installed a MySQL database driver.<\/span><\/p><p style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"font-size: 12pt; font-family: helvetica; color: black;\">Node.js can use this module to manipulate the MySQL database:<\/span><\/p><p style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"font-size: 12pt; font-family: helvetica; color: black;\"><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-663 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/var-mysql-5.png\" alt=\"install mysql\" width=\"321\" height=\"74\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/var-mysql-5.png 321w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/var-mysql-5-300x69.png 300w\" sizes=\"(max-width: 321px) 100vw, 321px\" \/><\/span><\/p><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Create Connection:<\/span><\/strong><\/span><\/h5><p><span style=\"font-family: helvetica;\">Start by creating a connection to the database.<\/span><\/p><p><span style=\"font-family: helvetica;\">Use the username and password from your MySQL database.<\/span><\/p><p><span style=\"font-family: helvetica;\">db-connection.js<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-664 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connections.js-6.png\" alt=\"db connection\" width=\"378\" height=\"260\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connections.js-6.png 378w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connections.js-6-300x206.png 300w\" sizes=\"(max-width: 378px) 100vw, 378px\" \/><\/p><p><span style=\"font-family: helvetica;\">Save the code above in a file called &#8220;db_connection.js&#8221; and run the file:<\/span><\/p><h5 style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Run &#8220;db_connection.js&#8221;:<\/span><\/strong><\/span><\/h5><p style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"font-size: 12pt; font-family: Helvetica; color: #333333; background: white;\">Which will give you this result:<\/span><\/p><div style=\"background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 4px; padding: 15px; width: 85%; margin-bottom: 15px;\"><span style=\"font-size: 12pt;\"><code style=\"color: #333333; line-height: 1.4;\">node db-connection.js<\/code><\/span><\/div><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-792 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connection-1024x325.jpg\" alt=\"mysql\" width=\"640\" height=\"203\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connection-1024x325.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connection-300x95.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connection-768x244.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connection.jpg 1103w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><p style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"font-size: 12pt; font-family: Helvetica; color: #333333; background: white;\">Now you can start querying the database using SQL statements.<\/span><\/p><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica; font-size: 12pt;\">Database Query:<\/span><\/strong><\/span><\/h5><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-671 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/query-database-9.png\" alt=\"database query\" width=\"375\" height=\"165\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/query-database-9.png 375w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/query-database-9-300x132.png 300w\" sizes=\"(max-width: 375px) 100vw, 375px\" \/><\/p><p style=\"background: white; margin: 7.5pt 0in 7.5pt 0in;\"><span style=\"font-size: 12pt; font-family: Helvetica; color: black; background: white; font-weight: normal;\">The query method takes an SQL statement as a parameter and returns the result.<\/span><\/p><blockquote><p><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica; font-size: 14pt;\">Step3:<\/span><\/strong><\/span><\/p><\/blockquote><p><span style=\"font-family: helvetica; font-size: 12pt;\">After that just upload the source file to Github[Hope you have created an account on Github.com and a new repository. Install Git in your local system as well].<\/span><\/p><p><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica; font-size: 12pt;\">Git ADD file:<\/span><\/strong><\/span><\/p><p><span style=\"font-family: helvetica; font-size: 12pt;\">All files should be added to GitHub<\/span><\/p><div style=\"background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 4px; padding: 15px; width: 85%; margin-bottom: 15px;\"><span style=\"font-size: 12pt;\"><code style=\"color: #333333; line-height: 1.4;\">git add --a<\/code><\/span><\/div><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-803 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-add-1024x328.jpg\" alt=\"github\" width=\"640\" height=\"205\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-add-1024x328.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-add-300x96.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-add-768x246.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-add.jpg 1104w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Git Commit:<\/span><\/strong><\/span><\/h5><p><span style=\"font-family: helvetica;\">The git commit command captures a snapshot of the project&#8217;s currently committed changes.<\/span><\/p><div style=\"background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 4px; padding: 15px; width: 85%; margin-bottom: 15px;\"><span style=\"font-size: 12pt;\"><code style=\"color: #333333; line-height: 1.4;\">git commit -m \"first-commit\"<\/code><\/span><\/div><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-804 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-commit-1024x346.jpg\" alt=\"github\" width=\"640\" height=\"216\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-commit-1024x346.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-commit-300x101.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-commit-768x259.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-commit.jpg 1104w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><h5 style=\"background: white; margin: 7.5pt 0in 7.5pt 0in;\"><span style=\"color: #000000;\"><strong><span style=\"font-size: 12pt; font-family: Helvetica; background: white;\">Git Push:<\/span><\/strong><\/span><\/h5><p><span style=\"font-family: helvetica;\">The git push command is used to upload local repository content to a remote repository. Pushing is simply transferring commits from your local repository to a remote repo. This is parallel to receiving the kit, but receiving imports commits to local branches, pushing exports to remote branches.<\/span><\/p><div style=\"background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 4px; padding: 15px; width: 85%; margin-bottom: 15px;\"><code style=\"color: #333; line-height: 1.4; font-size: 13px;\"><span style=\"font-size: 12pt;\">git push<\/span><\/code><\/div><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-806 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-push-1024x346.jpg\" alt=\"github\" width=\"640\" height=\"216\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-push-1024x346.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-push-300x101.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-push-768x260.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-push.jpg 1103w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><blockquote style=\"background: white; margin: 7.5pt 0in 7.5pt 0in;\"><p><span style=\"color: #000000;\"><strong><span style=\"font-size: 14pt;\"><span style=\"font-family: Helvetica; background: white;\">Step4:<\/span><\/span><\/strong><\/span><\/p><\/blockquote><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica; font-size: 12pt;\">Create AWS EC2 Instance:<\/span><\/strong><\/span><\/h5><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-677 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/aws.png\" alt=\"amazon web service\" width=\"225\" height=\"135\" \/><\/p><p><span style=\"font-family: helvetica;\">AWS has made launching EC2 instances an easy task, but there are still many steps to the final result. Learn how to successfully create an EC2 instance from AWS Console.<\/span><\/p><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Select a region:<\/span><\/strong><\/span><\/h5><p><span style=\"font-family: helvetica;\">One of the most important steps is to select the desired AWS region. This can be done from the top navigation bar of the AWS Console.<\/span><\/p><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Navigate to the EC2 Console:<\/span><\/strong><\/span><\/h5><p><span style=\"font-family: helvetica; font-size: 12pt;\">Once you select the desired AWS region, go to the EC2 Console. From the same landing page, search for EC2 (Figure 1). Your landing page in the management interface will likely display EC2 among the most commonly used services in the account.<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-682 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/navigate-to-the-ec2-14.png\" alt=\"ec2\" width=\"602\" height=\"237\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/navigate-to-the-ec2-14.png 602w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/navigate-to-the-ec2-14-300x118.png 300w\" sizes=\"(max-width: 602px) 100vw, 602px\" \/><\/p><p style=\"text-align: center;\"><em><span style=\"font-family: helvetica; color: #808080;\">(figure 1)<\/span><\/em><\/p><p><span style=\"font-family: helvetica;\">Once you arrive at the EC2 Console, from the left navigation menu, choose the\u00a0Instances\u00a0option.<\/span><\/p><p><span style=\"font-family: helvetica;\">Under\u00a0Instances\u00a0is a list of the EC2 instances deployed in the account. There is also a\u00a0Launch instances\u00a0button on the top right section of this page; clicking on that button brings you to the EC2 instance launch flow (Figure 2).<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-684 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ec2-console-15.png\" alt=\"ec2\" width=\"502\" height=\"37\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ec2-console-15.png 502w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ec2-console-15-300x22.png 300w\" sizes=\"(max-width: 502px) 100vw, 502px\" \/><\/p><p style=\"text-align: center;\"><em><span style=\"font-family: helvetica; color: #808080;\">(figure 2)<\/span><\/em><\/p><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Create the EC2 instance:<\/span><\/strong><\/span><\/h5><p><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Launch Instance:<\/span><\/strong><\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-708 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/launch-instance-1024x418.jpg\" alt=\"aws\" width=\"640\" height=\"261\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/launch-instance-1024x418.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/launch-instance-300x122.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/launch-instance-768x314.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/launch-instance-1536x627.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/launch-instance.jpg 1729w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-687 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/lanuch-instance-17.png\" alt=\"AWS\" width=\"578\" height=\"262\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/lanuch-instance-17.png 578w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/lanuch-instance-17-300x136.png 300w\" sizes=\"(max-width: 578px) 100vw, 578px\" \/><\/p><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Choose Instance type:<\/span><\/strong><\/span><\/h5><p><span style=\"font-family: helvetica;\">Here you can choose your desired machine type. If you wish to get benefited using the free tier you can choose the t2.micro\u00a0type instance.<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-689 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/choose-instance-type-18.png\" sizes=\"(max-width: 609px) 100vw, 609px\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/choose-instance-type-18-300x74.png 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/choose-instance-type-18.png 602w\" alt=\"AWS\" width=\"602\" height=\"149\" \/><\/p><h5><strong><span style=\"font-family: helvetica; color: #000000;\">Configure storage:<\/span><\/strong><\/h5><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-690 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/configure-storage-19.png\" alt=\"aws storage\" width=\"598\" height=\"358\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/configure-storage-19.png 598w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/configure-storage-19-300x180.png 300w\" sizes=\"(max-width: 598px) 100vw, 598px\" \/><\/p><p><span style=\"font-family: helvetica;\">You can also leave this step to be with the default settings.<\/span><\/p><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Add Tags:<\/span><\/strong><\/span><\/h5><p><span style=\"font-family: helvetica;\">Click\u00a0click to add a name tag\u00a0and enter a name in the value field.<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-691 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/Add-tag-20.png\" alt=\"aws\" width=\"602\" height=\"190\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/Add-tag-20.png 602w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/Add-tag-20-300x95.png 300w\" sizes=\"(max-width: 602px) 100vw, 602px\" \/><\/p><h5><span style=\"font-family: helvetica; color: #000000;\"><strong>Configure Security Group:<\/strong><\/span><\/h5><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-692 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/configure-security-group-21.png\" alt=\"configure setting\" width=\"602\" height=\"470\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/configure-security-group-21.png 602w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/configure-security-group-21-300x234.png 300w\" sizes=\"(max-width: 602px) 100vw, 602px\" \/><\/p><p><span style=\"font-family: helvetica;\">This is an important setup where you can allow connections to your instance by opening certain ports.<\/span><\/p><p><span style=\"font-family: helvetica;\">By default SSH port is enabled.<\/span><\/p><p><span style=\"font-family: helvetica;\">If you need your website to be viewed in the internet then you need to add rules to allow connections to HTTP and HTTPS.<\/span><\/p><p><span style=\"font-family: helvetica;\">Click\u00a0<strong>Review and Launch<\/strong>.<\/span><\/p><h5><span style=\"font-family: helvetica; color: #000000;\"><strong>Create PEM key and launch Instance:<\/strong><\/span><\/h5><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-811 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/pem-key.jpg\" alt=\"aws\" width=\"1920\" height=\"894\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/pem-key.jpg 1920w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/pem-key-300x140.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/pem-key-1024x477.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/pem-key-768x358.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/pem-key-1536x715.jpg 1536w\" sizes=\"(max-width: 1920px) 100vw, 1920px\" \/><\/p><p><span style=\"font-family: helvetica;\">Now you will be prompted to assign a key pair to access your instance.<\/span><\/p><p><span style=\"font-family: helvetica;\">Select\u00a0<strong>create a new key pair.<\/strong><\/span><\/p><p><span style=\"font-family: helvetica;\">Enter the name to your key.<\/span><\/p><p><span style=\"font-family: helvetica;\">Click\u00a0<strong>Download Key Pair<\/strong>.<\/span><\/p><p><span style=\"font-family: helvetica;\"><strong>Important:<\/strong> Save the key pair, if you miss this key you won&#8217;t be able to access your instance using SSH.<\/span><\/p><p><span style=\"font-family: helvetica;\">Click\u00a0<strong>Launch instances<\/strong>.<\/span><\/p><blockquote><p><span style=\"font-size: 14pt; font-family: helvetica; color: #000000;\"><strong>Step5:<\/strong><\/span><\/p><\/blockquote><h5><strong><span style=\"font-family: helvetica; color: #000000;\">Accessing a Terminal on Windows<\/span><\/strong><\/h5><p><span style=\"font-family: helvetica;\">Windows don\u2019t come with a built\u2011in terminal, so you need to download one from the Internet. Along with AWS, we recommend PuTTY, an ssh client used throughout the world.<\/span><\/p><ol><li><span style=\"font-family: helvetica;\">Access the<span style=\"color: #000000;\">\u00a0<span style=\"color: #333333;\"><a style=\"color: #333333;\" href=\"https:\/\/www.putty.org\/\"><strong>PUTTY download page<\/strong><\/a>.<\/span><\/span><\/span><\/li><li><span style=\"font-family: helvetica;\">Download and install the file in a location of your choice, then open it.<\/span><\/li><\/ol><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Download the putty:<\/span><\/strong><\/span><\/h5><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-809 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-download-1024x468.jpg\" alt=\"putty\" width=\"640\" height=\"293\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-download-1024x468.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-download-300x137.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-download-768x351.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-download-1536x702.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-download.jpg 1896w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><h5><span style=\"font-family: helvetica; color: #000000;\"><strong>Connect to your Linux instance<\/strong><\/span><\/h5><p><span style=\"font-family: helvetica;\">Use the following procedure to connect to your Linux instance using PuTTY. You need the\u00a0.ppk\u00a0file that you created for your private key. For more information, see\u00a0<span style=\"color: #333333;\"><a style=\"color: #333333;\" href=\"https:\/\/docs.aws.amazon.com\/AWSEC2\/latest\/UserGuide\/putty.html#putty-private-key\">Convert your private key using PuTTYgen<\/a><\/span>\u00a0in the preceding section. If you receive an error while attempting to connect to your instance, see\u00a0<span style=\"color: #333333;\"><a style=\"color: #333333;\" href=\"https:\/\/docs.aws.amazon.com\/AWSEC2\/latest\/UserGuide\/TroubleshootingInstancesConnecting.html\">Troubleshoot connecting to your instance<\/a>.<\/span><\/span><\/p><h5><span style=\"font-family: helvetica; color: #000000;\"><strong>To connect to your instance using PuTTY:<\/strong><\/span><\/h5><ol><li><span style=\"font-family: helvetica;\">Start PuTTY (from the <b>Start menu<\/b>, choose\u00a0<strong>All Programs, PuTTY, PuTTY<\/strong>).<\/span><\/li><li><span style=\"font-family: helvetica;\">In the <b>Category pane<\/b>, choose\u00a0<strong>Session<\/strong>\u00a0and complete the following fields:<\/span><\/li><\/ol><p style=\"padding-left: 40px; margin: 0px;\"><span style=\"font-family: helvetica;\">a. In the\u00a0<strong>Host Name box<\/strong>, do one of the following:<\/span><\/p><ul><li><span style=\"font-family: helvetica;\">(Public DNS) To connect using your instance&#8217;s public DNS name, enter\u00a0<em>instance-user-name<\/em>@<em>instance-public-dns-name<\/em>.<\/span><\/li><li><span style=\"font-family: helvetica;\">(IPv6) Alternatively, if your instance has an IPv6 address, to connect using your instance&#8217;s IPv6 address, enter\u00a0<em>instance-user-name<\/em>@<em>instance-IPv6-address<\/em>.<\/span><\/li><\/ul><p><span style=\"font-family: helvetica;\">For information about how to get the user name for your instance, and the public DNS name or IPv6 address of your instance, see<span style=\"color: #000000;\">\u00a0<\/span><span style=\"color: #333333;\"><a style=\"color: #333333;\" href=\"https:\/\/docs.aws.amazon.com\/AWSEC2\/latest\/UserGuide\/connection-prereqs.html#connection-prereqs-get-info-about-instance\">Get information about your instance<\/a>.<\/span><\/span><\/p><p style=\"padding-left: 40px;\"><span style=\"font-family: helvetica;\">b. Ensure that the <b>Port value<\/b>\u00a0is 22.<\/span><\/p><p style=\"padding-left: 40px;\"><span style=\"font-family: helvetica;\">c. Under <strong>Connection type<\/strong>, select\u00a0<strong>SSH<\/strong>.<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-813 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-config.jpg\" alt=\"putty\" width=\"601\" height=\"541\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-config.jpg 601w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-config-300x270.jpg 300w\" sizes=\"(max-width: 601px) 100vw, 601px\" \/><\/p><p><span style=\"font-family: helvetica;\">d. Specify the private key for your instance. For the <strong>Private key<\/strong>, enter the path to your private key, or choose the &#8220;<strong>&#8230;<\/strong>&#8221; button to browse for the file. To open the advanced site settings, for newer versions of WinSCP, choose\u00a0<strong>Advanced<\/strong>. To find the\u00a0<strong>Private key file setting<\/strong>, under\u00a0<strong>SSH<\/strong>, choose\u00a0<strong>Authentication<\/strong>.<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-814 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-private-key.jpg\" alt=\"putty\" width=\"600\" height=\"541\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-private-key.jpg 600w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-private-key-300x271.jpg 300w\" sizes=\"(max-width: 600px) 100vw, 600px\" \/><\/p><p><span style=\"font-family: helvetica; font-size: 14pt; color: #000000;\"><strong>\u00a0<\/strong><\/span><\/p><blockquote><p><span style=\"font-family: helvetica; font-size: 14pt; color: #000000;\"><strong>Step6:<\/strong><\/span><\/p><\/blockquote><h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Installing NGINX Software:<\/span><\/strong><\/span><\/h5><p><span style=\"font-family: helvetica;\">Now that your AWS environment is set up, it\u2019s time to install either\u00a0<span style=\"color: #333333;\"><a style=\"color: #333333;\" href=\"https:\/\/www.nginx.com\/blog\/setting-up-nginx\/#install-open-source\">NGINX Open Source<\/a><\/span>\u00a0or\u00a0<span style=\"color: #333333;\"><a style=\"color: #333333;\" href=\"https:\/\/www.nginx.com\/blog\/setting-up-nginx\/#install-nginx-plus\">NGINX\u00a0Plus<\/a><\/span>, which you can try free for\u00a030 days. Both options work in the context of this tutorial, but if you want to further explore the advanced features in\u00a0<span style=\"color: #333333;\"><a style=\"color: #333333;\" href=\"https:\/\/www.nginx.com\/products\/nginx\/\">NGINX\u00a0Plus<\/a><\/span>, please request a free trial.<\/span><\/p><h5><span style=\"font-family: helvetica; color: #000000;\"><strong>Installing NGINX Open Source<\/strong><\/span><\/h5><p><span style=\"font-family: helvetica;\">Most Linux distributions and BSD variants make NGINX Open Source available in their standard package repositories, but it\u2019s usually not the latest version. We recommend downloading NGINX Open Source directly from\u00a0<strong>nginx.org<\/strong>. There are just a few extra steps for adding the NGINX repository to the Ubuntu package manager (apt).<\/span><\/p><p><span style=\"font-family: helvetica;\">To install NGINX Open Source, follow these steps:<\/span><\/p><p><span style=\"font-family: helvetica;\">1. Access your terminal.<\/span><\/p><p><span style=\"font-family: helvetica;\">2. Download the NGINX signing key<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\">$\u00a0<strong>sudo wget\u00a0http:\/\/nginx.org\/keys\/nginx_signing.key<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">3. Add the key<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo apt-key add nginx_signing.key<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">4. Change directory to\u00a0<strong>\/etc\/apt<\/strong><\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ cd\u00a0 \/etc\/apt<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">5. Update the NGINX software<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo apt-get update<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">6. Install NGINX<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo apt-get install nginx<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">7. Type Y when prompted<\/span><\/p><p><span style=\"font-family: helvetica;\">8. Start NGINX<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo systemctl start nginx.service<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">9. Check its status<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo systemctl status nginx.service<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">10. Continue to\u00a0Opening Your Web Page.<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-817 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-1024x321.jpg\" alt=\"ip-address\" width=\"640\" height=\"201\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-1024x321.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-300x94.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-768x240.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-1536x481.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address.jpg 1581w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><p><span style=\"font-family: helvetica;\">Navigate to the Instances tab on the EC2 Dashboard if you are not there already. (One way is to click \u2002Services\u2002 in the top Console navigation bar, \u2002EC2\u2002 in the \u2002Compute\u2002 section, and Instances in the left\u2011hand navigation column.)<\/span><\/p><p><span style=\"font-family: helvetica;\">Scroll right in the table until you can see the instance\u2019s public IP address in the Public IPv4 address. Select the address and copy it into the paste buffer.<\/span><\/p><p><span style=\"font-family: helvetica;\">Open a new browser tab and paste the address into the address bar. The default <strong>Welcome to Nginx!<\/strong> the page appears, indicating that NGINX is installed and running but not yet configured.<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-845 size-full\" style=\"border: 1px solid gray;\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/MicrosoftTeams-image-19.png\" alt=\"\" width=\"614\" height=\"239\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/MicrosoftTeams-image-19.png 614w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/MicrosoftTeams-image-19-300x117.png 300w\" sizes=\"(max-width: 614px) 100vw, 614px\" \/><\/p><p><span style=\"font-family: helvetica;\">11. Setting Up Sample Files<\/span><\/p><p><span style=\"font-family: helvetica; font-size: 12pt;\">With a working version of NGINX or NGINX\u00a0Plus installed, it\u2019s time to put it to good use! Begin by setting up some files and directories.<\/span><\/p><p><span style=\"font-family: helvetica;\">1. Change the directory to your home directory if you are not already there. In the following instructions, it is <strong>\/home\/ubuntu<\/strong>.<\/span><\/p><p><span style=\"font-family: helvetica;\">2. Create a directory called <strong>public_html <\/strong>and change it.<\/span><\/p><p><span style=\"font-family: helvetica;\">3. In the <strong>public_html <\/strong>directory, create a file called\u00a0<strong>HTML<\/strong>\u00a0and a directory called data.<\/span><\/p><p><span style=\"font-family: helvetica;\">4. Change directory to <strong>\/etc\/nginx\/conf.d<\/strong><\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>cd \/etc\/nginx\/conf.d<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">5. Rename <strong>default<\/strong> <b>conf<\/b> to\u00a0<strong>default.conf.bak<\/strong>\u00a0to prevent NGINX from using it as the default configuration file.<\/span><\/p><p><span style=\"font-family: helvetica;\">6. Create a file called <strong>server1.conf<\/strong> with this configuration in it:<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo nano server1.conf<\/strong><\/code><\/pre><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-832 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ngnix-conf-1024x326.jpg\" alt=\"ngnix\" width=\"640\" height=\"204\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ngnix-conf-1024x326.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ngnix-conf-300x96.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ngnix-conf-768x245.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ngnix-conf.jpg 1064w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-830 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ls-1024x192.jpg\" alt=\"\" width=\"640\" height=\"120\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ls-1024x192.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ls-300x56.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ls-768x144.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ls.jpg 1062w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><p><span style=\"font-family: helvetica;\">7. Reload NGINX<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo nginx -s reload<\/strong><\/code><\/pre><blockquote><p><span style=\"font-family: helvetica; font-size: 14pt; color: #000000;\"><strong>Step7:<\/strong><\/span><\/p><\/blockquote><p><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Install npm, nodejs and git on server<\/span><\/strong><\/span><\/p><p><span style=\"font-family: helvetica;\">Let&#8217;s install npm<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo apt-get install -y npm<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">Let install node.js<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo apt-get install -y nodejs\n<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">Let install git<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo apt-get install -y git\n<\/strong><\/code><\/pre><blockquote><p><span style=\"font-size: 14pt; font-family: helvetica; color: #000000;\"><strong>Step8:<\/strong><\/span><\/p><\/blockquote><p><span style=\"font-family: helvetica;\">Install MySQL database on the server<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo apt install mysql-server<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">As soon as your installation is complete, the MySQL server should run automatically. You can check it with the following command.<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo systemctl status mysql<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">It must return some information about the MySQL server, such as Active: active (running). Let\u2019s log in as root.<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo mysql<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">You must set a password for your root now. Replace your_password_here with a strong password. <\/span><span style=\"font-family: helvetica;\">Now, let\u2019s exit and log in with the root credentials.<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo mysql -u root -p<\/strong><\/code><\/pre><blockquote><p><span style=\"font-size: 14pt; font-family: helvetica; color: #000000;\"><strong>Step9:<\/strong><\/span><\/p><\/blockquote><p><span style=\"font-family: helvetica;\">Installing MySQL Workbench for Easier Management.<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-737 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-mysql-workbenh-45.png\" alt=\"mysql\" width=\"590\" height=\"277\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-mysql-workbenh-45.png 590w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-mysql-workbenh-45-300x141.png 300w\" sizes=\"(max-width: 590px) 100vw, 590px\" \/><\/p><p><span style=\"font-family: helvetica;\">Click on + next to MySQL Connections.<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-738 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/mysql-connections-46.png\" alt=\"mysql\" width=\"602\" height=\"383\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/mysql-connections-46.png 602w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/mysql-connections-46-300x191.png 300w\" sizes=\"(max-width: 602px) 100vw, 602px\" \/><\/p><p><span style=\"font-family: helvetica;\">Give your connection an arbitrary name (e.g.,\u00a0AWS SQL test\u00a0). From the Connection method dropdown menu, choose \u201cStandard TCP\/IP over SSH.\u201d The SSH Hostname is your EC2 Instance Public IPv4 DNS address. You can find this address on your EC2 dashboard by clicking on your instance and choosing details from the tab menu.<\/span><\/p><p><span style=\"font-family: helvetica;\">Besides, change the SSH Username to\u00a0ubuntu\u00a0and locate your SSH Key File (the .pem file you got from AWS to connect via SSH). Finally, make sure that your user name is\u00a0root. Click OK, and your connection should appear on the first page.<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-740 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/mysql-connections-47.png\" alt=\"mysql\" width=\"602\" height=\"404\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/mysql-connections-47.png 602w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/mysql-connections-47-300x201.png 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/mysql-connections-47-150x100.png 150w\" sizes=\"(max-width: 602px) 100vw, 602px\" \/><\/p><p>After that, a copy should be taken from the existing database.<\/p><blockquote><p><span style=\"font-family: helvetica; font-size: 14pt;\"><strong>Step10:<\/strong><\/span><\/p><\/blockquote><p><span style=\"font-family: helvetica;\">Ok then it should be fetched from GitHub on the server<\/span><\/p><p><span style=\"font-family: helvetica;\">pull the code in the GitHub repository:<\/span><\/p><p><span style=\"font-family: helvetica;\">1. First make a directory:<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo mkdir newdir<\/strong><\/code><\/pre><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-837 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/new-dirctory-conf.jpg\" alt=\"\" width=\"1063\" height=\"338\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/new-dirctory-conf.jpg 1063w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/new-dirctory-conf-300x95.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/new-dirctory-conf-1024x326.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/new-dirctory-conf-768x244.jpg 768w\" sizes=\"(max-width: 1063px) 100vw, 1063px\" \/><\/p><p><span style=\"font-family: helvetica;\">Open the directory if newly created, and edit server1.conf file or open public_html directory to create already,<\/span><\/p><p><span style=\"font-family: helvetica;\">2. Open the directory:<\/span><\/p><p><span style=\"font-family: helvetica;\">If the directory is newly created, then open it. Otherwise public_html is already created<\/span><\/p><p><span style=\"font-family: helvetica;\">Open the directory I open public_html<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ cd public_html<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">3. Git initialize:<\/span><\/p><p><span style=\"font-family: helvetica;\">After that, you need to initialize git in that directory<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo git init<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">4. Git remote add<\/span><\/p><p><span style=\"font-family: helvetica;\">To add a new remote, use the git remote add command on the terminal, in the directory your repository is stored at. The git remote add command takes two arguments: A remote name, for example, origin.<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo git remote add origin\u00a0https:\/\/github.com\/niraltek\/sample-project.git<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">5. Git configure<\/span><\/p><p><span style=\"font-family: helvetica;\">The git checkout command lets you navigate between the branches created by the git branch. Checking out a branch updates the files in the working directory to match the version stored in that branch, and it tells Git to record all new commits on that branch.<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo git config core.sparseCheckout true<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">6. Sparse checkout<\/span><\/p><p><span style=\"font-family: helvetica;\">This command is used to create sparse checkouts, which change the working tree from having all tracked files present to only having a subset of those files. It can also switch which subset of files are present, or undo and go back to having all tracked files present in the working copy.<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo touch .git\/info\/sparse-checkout<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">7. Pull in the build directory in GitHub.<\/span><\/p><p><span style=\"font-family: helvetica;\">This command is used to pull a folder or directory from GitHub<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo bash -c 'echo \"dist\/\" &gt; .git\/info\/sparse-checkout'<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">8. Generate personal access token:<\/span><\/p><p><span style=\"font-family: helvetica;\">Before pulling from GitHub generate a personal access token first:<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-839 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-1024x618.jpg\" alt=\"github\" width=\"640\" height=\"386\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-1024x618.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-300x181.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-768x464.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github.jpg 1461w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><p><span style=\"font-family: helvetica;\">Click the setting,<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-841 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github1-1024x573.jpg\" alt=\"\" width=\"640\" height=\"358\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github1-1024x573.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github1-300x168.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github1-768x430.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github1-1536x859.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github1.jpg 1587w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><p><span style=\"font-family: helvetica;\">Click on the developer setting and click on generate a new token,<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-842 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/generate-token-1024x291.jpg\" alt=\"\" width=\"640\" height=\"182\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/generate-token-1024x291.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/generate-token-300x85.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/generate-token-768x219.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/generate-token-1536x437.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/generate-token.jpg 1887w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><p><span style=\"font-family: helvetica;\">After that, you need to pull your code from GitHub.<\/span><\/p><p><span style=\"font-family: helvetica;\">9. Pull your code:<\/span><\/p><p><span style=\"font-family: helvetica;\">git pull origin master will fetch and update only a specific branch called master and origin in the remote repository. Often, the default branch in Git is a master branch, and it keeps updating frequently. A user can use any branch name to pull that branch from the remote<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\">$ sudo git pull origin main<\/code><\/pre><p><span style=\"font-family: helvetica;\">username You must provide your GitHub username, <\/span><span style=\"font-family: helvetica;\">the password is your GitHub personal access token.<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-843 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-1024x172.jpg\" alt=\"github\" width=\"640\" height=\"108\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-1024x172.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-300x50.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-768x129.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login.jpg 1064w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><blockquote><p><span style=\"font-family: helvetica; font-size: 14pt;\"><strong>Step11:<\/strong><\/span><\/p><\/blockquote><p><span style=\"font-family: helvetica; color: #000000;\">Create a directory for the server connection<\/span><\/p><p><span style=\"font-family: helvetica;\">1. First create a directory:<\/span><\/p><p><span style=\"font-family: helvetica;\">Create a directory named demo-database -server<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo mkdir demo-database-server<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">2. Open the directory:<\/span><\/p><p><span style=\"font-family: helvetica;\">After that open that directory<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ cd demo-database-server\/<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">3. Git initialize:<\/span><\/p><p><span style=\"font-family: helvetica;\">After that, you need to initialize git in that directory<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo git init <\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">4. Git remote add:<\/span><\/p><p><span style=\"font-family: helvetica;\">To add a new remote, use the git remote add command on the terminal, in the directory your repository is stored at. The git remote add command takes two arguments: A remote name, for example, origin.<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo git remote add origin\u00a0https:\/\/github.com\/niraltek\/sample-project.git<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">5. Git configure:<\/span><\/p><p><span style=\"font-family: helvetica;\">The git checkout command lets you navigate between the branches created by the git branch. Checking out a branch updates the files in the working directory to match the version stored in that branch, and it tells Git to record all new commits on that branch.<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo git config core.sparseCheckout true<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">6. Sparse checkout:<\/span><\/p><p><span style=\"font-family: helvetica;\">This command is used to create sparse checkouts, which change the working tree from having all tracked files present to only have a subset of those files. It can also switch which subset of files are present, or undo and go back to having all tracked files present in the working copy.<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo touch .git\/info\/sparse-checkout<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">7. Pull in the build directory in GitHub:<\/span><\/p><p><span style=\"font-family: helvetica;\">This command is used to pull a folder or directory from GitHub<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo bash -c 'echo \"mysql-database\/\" &gt; .git\/info\/sparse-checkout'<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">8. Pull your code:<\/span><\/p><p><span style=\"font-family: helvetica;\">Git pull origin master will fetch and update only a specific branch called master and origin in the remote repository. Often, the default branch in Git is a master branch, and it keeps updating frequently. A user can use any branch name to pull that branch from the remote,<\/span><\/p><p><span style=\"font-family: helvetica;\">username You must provide your GitHub username, <\/span><span style=\"font-family: helvetica;\">the password is your GitHub personal access token. <\/span><span style=\"font-family: helvetica;\">We have already generated a personal access token and can use it.<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-843 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-1024x172.jpg\" alt=\"github\" width=\"640\" height=\"108\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-1024x172.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-300x50.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-768x129.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login.jpg 1064w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><p><span style=\"font-family: helvetica;\">After that,<\/span><\/p><p><span style=\"font-family: helvetica;\">9. Install pm2:<\/span><\/p><p><span style=\"font-family: helvetica;\">PM2 is a production process manager for Node.js applications with a built-in load balancer. It allows you to keep applications alive forever, reload them without downtime, and facilitate common system admin tasks.<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo npm install pm2 -g<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">10. Start a Server:<\/span><\/p><pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo pm2 start db-connection.js<\/strong><\/code><\/pre><p><span style=\"font-family: helvetica;\">11. Continue to Opening Your Web Page:<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-817 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-1024x321.jpg\" alt=\"ip-address\" width=\"640\" height=\"201\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-1024x321.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-300x94.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-768x240.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-1536x481.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address.jpg 1581w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p><p><span style=\"font-family: helvetica;\">Navigate to the Instances tab on the EC2 Dashboard if you are not there already. (One way is to click \u2002Services\u2002 in the top Console navigation bar, \u2002EC2\u2002 in the \u2002Compute\u2002 section, and Instances in the left\u2011hand navigation column).<\/span><\/p><p><span style=\"font-family: helvetica;\">Scroll right in the table until you can see the instance\u2019s public IP address in the Public IPv4 address. Select the address and copy it into the paste buffer.<\/span><\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-706 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-1024x477.jpg\" alt=\"angular\" width=\"640\" height=\"298\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-1024x477.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-300x140.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-768x357.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-1536x715.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app.jpg 1919w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-20b62ee elementor-widget elementor-widget-text-editor\" data-id=\"20b62ee\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<style><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">\ufeff<\/span><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">\ufeff<\/span><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">\ufeff<\/span><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\"><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">\ufeff<\/span>\ufeff<\/span><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">\ufeff<\/span><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">\ufeff<\/span><span data-mce-type=\"bookmark\" style=\"display: inline-block; width: 0px; overflow: hidden; line-height: 0;\" class=\"mce_SELRES_start\">\ufeff<\/span>img {margin: 0 !important;} p {margin: 0 0 1em}<\/style>\n<h1 style=\"text-align: center;\"><\/h1>\n<h6><span style=\"font-family: helvetica;\">A<b>fter installing angular in your local system follow the below procedure.<\/b><\/span><\/h6>\n<blockquote><span style=\"font-family: helvetica; font-size: 14pt; color: #000000;\"><strong>Step1:<\/strong><\/span><\/blockquote>\n<span style=\"font-family: helvetica;\">Create a new angular application:<\/span>\n<div style=\"background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 4px; padding: 15px; width: 85%; margin-bottom: 15px;\"><span style=\"font-size: 12pt;\"><code style=\"color: #333333; line-height: 1.4;\">ng new angular-app<\/code><\/span><\/div>\n<div><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-327 size-full\" src=\"http:\/\/localhost:8080\/wp-content\/uploads\/2022\/11\/create-angular-app-1.png\" sizes=\"(max-width: 603px) 100vw, 603px\" srcset=\"http:\/\/localhost:8080\/wp-content\/uploads\/2022\/11\/create-angular-app-1.png 603w, http:\/\/localhost:8080\/wp-content\/uploads\/2022\/11\/create-angular-app-1-300x95.png 300w\" alt=\"\" width=\"603\" height=\"191\" \/><\/div>\n<div><span style=\"font-family: helvetica; margin: 0;\">\u00a0<\/span><\/div>\n<div><\/div>\n<h6><span style=\"font-family: helvetica;\">Ang<b>ular application view<\/b><\/span><\/h6>\n<div><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-706 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-1024x477.jpg\" alt=\"angular\" width=\"640\" height=\"298\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-1024x477.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-300x140.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-768x357.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-1536x715.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app.jpg 1919w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/div>\n<strong style=\"color: #000000; font-family: var( --e-global-typography-text-font-family ), Sans-serif;\"><span style=\"font-family: helvetica; font-size: 14pt;\">\u00a0<\/span><\/strong>\n<blockquote><strong style=\"color: #000000; font-family: var( --e-global-typography-text-font-family ), Sans-serif;\"><span style=\"font-family: helvetica; font-size: 14pt;\">Step:2<\/span><\/strong><\/blockquote>\n<strong style=\"color: #000000; font-family: var( --e-global-typography-text-font-family ), Sans-serif;\"><span style=\"font-family: helvetica; font-size: 14pt;\">\u00a0<\/span><\/strong>\n<h5><strong><span style=\"font-family: helvetica; color: #000000;\">MySQL Database:<\/span><\/strong><\/h5>\n<span style=\"font-family: helvetica;\">To be able to experiment with the code examples, you should have MySQL installed on your computer.<\/span>\n\n<span style=\"font-family: helvetica;\">You can download a free MySQL database at<span style=\"color: #333333;\">\u00a0<a style=\"color: #333333;\" href=\"https:\/\/www.mysql.com\/downloads\/\">https:\/\/www.mysql.com\/downloads\/<\/a>.<\/span><\/span>\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica; font-size: 12pt;\">Install MySQL Driver:<\/span><\/strong><\/span><\/h5>\n<p style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"font-size: 12pt; font-family: helvetica; color: #333333;\">Once you have MySQL up and running on your computer, you can access it by using Node.js.<\/span><\/p>\n<p style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"font-size: 12pt; font-family: helvetica; color: #333333;\">To access a MySQL database with Node.js, you need a MySQL driver. This tutorial will use the &#8220;MySQL&#8221; module, downloaded from NPM.<\/span><\/p>\n<span style=\"font-family: helvetica; font-size: 12pt;\">To download and install the &#8220;MySQL&#8221; module, open the Command Terminal and execute the following:<\/span>\n\n<span style=\"font-family: helvetica; font-size: 12pt;\">First, install npm and then install MySQL<\/span>\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Create Node.js App:<\/span><\/strong><\/span><\/h5>\n<span style=\"font-family: helvetica; font-size: 12pt;\">First, create a folder and name it MySQL -database.<\/span>\n\n<span style=\"font-family: helvetica;\">Next, we initialize the Node.js App with a\u00a0<em>package.json<\/em>\u00a0file:<\/span>\n<p style=\"background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 4px; padding: 15px; width: 85%; margin-bottom: 15px;\"><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">npm init\n<\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">package name: (mysql-database)\n<\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">version: (1.0.0)\n<\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">description: none\n<\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">entry point: (index.js) db-connections.js\n<\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">test command:\n<\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">git repository:\n<\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">keywords: nodejs, express, sequelize, mysql, rest, api\n<\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">author: Niraltek Solutions\n<\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">license: (ISC)\n<\/span><\/code><code style=\"color: #333; line-height: 1.1; font-size: 13px;\"><span style=\"font-size: 12pt;\">About to write to D:\\mysql-database\\package.json:<\/span><\/code><\/p>\n\n<div><\/div>\n<div><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-771\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/npm-init.jpg\" alt=\"npm\" width=\"800\" height=\"376\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/npm-init.jpg 1104w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/npm-init-300x141.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/npm-init-1024x481.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/npm-init-768x361.jpg 768w\" sizes=\"(max-width: 800px) 100vw, 800px\" \/><\/div>\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">\u00a0<\/span><\/strong><\/span><\/h5>\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">NPM Install MySQL:<\/span><\/strong><\/span><\/h5>\n<span style=\"font-family: helvetica;\">We need to install the necessary modules: <code>express<\/code>,\u00a0<code>sequelize<\/code>,\u00a0<code>mysql2<\/code>. <\/span><span style=\"font-family: helvetica;\">Run the command:<\/span>\n<p style=\"background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 4px; padding: 15px; width: 85%; margin-bottom: 15px;\"><span style=\"font-size: 12pt;\"><code style=\"color: #333333; line-height: 1.4;\">npm install express sequelize mysql2 cors --save<\/code><\/span><\/p>\n\n<div><\/div>\n<div><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-789\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-express.jpg\" alt=\"express\" width=\"800\" height=\"287\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-express.jpg 1103w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-express-300x108.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-express-1024x368.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-express-768x276.jpg 768w\" sizes=\"(max-width: 800px) 100vw, 800px\" \/><\/div>\n<p style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"font-size: 12pt; font-family: helvetica; color: black;\">Now you have downloaded and installed a MySQL database driver.<\/span><\/p>\n<p style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"font-size: 12pt; font-family: helvetica; color: black;\">Node.js can use this module to manipulate the MySQL database:<\/span><\/p>\n<p style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"font-size: 12pt; font-family: helvetica; color: black;\"><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-663 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/var-mysql-5.png\" alt=\"install mysql\" width=\"321\" height=\"74\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/var-mysql-5.png 321w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/var-mysql-5-300x69.png 300w\" sizes=\"(max-width: 321px) 100vw, 321px\" \/><\/span><\/p>\n\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Create Connection:<\/span><\/strong><\/span><\/h5>\n<span style=\"font-family: helvetica;\">Start by creating a connection to the database.<\/span>\n\n<span style=\"font-family: helvetica;\">Use the username and password from your MySQL database.<\/span>\n\n<span style=\"font-family: helvetica;\">db-connection.js<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-664 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connections.js-6.png\" alt=\"db connection\" width=\"378\" height=\"260\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connections.js-6.png 378w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connections.js-6-300x206.png 300w\" sizes=\"(max-width: 378px) 100vw, 378px\" \/>\n\n<span style=\"font-family: helvetica;\">Save the code above in a file called &#8220;db_connection.js&#8221; and run the file:<\/span>\n<h5 style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Run &#8220;db_connection.js&#8221;:<\/span><\/strong><\/span><\/h5>\n<p style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"font-size: 12pt; font-family: Helvetica; color: #333333; background: white;\">Which will give you this result:<\/span><\/p>\n\n<div style=\"background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 4px; padding: 15px; width: 85%; margin-bottom: 15px;\"><span style=\"font-size: 12pt;\"><code style=\"color: #333333; line-height: 1.4;\">node db-connection.js<\/code><\/span><\/div>\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-792 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connection-1024x325.jpg\" alt=\"mysql\" width=\"640\" height=\"203\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connection-1024x325.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connection-300x95.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connection-768x244.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/db-connection.jpg 1103w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n<p style=\"background: white; margin: .2in 0in .2in 0in;\"><span style=\"font-size: 12pt; font-family: Helvetica; color: #333333; background: white;\">Now you can start querying the database using SQL statements.<\/span><\/p>\n\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica; font-size: 12pt;\">Database Query:<\/span><\/strong><\/span><\/h5>\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-671 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/query-database-9.png\" alt=\"database query\" width=\"375\" height=\"165\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/query-database-9.png 375w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/query-database-9-300x132.png 300w\" sizes=\"(max-width: 375px) 100vw, 375px\" \/>\n<p style=\"background: white; margin: 7.5pt 0in 7.5pt 0in;\"><span style=\"font-size: 12pt; font-family: Helvetica; color: black; background: white; font-weight: normal;\">The query method takes an SQL statement as a parameter and returns the result.<\/span><\/p>\n\n<blockquote><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica; font-size: 14pt;\">Step3:<\/span><\/strong><\/span><\/blockquote>\n<span style=\"font-family: helvetica; font-size: 12pt;\">After that just upload the source file to Github[Hope you have created an account on Github.com and a new repository. Install Git in your local system as well].<\/span>\n\n<span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica; font-size: 12pt;\">Git ADD file:<\/span><\/strong><\/span>\n\n<span style=\"font-family: helvetica; font-size: 12pt;\">All files should be added to GitHub<\/span>\n<div style=\"background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 4px; padding: 15px; width: 85%; margin-bottom: 15px;\"><span style=\"font-size: 12pt;\"><code style=\"color: #333333; line-height: 1.4;\">git add --a<\/code><\/span><\/div>\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-803 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-add-1024x328.jpg\" alt=\"github\" width=\"640\" height=\"205\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-add-1024x328.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-add-300x96.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-add-768x246.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-add.jpg 1104w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Git Commit:<\/span><\/strong><\/span><\/h5>\n<span style=\"font-family: helvetica;\">The git commit command captures a snapshot of the project&#8217;s currently committed changes.<\/span>\n<div style=\"background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 4px; padding: 15px; width: 85%; margin-bottom: 15px;\"><span style=\"font-size: 12pt;\"><code style=\"color: #333333; line-height: 1.4;\">git commit -m \"first-commit\"<\/code><\/span><\/div>\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-804 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-commit-1024x346.jpg\" alt=\"github\" width=\"640\" height=\"216\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-commit-1024x346.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-commit-300x101.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-commit-768x259.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-commit.jpg 1104w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n<h5 style=\"background: white; margin: 7.5pt 0in 7.5pt 0in;\"><span style=\"color: #000000;\"><strong><span style=\"font-size: 12pt; font-family: Helvetica; background: white;\">Git Push:<\/span><\/strong><\/span><\/h5>\n<span style=\"font-family: helvetica;\">The git push command is used to upload local repository content to a remote repository. Pushing is simply transferring commits from your local repository to a remote repo. This is parallel to receiving the kit, but receiving imports commits to local branches, pushing exports to remote branches.<\/span>\n<div style=\"background-color: #f5f5f5; border: 1px solid #ccc; border-radius: 4px; padding: 15px; width: 85%; margin-bottom: 15px;\"><code style=\"color: #333; line-height: 1.4; font-size: 13px;\"><span style=\"font-size: 12pt;\">git push<\/span><\/code><\/div>\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-806 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-push-1024x346.jpg\" alt=\"github\" width=\"640\" height=\"216\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-push-1024x346.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-push-300x101.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-push-768x260.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/git-push.jpg 1103w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n<blockquote style=\"background: white; margin: 7.5pt 0in 7.5pt 0in;\"><span style=\"color: #000000;\"><strong><span style=\"font-size: 14pt;\"><span style=\"font-family: Helvetica; background: white;\">Step4:<\/span><\/span><\/strong><\/span><\/blockquote>\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica; font-size: 12pt;\">Create AWS EC2 Instance:<\/span><\/strong><\/span><\/h5>\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-677 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/aws.png\" alt=\"amazon web service\" width=\"225\" height=\"135\" \/>\n\n<span style=\"font-family: helvetica;\">AWS has made launching EC2 instances an easy task, but there are still many steps to the final result. Learn how to successfully create an EC2 instance from AWS Console.<\/span>\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Select a region:<\/span><\/strong><\/span><\/h5>\n<span style=\"font-family: helvetica;\">One of the most important steps is to select the desired AWS region. This can be done from the top navigation bar of the AWS Console.<\/span>\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Navigate to the EC2 Console:<\/span><\/strong><\/span><\/h5>\n<span style=\"font-family: helvetica; font-size: 12pt;\">Once you select the desired AWS region, go to the EC2 Console. From the same landing page, search for EC2 (Figure 1). Your landing page in the management interface will likely display EC2 among the most commonly used services in the account.<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-682 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/navigate-to-the-ec2-14.png\" alt=\"ec2\" width=\"602\" height=\"237\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/navigate-to-the-ec2-14.png 602w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/navigate-to-the-ec2-14-300x118.png 300w\" sizes=\"(max-width: 602px) 100vw, 602px\" \/>\n<p style=\"text-align: center;\"><em><span style=\"font-family: helvetica; color: #808080;\">(figure 1)<\/span><\/em><\/p>\n<span style=\"font-family: helvetica;\">Once you arrive at the EC2 Console, from the left navigation menu, choose the\u00a0Instances\u00a0option.<\/span>\n\n<span style=\"font-family: helvetica;\">Under\u00a0Instances\u00a0is a list of the EC2 instances deployed in the account. There is also a\u00a0Launch instances\u00a0button on the top right section of this page; clicking on that button brings you to the EC2 instance launch flow (Figure 2).<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-684 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ec2-console-15.png\" alt=\"ec2\" width=\"502\" height=\"37\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ec2-console-15.png 502w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ec2-console-15-300x22.png 300w\" sizes=\"(max-width: 502px) 100vw, 502px\" \/>\n<p style=\"text-align: center;\"><em><span style=\"font-family: helvetica; color: #808080;\">(figure 2)<\/span><\/em><\/p>\n\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Create the EC2 instance:<\/span><\/strong><\/span><\/h5>\n<span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Launch Instance:<\/span><\/strong><\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-708 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/launch-instance-1024x418.jpg\" alt=\"aws\" width=\"640\" height=\"261\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/launch-instance-1024x418.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/launch-instance-300x122.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/launch-instance-768x314.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/launch-instance-1536x627.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/launch-instance.jpg 1729w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-687 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/lanuch-instance-17.png\" alt=\"AWS\" width=\"578\" height=\"262\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/lanuch-instance-17.png 578w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/lanuch-instance-17-300x136.png 300w\" sizes=\"(max-width: 578px) 100vw, 578px\" \/>\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Choose Instance type:<\/span><\/strong><\/span><\/h5>\n<span style=\"font-family: helvetica;\">Here you can choose your desired machine type. If you wish to get benefited using the free tier you can choose the t2.micro\u00a0type instance.<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-689 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/choose-instance-type-18.png\" sizes=\"(max-width: 609px) 100vw, 609px\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/choose-instance-type-18-300x74.png 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/choose-instance-type-18.png 602w\" alt=\"AWS\" width=\"602\" height=\"149\" \/>\n<h5><strong><span style=\"font-family: helvetica; color: #000000;\">Configure storage:<\/span><\/strong><\/h5>\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-690 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/configure-storage-19.png\" alt=\"aws storage\" width=\"598\" height=\"358\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/configure-storage-19.png 598w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/configure-storage-19-300x180.png 300w\" sizes=\"(max-width: 598px) 100vw, 598px\" \/>\n\n<span style=\"font-family: helvetica;\">You can also leave this step to be with the default settings.<\/span>\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Add Tags:<\/span><\/strong><\/span><\/h5>\n<span style=\"font-family: helvetica;\">Click\u00a0click to add a name tag\u00a0and enter a name in the value field.<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-691 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/Add-tag-20.png\" alt=\"aws\" width=\"602\" height=\"190\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/Add-tag-20.png 602w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/Add-tag-20-300x95.png 300w\" sizes=\"(max-width: 602px) 100vw, 602px\" \/>\n<h5><span style=\"font-family: helvetica; color: #000000;\"><strong>Configure Security Group:<\/strong><\/span><\/h5>\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-692 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/configure-security-group-21.png\" alt=\"configure setting\" width=\"602\" height=\"470\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/configure-security-group-21.png 602w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/configure-security-group-21-300x234.png 300w\" sizes=\"(max-width: 602px) 100vw, 602px\" \/>\n\n<span style=\"font-family: helvetica;\">This is an important setup where you can allow connections to your instance by opening certain ports.<\/span>\n\n<span style=\"font-family: helvetica;\">By default SSH port is enabled.<\/span>\n\n<span style=\"font-family: helvetica;\">If you need your website to be viewed in the internet then you need to add rules to allow connections to HTTP and HTTPS.<\/span>\n\n<span style=\"font-family: helvetica;\">Click\u00a0<strong>Review and Launch<\/strong>.<\/span>\n<h5><span style=\"font-family: helvetica; color: #000000;\"><strong>Create PEM key and launch Instance:<\/strong><\/span><\/h5>\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-811 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/pem-key.jpg\" alt=\"aws\" width=\"1920\" height=\"894\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/pem-key.jpg 1920w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/pem-key-300x140.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/pem-key-1024x477.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/pem-key-768x358.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/pem-key-1536x715.jpg 1536w\" sizes=\"(max-width: 1920px) 100vw, 1920px\" \/>\n\n<span style=\"font-family: helvetica;\">Now you will be prompted to assign a key pair to access your instance.<\/span>\n\n<span style=\"font-family: helvetica;\">Select\u00a0<strong>create a new key pair.<\/strong><\/span>\n\n<span style=\"font-family: helvetica;\">Enter the name to your key.<\/span>\n\n<span style=\"font-family: helvetica;\">Click\u00a0<strong>Download Key Pair<\/strong>.<\/span>\n\n<span style=\"font-family: helvetica;\"><strong>Important:<\/strong> Save the key pair, if you miss this key you won&#8217;t be able to access your instance using SSH.<\/span>\n\n<span style=\"font-family: helvetica;\">Click\u00a0<strong>Launch instances<\/strong>.<\/span>\n<blockquote><span style=\"font-size: 14pt; font-family: helvetica; color: #000000;\"><strong>Step5:<\/strong><\/span><\/blockquote>\n<h5><strong><span style=\"font-family: helvetica; color: #000000;\">Accessing a Terminal on Windows<\/span><\/strong><\/h5>\n<span style=\"font-family: helvetica;\">Windows don\u2019t come with a built\u2011in terminal, so you need to download one from the Internet. Along with AWS, we recommend PuTTY, an ssh client used throughout the world.<\/span>\n<ol>\n \t<li><span style=\"font-family: helvetica;\">Access the<span style=\"color: #000000;\">\u00a0<span style=\"color: #333333;\"><a style=\"color: #333333;\" href=\"https:\/\/www.putty.org\/\"><strong>PUTTY download page<\/strong><\/a>.<\/span><\/span><\/span><\/li>\n \t<li><span style=\"font-family: helvetica;\">Download and install the file in a location of your choice, then open it.<\/span><\/li>\n<\/ol>\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Download the putty:<\/span><\/strong><\/span><\/h5>\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-809 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-download-1024x468.jpg\" alt=\"putty\" width=\"640\" height=\"293\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-download-1024x468.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-download-300x137.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-download-768x351.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-download-1536x702.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-download.jpg 1896w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n<h5><span style=\"font-family: helvetica; color: #000000;\"><strong>Connect to your Linux instance<\/strong><\/span><\/h5>\n<span style=\"font-family: helvetica;\">Use the following procedure to connect to your Linux instance using PuTTY. You need the\u00a0.ppk\u00a0file that you created for your private key. For more information, see\u00a0<span style=\"color: #333333;\"><a style=\"color: #333333;\" href=\"https:\/\/docs.aws.amazon.com\/AWSEC2\/latest\/UserGuide\/putty.html#putty-private-key\">Convert your private key using PuTTYgen<\/a><\/span>\u00a0in the preceding section. If you receive an error while attempting to connect to your instance, see\u00a0<span style=\"color: #333333;\"><a style=\"color: #333333;\" href=\"https:\/\/docs.aws.amazon.com\/AWSEC2\/latest\/UserGuide\/TroubleshootingInstancesConnecting.html\">Troubleshoot connecting to your instance<\/a>.<\/span><\/span>\n<h5><span style=\"font-family: helvetica; color: #000000;\"><strong>To connect to your instance using PuTTY:<\/strong><\/span><\/h5>\n<ol>\n \t<li><span style=\"font-family: helvetica;\">Start PuTTY (from the <b>Start menu<\/b>, choose\u00a0<strong>All Programs, PuTTY, PuTTY<\/strong>).<\/span><\/li>\n \t<li><span style=\"font-family: helvetica;\">In the <b>Category pane<\/b>, choose\u00a0<strong>Session<\/strong>\u00a0and complete the following fields:<\/span><\/li>\n<\/ol>\n<p style=\"padding-left: 40px; margin: 0px;\"><span style=\"font-family: helvetica;\">a. In the\u00a0<strong>Host Name box<\/strong>, do one of the following:<\/span><\/p>\n\n<ul>\n \t<li><span style=\"font-family: helvetica;\">(Public DNS) To connect using your instance&#8217;s public DNS name, enter\u00a0<em>instance-user-name<\/em>@<em>instance-public-dns-name<\/em>.<\/span><\/li>\n \t<li><span style=\"font-family: helvetica;\">(IPv6) Alternatively, if your instance has an IPv6 address, to connect using your instance&#8217;s IPv6 address, enter\u00a0<em>instance-user-name<\/em>@<em>instance-IPv6-address<\/em>.<\/span><\/li>\n<\/ul>\n<span style=\"font-family: helvetica;\">For information about how to get the user name for your instance, and the public DNS name or IPv6 address of your instance, see<span style=\"color: #000000;\">\u00a0<\/span><span style=\"color: #333333;\"><a style=\"color: #333333;\" href=\"https:\/\/docs.aws.amazon.com\/AWSEC2\/latest\/UserGuide\/connection-prereqs.html#connection-prereqs-get-info-about-instance\">Get information about your instance<\/a>.<\/span><\/span>\n<p style=\"padding-left: 40px;\"><span style=\"font-family: helvetica;\">b. Ensure that the <b>Port value<\/b>\u00a0is 22.<\/span><\/p>\n<p style=\"padding-left: 40px;\"><span style=\"font-family: helvetica;\">c. Under <strong>Connection type<\/strong>, select\u00a0<strong>SSH<\/strong>.<\/span><\/p>\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-813 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-config.jpg\" alt=\"putty\" width=\"601\" height=\"541\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-config.jpg 601w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-config-300x270.jpg 300w\" sizes=\"(max-width: 601px) 100vw, 601px\" \/>\n\n<span style=\"font-family: helvetica;\">d. Specify the private key for your instance. For the <strong>Private key<\/strong>, enter the path to your private key, or choose the &#8220;<strong>&#8230;<\/strong>&#8221; button to browse for the file. To open the advanced site settings, for newer versions of WinSCP, choose\u00a0<strong>Advanced<\/strong>. To find the\u00a0<strong>Private key file setting<\/strong>, under\u00a0<strong>SSH<\/strong>, choose\u00a0<strong>Authentication<\/strong>.<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-814 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-private-key.jpg\" alt=\"putty\" width=\"600\" height=\"541\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-private-key.jpg 600w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/putty-private-key-300x271.jpg 300w\" sizes=\"(max-width: 600px) 100vw, 600px\" \/>\n\n<span style=\"font-family: helvetica; font-size: 14pt; color: #000000;\"><strong>\u00a0<\/strong><\/span>\n<blockquote><span style=\"font-family: helvetica; font-size: 14pt; color: #000000;\"><strong>Step6:<\/strong><\/span><\/blockquote>\n<h5><span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Installing NGINX Software:<\/span><\/strong><\/span><\/h5>\n<span style=\"font-family: helvetica;\">Now that your AWS environment is set up, it\u2019s time to install either\u00a0<span style=\"color: #333333;\"><a style=\"color: #333333;\" href=\"https:\/\/www.nginx.com\/blog\/setting-up-nginx\/#install-open-source\">NGINX Open Source<\/a><\/span>\u00a0or\u00a0<span style=\"color: #333333;\"><a style=\"color: #333333;\" href=\"https:\/\/www.nginx.com\/blog\/setting-up-nginx\/#install-nginx-plus\">NGINX\u00a0Plus<\/a><\/span>, which you can try free for\u00a030 days. Both options work in the context of this tutorial, but if you want to further explore the advanced features in\u00a0<span style=\"color: #333333;\"><a style=\"color: #333333;\" href=\"https:\/\/www.nginx.com\/products\/nginx\/\">NGINX\u00a0Plus<\/a><\/span>, please request a free trial.<\/span>\n<h5><span style=\"font-family: helvetica; color: #000000;\"><strong>Installing NGINX Open Source<\/strong><\/span><\/h5>\n<span style=\"font-family: helvetica;\">Most Linux distributions and BSD variants make NGINX Open Source available in their standard package repositories, but it\u2019s usually not the latest version. We recommend downloading NGINX Open Source directly from\u00a0<strong>nginx.org<\/strong>. There are just a few extra steps for adding the NGINX repository to the Ubuntu package manager (apt).<\/span>\n\n<span style=\"font-family: helvetica;\">To install NGINX Open Source, follow these steps:<\/span>\n\n<span style=\"font-family: helvetica; color: #333333;\">1. Access your terminal.<\/span>\n\n<span style=\"font-family: helvetica;\">2. Download the NGINX signing key<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\">$\u00a0<strong>sudo wget\u00a0http:\/\/nginx.org\/keys\/nginx_signing.key<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">3. Add the key<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo apt-key add nginx_signing.key<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">4. Change directory to\u00a0<strong>\/etc\/apt<\/strong><\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ cd\u00a0 \/etc\/apt<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">5. Update the NGINX software<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo apt-get update<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">6. Install NGINX<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo apt-get install nginx<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">7. Type Y when prompted<\/span>\n\n<span style=\"font-family: helvetica;\">8. Start NGINX<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo systemctl start nginx.service<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">9. Check its status<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo systemctl status nginx.service<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">10. Continue to\u00a0Opening Your Web Page.<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-817 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-1024x321.jpg\" alt=\"ip-address\" width=\"640\" height=\"201\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-1024x321.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-300x94.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-768x240.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-1536x481.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address.jpg 1581w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n\n<span style=\"font-family: helvetica;\">Navigate to the Instances tab on the EC2 Dashboard if you are not there already. (One way is to click \u2002Services\u2002 in the top Console navigation bar, \u2002EC2\u2002 in the \u2002Compute\u2002 section, and Instances in the left\u2011hand navigation column.)<\/span>\n\n<span style=\"font-family: helvetica;\">Scroll right in the table until you can see the instance\u2019s public IP address in the Public IPv4 address. Select the address and copy it into the paste buffer.<\/span>\n\n<span style=\"font-family: helvetica;\">Open a new browser tab and paste the address into the address bar. The default <strong>Welcome to Nginx!<\/strong> the page appears, indicating that NGINX is installed and running but not yet configured.<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-845 size-full\" style=\"border: 1px solid gray;\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/MicrosoftTeams-image-19.png\" alt=\"\" width=\"614\" height=\"239\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/MicrosoftTeams-image-19.png 614w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/MicrosoftTeams-image-19-300x117.png 300w\" sizes=\"(max-width: 614px) 100vw, 614px\" \/>\n\n<span style=\"font-family: helvetica;\">11. Setting Up Sample Files<\/span>\n\n<span style=\"font-family: helvetica; font-size: 12pt;\">With a working version of NGINX or NGINX\u00a0Plus installed, it\u2019s time to put it to good use! Begin by setting up some files and directories.<\/span>\n\n<span style=\"font-family: helvetica;\">1. Change the directory to your home directory if you are not already there. In the following instructions, it is <strong>\/home\/ubuntu<\/strong>.<\/span>\n\n<span style=\"font-family: helvetica;\">2. Create a directory called <strong>public_html <\/strong>and change it.<\/span>\n\n<span style=\"font-family: helvetica;\">3. In the <strong>public_html <\/strong>directory, create a file called\u00a0<strong>HTML<\/strong>\u00a0and a directory called data.<\/span>\n\n<span style=\"font-family: helvetica;\">4. Change directory to <strong>\/etc\/nginx\/conf.d<\/strong><\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>cd \/etc\/nginx\/conf.d<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">5. Rename <strong>default<\/strong> <b>conf<\/b> to\u00a0<strong>default.conf.bak<\/strong>\u00a0to prevent NGINX from using it as the default configuration file.<\/span>\n\n<span style=\"font-family: helvetica;\">6. Create a file called <strong>server1.conf<\/strong> with this configuration in it:<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo nano server1.conf<\/strong><\/code><\/pre>\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-832 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ngnix-conf-1024x326.jpg\" alt=\"ngnix\" width=\"640\" height=\"204\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ngnix-conf-1024x326.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ngnix-conf-300x96.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ngnix-conf-768x245.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ngnix-conf.jpg 1064w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-830 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ls-1024x192.jpg\" alt=\"\" width=\"640\" height=\"120\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ls-1024x192.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ls-300x56.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ls-768x144.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ls.jpg 1062w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n\n<span style=\"font-family: helvetica;\">7. Reload NGINX<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo nginx -s reload<\/strong><\/code><\/pre>\n<blockquote><span style=\"font-family: helvetica; font-size: 14pt; color: #000000;\"><strong>Step7:<\/strong><\/span><\/blockquote>\n<span style=\"color: #000000;\"><strong><span style=\"font-family: helvetica;\">Install npm, nodejs and git on server<\/span><\/strong><\/span>\n\n<span style=\"font-family: helvetica;\">Let&#8217;s install npm<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo apt-get install -y npm<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">Let install node.js<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo apt-get install -y nodejs\n<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">Let install git<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo apt-get install -y git\n<\/strong><\/code><\/pre>\n<blockquote><span style=\"font-size: 14pt; font-family: helvetica; color: #000000;\"><strong>Step8:<\/strong><\/span><\/blockquote>\n<span style=\"font-family: helvetica;\">Install MySQL database on the server<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo apt install mysql-server<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">As soon as your installation is complete, the MySQL server should run automatically. You can check it with the following command.<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo systemctl status mysql<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">It must return some information about the MySQL server, such as Active: active (running). Let\u2019s log in as root.<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo mysql<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">You must set a password for your root now. Replace your_password_here with a strong password. <\/span><span style=\"font-family: helvetica;\">Now, let\u2019s exit and log in with the root credentials.<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo mysql -u root -p<\/strong><\/code><\/pre>\n<blockquote><span style=\"font-size: 14pt; font-family: helvetica; color: #000000;\"><strong>Step9:<\/strong><\/span><\/blockquote>\n<span style=\"color: #000000; font-family: helvetica;\">Installing MySQL Workbench for Easier Management<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-737 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-mysql-workbenh-45.png\" alt=\"mysql\" width=\"590\" height=\"277\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-mysql-workbenh-45.png 590w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/install-mysql-workbenh-45-300x141.png 300w\" sizes=\"(max-width: 590px) 100vw, 590px\" \/>\n\n<span style=\"font-family: helvetica;\">Click on + next to MySQL Connections.<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-738 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/mysql-connections-46.png\" alt=\"mysql\" width=\"602\" height=\"383\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/mysql-connections-46.png 602w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/mysql-connections-46-300x191.png 300w\" sizes=\"(max-width: 602px) 100vw, 602px\" \/>\n\n<span style=\"font-family: helvetica;\">Give your connection an arbitrary name (e.g.,\u00a0AWS SQL test\u00a0). From the Connection method dropdown menu, choose \u201cStandard TCP\/IP over SSH.\u201d The SSH Hostname is your EC2 Instance Public IPv4 DNS address. You can find this address on your EC2 dashboard by clicking on your instance and choosing details from the tab menu.<\/span>\n\n<span style=\"font-family: helvetica;\">Besides, change the SSH Username to\u00a0ubuntu\u00a0and locate your SSH Key File (the .pem file you got from AWS to connect via SSH). Finally, make sure that your user name is\u00a0root. Click OK, and your connection should appear on the first page.<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-740 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/mysql-connections-47.png\" alt=\"mysql\" width=\"602\" height=\"404\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/mysql-connections-47.png 602w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/mysql-connections-47-300x201.png 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/mysql-connections-47-150x100.png 150w\" sizes=\"(max-width: 602px) 100vw, 602px\" \/>\n\nAfter that, a copy should be taken from the existing database.\n<blockquote><span style=\"font-family: helvetica; font-size: 14pt;\"><strong>Step10:<\/strong><\/span><\/blockquote>\n<span style=\"font-family: helvetica;\">Ok then it should be fetched from GitHub on the server<\/span>\n\n<span style=\"font-family: helvetica;\">pull the code in the GitHub repository:<\/span>\n\n<span style=\"font-family: helvetica;\">1. First make a directory:<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo mkdir newdir<\/strong><\/code><\/pre>\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-837 size-full\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/new-dirctory-conf.jpg\" alt=\"\" width=\"1063\" height=\"338\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/new-dirctory-conf.jpg 1063w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/new-dirctory-conf-300x95.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/new-dirctory-conf-1024x326.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/new-dirctory-conf-768x244.jpg 768w\" sizes=\"(max-width: 1063px) 100vw, 1063px\" \/>\n\n<span style=\"font-family: helvetica;\">Open the directory if newly created, and edit server1.conf file or open public_html directory to create already,<\/span>\n\n<span style=\"font-family: helvetica;\">2. Open the directory:<\/span>\n\n<span style=\"font-family: helvetica;\">If the directory is newly created, then open it. Otherwise public_html is already created<\/span>\n\n<span style=\"font-family: helvetica;\">Open the directory I open public_html<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ cd public_html<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">3. Git initialize:<\/span>\n\n<span style=\"font-family: helvetica;\">After that, you need to initialize git in that directory<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo git init<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">4. Git remote add<\/span>\n\n<span style=\"font-family: helvetica;\">To add a new remote, use the git remote add command on the terminal, in the directory your repository is stored at. The git remote add command takes two arguments: A remote name, for example, origin.<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo git remote add origin\u00a0https:\/\/github.com\/niraltek\/sample-project.git<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">5. Git configure<\/span>\n\n<span style=\"font-family: helvetica;\">The git checkout command lets you navigate between the branches created by the git branch. Checking out a branch updates the files in the working directory to match the version stored in that branch, and it tells Git to record all new commits on that branch.<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo git config core.sparseCheckout true<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">6. Sparse checkout<\/span>\n\n<span style=\"font-family: helvetica;\">This command is used to create sparse checkouts, which change the working tree from having all tracked files present to only having a subset of those files. It can also switch which subset of files are present, or undo and go back to having all tracked files present in the working copy.<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo touch .git\/info\/sparse-checkout<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">7. Pull in the build directory in GitHub.<\/span>\n\n<span style=\"font-family: helvetica;\">This command is used to pull a folder or directory from GitHub<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo bash -c 'echo \"dist\/\" &gt; .git\/info\/sparse-checkout'<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">8. Generate personal access token:<\/span>\n\n<span style=\"font-family: helvetica;\">Before pulling from GitHub generate a personal access token first:<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-839 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-1024x618.jpg\" alt=\"github\" width=\"640\" height=\"386\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-1024x618.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-300x181.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-768x464.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github.jpg 1461w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n\n<span style=\"font-family: helvetica;\">Click the setting,<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-841 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github1-1024x573.jpg\" alt=\"\" width=\"640\" height=\"358\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github1-1024x573.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github1-300x168.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github1-768x430.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github1-1536x859.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github1.jpg 1587w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n\n<span style=\"font-family: helvetica;\">Click on the developer setting and click on generate a new token,<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-842 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/generate-token-1024x291.jpg\" alt=\"\" width=\"640\" height=\"182\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/generate-token-1024x291.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/generate-token-300x85.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/generate-token-768x219.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/generate-token-1536x437.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/generate-token.jpg 1887w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n\n<span style=\"font-family: helvetica;\">After that, you need to pull your code from GitHub.<\/span>\n\n<span style=\"font-family: helvetica;\">9. Pull your code:<\/span>\n\n<span style=\"font-family: helvetica;\">git pull origin master will fetch and update only a specific branch called master and origin in the remote repository. Often, the default branch in Git is a master branch, and it keeps updating frequently. A user can use any branch name to pull that branch from the remote<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\">$ sudo git pull origin main<\/code><\/pre>\n<span style=\"font-family: helvetica;\">username You must provide your GitHub username, <\/span><span style=\"font-family: helvetica;\">the password is your GitHub personal access token.<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-843 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-1024x172.jpg\" alt=\"github\" width=\"640\" height=\"108\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-1024x172.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-300x50.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-768x129.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login.jpg 1064w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n<blockquote><span style=\"font-family: helvetica; font-size: 14pt;\"><strong>Step11:<\/strong><\/span><\/blockquote>\n<span style=\"font-family: helvetica; color: #000000;\">Create a directory for the server connection<\/span>\n\n<span style=\"font-family: helvetica;\">1. First create a directory:<\/span>\n\n<span style=\"font-family: helvetica;\">Create a directory named demo-database -server<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo mkdir demo-database-server<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">2. Open the directory:<\/span>\n\n<span style=\"font-family: helvetica;\">After that open that directory<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ cd demo-database-server\/<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">3. Git initialize:<\/span>\n\n<span style=\"font-family: helvetica;\">After that, you need to initialize git in that directory<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo git init <\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">4. Git remote add:<\/span>\n\n<span style=\"font-family: helvetica;\">To add a new remote, use the git remote add command on the terminal, in the directory your repository is stored at. The git remote add command takes two arguments: A remote name, for example, origin.<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo git remote add origin\u00a0https:\/\/github.com\/niraltek\/sample-project.git<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">5. Git configure:<\/span>\n\n<span style=\"font-family: helvetica;\">The git checkout command lets you navigate between the branches created by the git branch. Checking out a branch updates the files in the working directory to match the version stored in that branch, and it tells Git to record all new commits on that branch.<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo git config core.sparseCheckout true<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">6. Sparse checkout:<\/span>\n\n<span style=\"font-family: helvetica;\">This command is used to create sparse checkouts, which change the working tree from having all tracked files present to only have a subset of those files. It can also switch which subset of files are present, or undo and go back to having all tracked files present in the working copy.<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo touch .git\/info\/sparse-checkout<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">7. Pull in the build directory in GitHub:<\/span>\n\n<span style=\"font-family: helvetica;\">This command is used to pull a folder or directory from GitHub<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo bash -c 'echo \"mysql-database\/\" &gt; .git\/info\/sparse-checkout'<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">8. Pull your code:<\/span>\n\n<span style=\"font-family: helvetica;\">Git pull origin master will fetch and update only a specific branch called master and origin in the remote repository. Often, the default branch in Git is a master branch, and it keeps updating frequently. A user can use any branch name to pull that branch from the remote,<\/span>\n\n<span style=\"font-family: helvetica;\">username You must provide your GitHub username, <\/span><span style=\"font-family: helvetica;\">the password is your GitHub personal access token. <\/span><span style=\"font-family: helvetica;\">We have already generated a personal access token and can use it.<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-843 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-1024x172.jpg\" alt=\"github\" width=\"640\" height=\"108\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-1024x172.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-300x50.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login-768x129.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/github-login.jpg 1064w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n\n<span style=\"font-family: helvetica;\">After that,<\/span>\n\n<span style=\"font-family: helvetica;\">9. Install pm2:<\/span>\n\n<span style=\"font-family: helvetica;\">PM2 is a production process manager for Node.js applications with a built-in load balancer. It allows you to keep applications alive forever, reload them without downtime, and facilitate common system admin tasks.<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo npm install pm2 -g<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">10. Start a Server:<\/span>\n<pre style=\"background-color: #e6e6e6; padding: 10px; margin-bottom: 10px; border-radius: 4px;\"><code style=\"background-color: #222; color: #1fbf51; display: block; padding: 20px; border-radius: 3px;\"><strong>$ sudo pm2 start db-connection.js<\/strong><\/code><\/pre>\n<span style=\"font-family: helvetica;\">11. Continue to Opening Your Web Page:<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-817 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-1024x321.jpg\" alt=\"ip-address\" width=\"640\" height=\"201\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-1024x321.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-300x94.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-768x240.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address-1536x481.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/ip-address.jpg 1581w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\n\n<span style=\"font-family: helvetica;\">Navigate to the Instances tab on the EC2 Dashboard if you are not there already. (One way is to click \u2002Services\u2002 in the top Console navigation bar, \u2002EC2\u2002 in the \u2002Compute\u2002 section, and Instances in the left\u2011hand navigation column).<\/span>\n\n<span style=\"font-family: helvetica;\">Scroll right in the table until you can see the instance\u2019s public IP address in the Public IPv4 address. Select the address and copy it into the paste buffer.<\/span>\n\n<img decoding=\"async\" loading=\"lazy\" class=\"aligncenter wp-image-706 size-large\" src=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-1024x477.jpg\" alt=\"angular\" width=\"640\" height=\"298\" srcset=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-1024x477.jpg 1024w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-300x140.jpg 300w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-768x357.jpg 768w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app-1536x715.jpg 1536w, https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-app.jpg 1919w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"<p>\u00a0 After installing angular in your local system follow the below procedure. Step1: Create a new angular application: ng new angular-app\u00a0\u00a0 Angular application view \u00a0 Step:2 \u00a0 MySQL Database: To be able to experiment with the code examples, you should have MySQL installed on your computer. You can download a free MySQL database at\u00a0https:\/\/www.mysql.com\/downloads\/. Install [&hellip;]<\/p>\n <a href=\"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/\" class=\"ReadMore\" title=\"Read More\">Read More<\/a>","protected":false},"author":5,"featured_media":769,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"image","meta":[],"categories":[16],"tags":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v18.5.1 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How to deploy Angular and Node.js on AWS EC2 instance? - Niraltek Blog<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to deploy Angular and Node.js on AWS EC2 instance? - Niraltek Blog\" \/>\n<meta property=\"og:description\" content=\"\u00a0 After installing angular in your local system follow the below procedure. Step1: Create a new angular application: ng new angular-app\u00a0\u00a0 Angular application view \u00a0 Step:2 \u00a0 MySQL Database: To be able to experiment with the code examples, you should have MySQL installed on your computer. You can download a free MySQL database at\u00a0https:\/\/www.mysql.com\/downloads\/. Install [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/\" \/>\n<meta property=\"og:site_name\" content=\"Niraltek Blog\" \/>\n<meta property=\"article:published_time\" content=\"2022-09-27T10:42:22+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-03-17T05:39:56+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-01.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"802\" \/>\n\t<meta property=\"og:image:height\" content=\"402\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Kesavan G\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"19 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.niraltek.com\/blog\/#website\",\"url\":\"https:\/\/www.niraltek.com\/blog\/\",\"name\":\"Niraltek Blog\",\"description\":\"Niraltek, IOT, BLOGS\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.niraltek.com\/blog\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/#primaryimage\",\"inLanguage\":\"en-US\",\"url\":\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-01.jpg\",\"contentUrl\":\"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-01.jpg\",\"width\":802,\"height\":402},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/#webpage\",\"url\":\"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/\",\"name\":\"How to deploy Angular and Node.js on AWS EC2 instance? - Niraltek Blog\",\"isPartOf\":{\"@id\":\"https:\/\/www.niraltek.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/#primaryimage\"},\"datePublished\":\"2022-09-27T10:42:22+00:00\",\"dateModified\":\"2023-03-17T05:39:56+00:00\",\"author\":{\"@id\":\"https:\/\/www.niraltek.com\/blog\/#\/schema\/person\/9b8770087f329d0a7c589d761edbca4c\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.niraltek.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to deploy Angular and Node.js on AWS EC2 instance?\"}]},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.niraltek.com\/blog\/#\/schema\/person\/9b8770087f329d0a7c589d761edbca4c\",\"name\":\"Kesavan G\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/www.niraltek.com\/blog\/#personlogo\",\"inLanguage\":\"en-US\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/eaa499554276e0dfd9ff274f3c9fb563?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/eaa499554276e0dfd9ff274f3c9fb563?s=96&d=mm&r=g\",\"caption\":\"Kesavan G\"},\"sameAs\":[\"http:\/\/www.niraltek.com\"],\"url\":\"https:\/\/www.niraltek.com\/blog\/author\/kesavan\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to deploy Angular and Node.js on AWS EC2 instance? - Niraltek Blog","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/","og_locale":"en_US","og_type":"article","og_title":"How to deploy Angular and Node.js on AWS EC2 instance? - Niraltek Blog","og_description":"\u00a0 After installing angular in your local system follow the below procedure. Step1: Create a new angular application: ng new angular-app\u00a0\u00a0 Angular application view \u00a0 Step:2 \u00a0 MySQL Database: To be able to experiment with the code examples, you should have MySQL installed on your computer. You can download a free MySQL database at\u00a0https:\/\/www.mysql.com\/downloads\/. Install [&hellip;]","og_url":"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/","og_site_name":"Niraltek Blog","article_published_time":"2022-09-27T10:42:22+00:00","article_modified_time":"2023-03-17T05:39:56+00:00","og_image":[{"width":802,"height":402,"url":"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-01.jpg","type":"image\/jpeg"}],"twitter_card":"summary_large_image","twitter_misc":{"Written by":"Kesavan G","Est. reading time":"19 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebSite","@id":"https:\/\/www.niraltek.com\/blog\/#website","url":"https:\/\/www.niraltek.com\/blog\/","name":"Niraltek Blog","description":"Niraltek, IOT, BLOGS","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.niraltek.com\/blog\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"ImageObject","@id":"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/#primaryimage","inLanguage":"en-US","url":"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-01.jpg","contentUrl":"https:\/\/www.niraltek.com\/blog\/wp-content\/uploads\/2022\/09\/angular-01.jpg","width":802,"height":402},{"@type":"WebPage","@id":"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/#webpage","url":"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/","name":"How to deploy Angular and Node.js on AWS EC2 instance? - Niraltek Blog","isPartOf":{"@id":"https:\/\/www.niraltek.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/#primaryimage"},"datePublished":"2022-09-27T10:42:22+00:00","dateModified":"2023-03-17T05:39:56+00:00","author":{"@id":"https:\/\/www.niraltek.com\/blog\/#\/schema\/person\/9b8770087f329d0a7c589d761edbca4c"},"breadcrumb":{"@id":"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.niraltek.com\/blog\/how-to-deploy-angular-node-js-on-aws-ec2-instance\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.niraltek.com\/blog\/"},{"@type":"ListItem","position":2,"name":"How to deploy Angular and Node.js on AWS EC2 instance?"}]},{"@type":"Person","@id":"https:\/\/www.niraltek.com\/blog\/#\/schema\/person\/9b8770087f329d0a7c589d761edbca4c","name":"Kesavan G","image":{"@type":"ImageObject","@id":"https:\/\/www.niraltek.com\/blog\/#personlogo","inLanguage":"en-US","url":"https:\/\/secure.gravatar.com\/avatar\/eaa499554276e0dfd9ff274f3c9fb563?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/eaa499554276e0dfd9ff274f3c9fb563?s=96&d=mm&r=g","caption":"Kesavan G"},"sameAs":["http:\/\/www.niraltek.com"],"url":"https:\/\/www.niraltek.com\/blog\/author\/kesavan\/"}]}},"_links":{"self":[{"href":"https:\/\/www.niraltek.com\/blog\/wp-json\/wp\/v2\/posts\/574"}],"collection":[{"href":"https:\/\/www.niraltek.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.niraltek.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.niraltek.com\/blog\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/www.niraltek.com\/blog\/wp-json\/wp\/v2\/comments?post=574"}],"version-history":[{"count":130,"href":"https:\/\/www.niraltek.com\/blog\/wp-json\/wp\/v2\/posts\/574\/revisions"}],"predecessor-version":[{"id":1512,"href":"https:\/\/www.niraltek.com\/blog\/wp-json\/wp\/v2\/posts\/574\/revisions\/1512"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.niraltek.com\/blog\/wp-json\/wp\/v2\/media\/769"}],"wp:attachment":[{"href":"https:\/\/www.niraltek.com\/blog\/wp-json\/wp\/v2\/media?parent=574"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.niraltek.com\/blog\/wp-json\/wp\/v2\/categories?post=574"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.niraltek.com\/blog\/wp-json\/wp\/v2\/tags?post=574"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}