Skip to content

kunxin-chor/tgc15-framework-test

Repository files navigation

How to setup

  1. Install all node modules with yarn install

  2. Update database connections in database.json

  3. Log into mysql client with mysql -u root

  4. Create a new database user with the following commands

CREATE USER 'foo'@'%' IDENTIFIED WITH mysql_native_password BY 'bar';
grant all privileges on *.* to 'foo'@'%';

FLUSH PRIVILEGES;
  1. Create a new database named organic

  2. Exit mysql client (or open a new terminal)

  3. Install nodemon with npm install -g nodemon

  4. Add permission to run ./db-migrate.sh with `chmod +x ./db-migrate.sh

  5. Create the .env file like below, and fill in the details from your Cloudinary and Stripe account.

CLOUDINARY_NAME=
CLOUDINARY_API_KEY=
CLOUDINARY_SECRET=
CLOUDINARY_UPLOAD_PRESET=
DB_DRIVER=mysql
DB_PASSWORD=bar
DB_USER=foo
DB_DATABASE=organic
DB_HOST=localhost
STRIPE_PUBLISHABLE_KEY=
STRIPE_SECRET_KEY=
STRIPE_SUCCESS_URL=
STRIPE_CANCEL_URL=
  1. Run all migrations with ./db-migrate.sh up

  2. Add in dummy categories, brands and products as needed.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published