How to deploy in local machine

Deploy Api-Server, Admin Web Dashboard, Mobile App, Customer Web App and Amplitude Dashboard for Analytics in Local machine

Installation Steps

Api Server

  1. run cd enatega-multivendor-api in terminal

  2. Set environment file (.env)

    PORT=8001
    CONNECTION_STRING=<DB-CONNECTION-STRING>
    RESET_PASSWORD_LINK=http://localhost:8001/auth/reset/?reset=
    SERVER_URL=http://<LOCAL IP>:8001/
    STRIPE_WEBHOOK_ENDPOINT_SECRET=<STRIPE'S WEBHOOK SECRET>
    DASHBOARD_URL=http://localhost:3000/
    WEB_URL=http://localhost:3006/
    ORDER_DETAIL_WEB_URL=order-detail/
  3. Create an account on MONGO ATLAS, then Create a database, copy connection string and paste it in .env against the key CONNECTION_STRING. Read more about how to use mongo atlas here

  4. then run npm install in terminal to install packages

  5. install nodemon globally using npm i -g nodemon then run nodemon in terminal to start the api.

NOTE: For notifications to work on android you'll have to upload FCM token on expo server. Read more about it here

Admin Web Dashboard

  1. run cd enatega-multivendor-admin in terminal

  2. Install packages by npm install or yarn install

  3. update SERVER_URL, WS_SERVER_URL, CLOUDINARY_UPLOAD_URL, CLOUDINARY_CATEGORY, CLOUDINARY_FOOD, CLOUDINARY_PROFILE in src/config/config.js if you are running API/Server on different url/port

  4. run npm start to run the admin dashboard

install expo-cli globally using npm install -g expo-cli before trying to run the apps.

Mobile App

  1. Go to folder enatega-mutlivendor-app

  2. Install packages by npm install or yarn install

  3. update GRAPHQL_URL, WS_GRAPHQL_URL, SERVER_URL in /environment.js if you are running API/Server on different url/port, development configurations are used when you are running app locally.

  4. Run the mobile app by expo start

  5. Scan the QR code with the Expo app (Android) or the Camera app (iOS).

Rider App

  1. Go to folder enatega-multivendor-rider

  2. Install packages by npm install or yarn install

  3. update GRAPHQL_URL and WS_GRAPHQL_URL in /environment.js if you are running API/Server on different url/port, development configurations are used when you are running app locally.

  4. Run the mobile app by expo start

  5. Scan the QR code with the Expo app (Android) or the Camera app (iOS).

Restaurant App

  1. Go to folder enatega-multivendor-restaurant

  2. Install packages by npm install or yarn install

  3. update GRAPHQL_URL and WS_GRAPHQL_URL in /environment.js if you are running API/Server on different url/port, development configurations are used when you are running app locally.

  4. Run the mobile app by expo start

  5. Scan the QR code with the Expo app (Android) or the Camera app (iOS).

Customer Web App

  1. Go to folder enatega-multivendor-web

  2. Install packages by npm install or yarn install

  3. Update SERVER_URL WS_SERVER_URL GOOGLE_CLIENT_ID FACEBOOK_SCHEME FACEBOOK_ID STRIPE_PUBLIC_KEY PAYPAL_KEY FACEBOOK_NAME GOOGLE_MAPS_KEY in /enatega-mutlivendor-web/src/config/constant.js'

  4. Run npm start inside the folder

Analytics Dashboard

  1. Explore demo version on https://amplitude.com get amplitude key and replace it with amplitudeApiKey in app.json of mobile app.

  2. You can further explore dashboard by following amplitude documentation. https://developers.amplitude.com/

Last updated