Skip to content

gesposito/jackpot

Repository files navigation

Jackpot

Customized version of Sequelize's express-example showing a sample application (data is from superenalotto).

Requirements

  • You'll need MySQL installed on your machine (i.e. with brew install mysql or Docker)
  • You won't need yarn, simply use npm run instead, but yarn is preferred

Config

  • Step 0
cp config/config.mock.json config/config.json

Create your config file from the mocked one and customize it with your credentials

Feed data

  • Step 1
yarn feed

Will download all the Games data

Schema Migrations

  • Step 2
yarn db:migrate

Will run the migrations. If you run the app for the first time, this will be taken care by sequelize.sync() in bin/www.

yarn db:migrate:undo:all

Will undo the migrations (if needed)

Data seeding

  • Step 3
yarn seed:all

Will seed data in your DB

yarn seed:undo

Will undo the seeding (if needed)

Run

  • Step 4 (Profit)
yarn start