Skip to content

Latest commit

 

History

History
97 lines (87 loc) · 1.84 KB

README.md

File metadata and controls

97 lines (87 loc) · 1.84 KB

Description

Project builds API for recruitment and job search websites. Using NestJS Framework, combined with MongoDb database to store data.

How to install?

Required: NodeJS version >= 16.20.0

  1. Clone or download source code here
  2. Install package:


with npm:

npm install

or with yarn:

yarn

Config .env file

Add necessary values ​​to the .env file:

PORT =  
MONGO_URL = 
JWT_ACCESS_TOKEN_SECRET = 
JWT_ACCESS_EXPIRE = 
JWT_REFRESH_TOKEN_SECRET = 
JWT_REFRESH_EXPIRE = 
EMAIL_HOST = 
EMAIL_AUTH_USER= 
EMAIL_AUTH_PASS =
EMAIL_PREVIEW = 
CLIENT_ID = 
CLIENT_SECRET = 
REFRESH_URI = 
REFRESH_TOKEN = 
FOLDER_NAME = 
SHOULD_INIT = 
INIT_PASSWORD_ADMIN = 
INIT_PASSWORD_USER = 
INIT_PASSWORD_HR = 

How to run?

with npm:

npm run dev

or

npm run build

then

npm run start:prod

with yarn:

yarn run dev

or

yarn run build

then

yarn run start:prod

Try the API on swagger?

After running the program successfully, you can access the link http://localhost:[PORT]/swagger to try out the APIs


Deploy with Heroku

  1. create Procfile and config:
build: npm run build
web: npm run start:prod
  1. Sign up, login and create new app on Heroku:
  1. Config with Heroku, view details here:
  1. install and run Heroku CLI to check logs:
heroku logs --tail --app app_name