// To create the database on local storage
FROM: (https://www.microfocus.com/documentation/idol/IDOL_12_0/MediaServer/Guides/html/English/Content/Getting_Started/Configure/_TRN_Set_up_PostgreSQL.htm)
- Download and install a PostgreSQL server. For instructions, refer to the PostgreSQL documentation on www.postgresql.org.
- Add the PostgreSQL bin directory path to the PATH environmental variable.
- Open the psql command-line tool:
In the Windows Command Prompt, run the command:
psql -U postgres
Enter your password when prompted (On our code, we set the password to hogwarts6393) - Run a CREATE DATABASE command to create a new database (On our code, we set the db name to be gymCorp)
CREATE DATABASE gymCorp WITH ENCODING 'UTF8' LC_COLLATE='English_United Kingdom' LC_CTYPE='English_United Kingdom';
// To run our server
- Open the terminal/command prompt, navigate to the server directory and install the packages :
cd server
npm i - Navigate to the database directory:
cd database - Start the database server by running the following command:
node index.js - Once the database server is running, go back to the server directory by running:
cd .. - Create the necessary tables and data by running the following command:
node createData - Start the server by running the following command:
nodemon app.js
// To run our client
- Open the terminal/command prompt, navigate to the client directory and install the packages:
cd client
npm i - Start the client by running the following command:
npm start
// Once web app is launched
Log in as existing user:
email : [email protected]
password : test123
Log in as existing staff:
email : [email protected]
password : test123
Log in as existing manager:
email : [email protected]
password : test123