NOTE: Developer mode does not exist at this stage of the project, so multiple student accounts are required to fully test features in the lobby.
- Clone the repository
- In the root directory,
npm install
- Set up the database (instructions below)
- To run the app,
node app.js
ornpm start
- Visit localhost:8081 in your browser to access the application
Ubuntu
$bash sudo apt-get install mysql-server
OSX
$bash brew install mysql
$bash mysql.server start
Windows
Follow instructions on MySQL official site: https://dev.mysql.com/downloads/windows/
Create a new user for accessing the database. Run the following 3 commands:
CREATE USER 'sample_username'@'localhost' IDENTIFIED BY 'sample_password';
Grant user privilege:
GRANT ALL PRIVILEGES ON * . * TO 'sample_username'@'localhost';
Update database privilege:
FLUSH PRIVILEGES;
The sample_username
and sample_password
are used in the config.json for accessing the database.
Create a database with name sample_database_name
.
CREATE DATABASE sample_database_name
Add the following things to config.json.
config.json
------------------
{
...
"db-host": "127.0.0.1",
"db-dialect": "mysql",
"db-name": "sample_database_name",
"db-username": "sample_username",
"db-password": "sample_password",
}
5. Migrate and set up database using the Sequelize CLI
Global install
npm install -g sequelize-cli
sequelize db:migrate
Local install to node_modules folder
npm install --save sequelize-cli
.\node_modules\.bin\sequelize db:migrate
Branch names should be formatted as such:
[tag]/[component]/[feature]
Tag | Description |
---|---|
wip | Preliminary work |
bug | Bug fixing |
exp | Experimental/test codes |
ftr | Features to be implemented |
test | Testing |