InSnync CRM API's is developed with Adonisjs and mysql.
1. Production
==> Branch Name: main
==> Domain Name: main.insync-crm-api.com
2. Development
==> Branch Name: develop
==> Domain Name: develop.insync-crm-api.com
-
Clone repository
git clone https://github.com/abendsoft/insync-crm-api.git cd insync-crm-api yarn install
-
Create a new
.env
file for the backend and generate a newAPP_KEY
. Copy the output and paste it into the.env
file at the end of the line forAPP_KEY
.cp .env.example .env node ace generate:key #Generates new APP_KEY
-
Within the
.env
file, configure the MYSQL* variables to suit your environment setup. -
launch
start development
server.yarn dev
-
You won't be able to
login
because there are no users. So, it is time to seed the database. -
To prepare (seed) the database with mock data:
-
First, let's migrate the database.
node ace migration:run
-
Next, Let's seed important tables on the database. Run the index seeder command below to run all configured seeders for the application and fully setup it up in one command:
node ace db:seed --files="database/seeders/MainSeeder/Index.ts"
If you are on Windows and having errors, you can run:
node ace db:seed --files="database\seeders\MainSeeder\Index.ts"
Please note that this operation could take a couple of minutes.
-
-
After running the index seeder, all users generated will be logged to file. Check the file:
database/data/seeded_users.txt
and take note of the user credentials logged to the file. -
Get an email and password of a user and log in.
-
Congratulations. You have successfully set up the InSync.