Running the server

Actions described here are executed in the web module.

Setting up the environment variables

Create a .env file with the schema of the .env.example file.

DB_HOST="your db host"
DB_USER="your db user"
DB_PASSWORD="your db password"
DB_NAME="your db name"
JWT_SECRET="your secret"
PORT="port of the app"
NODE_ENV=dev
SERVER_HOST=http://host:port
API_HOST="http://host:port/api/"
API_WALLET="wallet api url"
REACT_HOST=http://rect_host:react_port
triangle-exclamation

Installing dependencies

$ npm install

Starting the server and database

circle-check

Saving the addresses of the deployed contracts

circle-info

You only need to save the addresses of the deployed contracts once.

If it is the first time you are running the project or you deploy a new contract, you must register it in the database.

Insert the addesses of protocol contracts into the protocolLabs table and addresses of assets into loansAssetstable.

circle-info

You can fill the other fields as you prefer.

Last updated