/xim_tech_task

xim_tech_task

Primary LanguageJavaScript

XIM tech task

Table of Contents

Getting Started

These instructions will help you set up and run the project on your local machine.

Prerequisites

need mysql to be installed on your local machine

Installation

  1. Clone the repository:

    git clone git@github.com:salamat9/xim_tech_task.git
  2. Navigate to the project directory:

    cd ximxim
  3. Install dependencies:

    npm install

Env Files

create .env file at root directory with these keys

PORT=
DB_USERNAME=
DB_PASSWORD=
DB_NAME=
DB_HOST=
DB_PORT=
JWT_SECRET_KEY=s
JWT_REFRESH_KEY=
ACCESS_TOKEN_LIFESPAN=
REFRESH_TOKEN_LIFESPAN=

Database Migrations

at src/config/db.json fill these json values with your database credentials it need to work with sequelize

{
    "username": "",
    "password": "",
    "database": "",
    "host": "",
    "dialect": "mysql"
}

Before running the application, you need to apply database migrations using Sequelize.

npx sequelize db:migrate

Uploads folder

at root folder create uploads directory

Run project

npm run dev

Still have questions? Or you can give me feedback.

write me on telegram https://t.me/sa1amat9