To exercise RESTful API development, unit testing, JOI validation and MySQL.
- NPM
- MySQL
- Clone the repo
git clone git@github.com:renatozr/store-manager-api.git
- Enter the directory
cd store-manager-api
- Install NPM packages
npm install
- Rename .env.example file to .env
- Fill in the environment variables (example below)
PORT=3001 MYSQL_HOST=localhost MYSQL_PORT=3306 MYSQL_USER=root MYSQL_PASSWORD=password
- Setup database
npm run initdb
- Run the project
npm run dev
- Run the project tests
npm test