Powered by Nest on AWS Elastic Beanstalk.
$ npm install
# export env
# $ cp .env.template .env
# $ export $(cat .env | grep -v '^#' | grep -v '^$' | xargs)
# run middlewares on docker
$ make up-middleware
# migrate database
$ npm run migration:run
# development
$ npm run start
# watch mode
$ npm run start:dev
# production mode
$ npm run start:prod
Install awscli and ebcli.
# export aws keypar
$ export AWS_ACCESS_KEY_ID="xxxx"
$ export AWS_SECRET_ACCESS_KEY="yyyy"
$ export AWS_DEFAULT_REGION="ap-northeast-1"
# Create resources and deploy to AWS
$ make create
# Deploy only
$ make deploy
# Scale out
$ eb scale 3
# Terminate resources on AWS
$ make terminate
# load testing senario via websocket
$ npx artillery run senarios/websocket.yml
# unit tests
$ npm run test
# e2e tests
$ npm run test:e2e
# test coverage
$ npm run test:cov