Skip to content

Latest commit

 

History

History
71 lines (48 loc) · 1.26 KB

README.md

File metadata and controls

71 lines (48 loc) · 1.26 KB

Prerequisites

Node, Docker and docker-compose for development. This is a template for prototyping or building small to medium sized projects.

Tech Stack

  1. Postgres - Database
  2. ExpressJS - Web Framework
  3. ReactJS - Frontend Framework

Development

  1. Start database
$ docker-compose up
  1. Run server
# remember to setup .env
$ cd server && npm i && npm run start:dev
# check localhost:3000
  1. Run client
# remember to setup .env
$ cd client && npm i && npm start
# check localhost:8080

Production

  1. Build image

Build the image using docker-compose. Note: update the .env to use database host as db (the same as the database container name).

$ docker-compose -f docker-compose.prod.yml build
  1. Build frontend
$ cd client && npm run build
  1. Run
$ docker-compose -f docker-compose.prod.yml up
# check localhost:80

Testing

Use Jest for testing. Create test files with *.test.js extensions.

License

This project is licensed under the MIT License - see the LICENSE file for details

Author

Aldrich

TODO

  • update README
  • add linter
  • fix tests and travis CI