项目作者: SethiPawandeep

项目描述 :
Summer of 2017. Project to learn Node.js. Main project on branch nic-nightduty-app.
高级语言: JavaScript
项目地址: git://github.com/SethiPawandeep/summer-project.git
创建时间: 2017-06-11T11:26:40Z
项目社区:https://github.com/SethiPawandeep/summer-project

开源协议:

下载


summer-project

A project in node for the summer of ‘17.

How to run:

Step 1

Install node on your machine.

Step 2

Install postgres.

Type sudo apt-get update and then sudo apt-get install postgres postgres-contrib on the terminal.

Configure postgres as in credentials var in controllers/authController.js.

Step 4

Clone project on your machine. cd into the project directory and type npm install.

Step 5

Register for reCAPTCHA V2 on the domain localhost here.
Create a file called myRecaptcha.js in the main project directory and type

  1. module.exports = {
  2. secretKey: 'YOUR_SERVER_SIDE_SECRET'
  3. }

Step 6

Create a directory called SSL in the root directory of the project. Type the following commands in the terminal to generate your self signed SSL Certificate

  1. $ openssl genrsa -out key.pem 1024
  2. $ openssl req -new -key key.pem -out certrequest.csr
  3. $ openssl x509 -req -in certrequest.csr -signkey key.pem -out cert.pem

Step 7

npm start the project and type localhost:3000 in your browser and you are ready to go! :smiley:

Progress as of 19/06: A simple register and login form implemented. Sessions managed properly. Database(PostgreSQL) connected.

Progress as of 21/06: reCAPTCHA added to registration form.

Progress as of 25/06: Node module bcrypt used to encrypt password on the server.

Progress as of 30/06: HTML5 Geolocation implemented. Latitude and Longitude submitted through register form.

Progress as of 03/07: HTTPS server used. Self-signed SSL certificate created.