Skip to content

Latest commit

 

History

History
84 lines (64 loc) · 2.83 KB

CONTRIBUTING.md

File metadata and controls

84 lines (64 loc) · 2.83 KB

Files structure

We are about to change the files structure to a more good one for modern file structures

Website                            Description
Api The Restful API
Config Config files
Controllers The controllers that handle the HTTP requests
Desktop Desktop version, ElectronJS
Grahpql GraphQL API (not available yet)
Middlewares Middlewares of the Back-end API
Models Models of the Back-end API
Passport Authentication Oauth2.0 of the Back-end API
Public Front-end code
Resources
Routes Routes of the Back-end API
Views EJS views for the Front-end

Init the project in local env

Clone the repo

git clone https://github.com/mouadTaoussi/survey-app.git
cd survey-app

Install the dependencies

npm install

Create .env file and add those credentiels below:

touch Config/.env && nano Config/.env
NODE_ENV = development
NODE_PORT = 5000
HOST_NAME = localhost:5000

EXPRESS_SESSION_KEY = xxxxxxxxxxxxxxxxxxxxxxxxxxxxx
JSON_WEB_TOKEN_SECRET = xxxxxxxxxxxxxxxxxxxxxxxxxxx

GOOGLE_ID = xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
GOOGLE_SECRET = xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
LINKEDIN_ID = xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
LINKEDIN_SECRET = xxxxxxxxxxxxxxxxxxxxxxxxxxxxx
GITHUB_ID = xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
GITHUB_SECRET = xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

DATABASE_CONNECTION = xxxxxxxxxxxxxxxxxxxxxxxxx

FIREBASE_API_KEY = xxxxxxxxxxxxxxxxxxxxxxxxxxxx
FIREBASE_AUTH_DOMAIN = xxxxxxxxxxxxxxxxxxxxxxxx
FIREBASE_DATABASE_URL = xxxxxxxxxxxxxxxxxxxxxxx
FIREBASE_STORAGE_BUCKET = xxxxxxxxxxxxxxxxxxxxx
FIREBASE_PROJECT_ID = xxxxxxxxxxxxxxxxxxxxxxxxx

REDIS_LABS_HOST = xxxxxxxxxxxxxxxxxxxxxxxxxxxxx
REDIS_LABS_PORT = 19679
REDIS_LABS_PASSWORD = xxxxxxxxxxxxxxxxxxxxxxxxx

EMAIL_ADDRESSE = xxxxxxxxxxxxxxxxxxxxxx
EMAIL_PASSWORD = xxxxxxxxxxxxxxxxxxxxxx

run app locally

npm run dev

run app when it is in prod

npm run start