Skip to content

Latest commit

 

History

History
118 lines (77 loc) · 2.11 KB

README.md

File metadata and controls

118 lines (77 loc) · 2.11 KB

Node.js User Onboarding application

A Node based module using Mongodb to onboard user's into a very basic application, secured using JWT authorization.

The Node.js app uses Hapi Framework and Hapi Swagger

PS : This is an ES6 translation of this project

Contents

Project Dependencies

Manual Deployment

Setup Node.js

Inorder to setup NodeJS you need to fellow the current steps:

Mac OS X

  • Step1: Install Home brew
$ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

$ brew -v
  • Step2: Install Node using Brew
$ brew install node

$ node -v

$ npm -v

Linux Systems

  • Step1: Install Node using apt-get
$ sudo apt-get install curl python-software-properties

$ curl -sL https://deb.nodesource.com/setup_12.x | sudo -E bash -

$ sudo apt-get install nodejs

$ node -v

$ npm -v

Setup Node User Onboarding Application

  • Step1: Git clone the application

  • Step2: Install node modules

$ npm i

or 

$ npm install
$ npm i -g @babel/core @babel/node @babel/cli
  • Step3: Copy .env.example to .env
$ cp .env.example .env
  • Step4a: Start the application
$ npm start
  • Step4b: Start With Nodemon
$ npm run startWithNodemon

Build

$ npm run build

Starting the build

$ npm run deployment

The current version of your application would be running on http://localhost:8000 or http://IP_OF_SERVER:8000 (in case you are running on the server)

Story AR

For AWS CodeDeploy setup

#!/bin/bash
sudo yum -y update
sudo yum -y install ruby
sudo yum -y install wget
cd /home/ubuntu/storyar/StoryAR-backend
wget https://aws-codedeploy-us-east-1.s3.amazonaws.com/latest/install
sudo chmod +x ./install
sudo ./install auto