nktimesheeting
http://nktimesheeting.herokuapp.com
The stack
Frontend
API Server
Toolchain dependencies
- Stack
- NPM
- Docker
Development
Setup
Install postgres and make a new user and db:
createuser newapp -W # choose 'newapp' for the password
createdb newapp --owner=newapp
createdb newapp-testing --owner=newapp
Run a server for the static files on port 8080
:
cd web
npm install webpack -g
npm install
npm run dev
Run the API server on port 3000
:
cd server
stack build --exec server
The static server will automatically forward API requests to the API server
during development. Visit http://localhost:8080/
to develop.
Testing
Run server tests with stack
cd server
stack test
Run frontend tests with npm
cd web
npm test
Deployment
Ensure you have docker setup and running. If you're on OSX look into docker-machine.
Use make
to build everything:
make
Commit and push to Heroku:
heroku buildpacks:set https://github.com/nathankot/heroku-binary-buildpack
git commit -m "Build"
git push heroku master