Version 1.0.0
This project aims to Build a Storefront Backend With the use of the following libraries [TypeScript, Postgres Database, Node/ExpressJS, dotenv, Jasmine Unit Test, Supertest, bcrypt for hashing Password, db-migrate, jsonwebtoken].This project barely touches the surface of what is possible but will prove your ability to use what you’ve learned in real-world scenarios.
in your CMD run the Following:
- psql -U postgres
- CREATE USER nasif_udacity WITH PASSWORD 'nasif123';
- [Create Main DB] CREATE DATABASE nasif_store;
- [Create Test DB] CREATE DATABASE nasif_store_test;
- GRANT ALL PRIVILEGES ON DATABASE nasif_store TO nasif_udacity;
- GRANT ALL PRIVILEGES ON DATABASE nasif_store_test TO nasif_udacity;
Ports: The Database running Port: 5432 The Store Backend running Port: 3020
You can Install this project to your PC using clone the repo to your github account then Download It as a ZIP File to your PC.
or Clone it using GIT git clone
if you access it from GITHUB.
-
After The Installation you can now use the project files by UnZip the file and open it on any Code Text Editor (VS Code).
-
You Must First install packages (dependencies): open Project-File in terminal and npm i.
-
Then npm run start to start the server.
- Install The Pacakges if node_module File not attached:
npm i
- Run unit tests with Jasmine:
npm run test-Win
for Windows ornpm run test-Mac
for Mac - Start server:
npm run start
• PORT=3020 • ENV=dev • POSTGRES_HOST=localhost • POSTGRES_PORT=DB_Port • POSTGRES_DB=DB_Name • POSTGRES_DB_TEST=Test_DB_Name • POSTGRES_USER=yourUN • POSTGRES_PASSWORD=yourPass • BCRYPT_PASSWORD = user-secret-password • SALT_ROUND=10 • TOKEN_SECRET=user-secret-token
- Udacity
- EgFwd
© Udacity And Mohammed Nasif.