Skip to content

TMH-SE/ticket-sales-back

Repository files navigation

Logo

1. Preparation

1.1 Clone code into local

$ git clone https://github.com/TMH-SE/ticket-sales-backend.git

1.2 Create .env

# follow the file .env.example
SECRET_KEY=h3l1oW0rld
PORT=<your_port_run_backend>

1.3 Creat awsConfig.json (for production)

# follow the file .aws.json.example
{
"accessKeyId": <YOUR_ACCESS_KEY_ID>,
"secretAccessKey": <YOUR_SECRET_ACCESS_KEY>,
"sessionToken": <YOUR_SESSION_TOKEN>,
"region": "us-east-1"
}

1.4 Install dependencies

# using npm
$ npm i

# using yarn
$ yarn add

1.5 Run dbseed

# create table and account admin
$ NODE_ENV=development npm run db:seed

2. Running the app

# development
$ npm run start

# watch mode
$ npm run start:dev

# production mode
$ npm run start:prod

# Running the app with webpack
  # 1. Build webpack
    $ npm run webpack
  # 2. Once webpack started to watch files, run another command in the another command line window:
    $ npm run start:webpack

3. Git policy

3.1 Branch

  # create branch before perform your task
  # naming branch follow the pattern: yourName_yourTask
  # e.g: hieu_khachHang
  $ git branch <your_branch>

  # check out your branch before start code
  $ git checkout <your_branch>

3.2 Commit code

  # save your changes
  $ git add .

  # commit code
  # your comment must be concise and describe what you did
  $ git commit -m 'your comment'

3.3 Pull code

  # always pull code before whenever start coding or push code to repository
  $ git pull origin master

3.4 Push code

  # push code from local to repository
  $ git push origin <your_branch>

*NOTE: Before push code, you must pull code and fix conflict

4. License

Project is MIT licensed.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published