Skip to content

Configuring ENV Variables for Backend

tks18 edited this page Dec 4, 2020 · 11 revisions

Special Steps if You have Deployed using Method 2 (i.e. Manually Using Git and Heroku):

  • If You have Deployed Manually Using Git and Heroku, then You have to follow the Following Steps to Configure Your Variables:

    • Login in to Your Heroku Account.

    • Open the App in which You have Deployed the backend.

    • Navigate to Settings Tab inside the app.

    • Click on the Button Reveal Vars to Reveal the Variable Section.

    • Very Important: See that the Variable name should be Same as the Below. All Variable Names will be in Uppercase..

  • In case You have Used my gindex-cli-tool, You don't have to worry about this, since everything will be taken care by the tool. You have to enter only the variable values.

Variables to be Configured:

  1. DBURL:
* Put the Connection String that You have Copied When you Setted up the MongoDB
* If Not, [Go to Here](https://github.com/tks18/gindex-v4/wiki/Setting-Things-Up#6-setup-your-mongo-database) and Copy the Connection String.

![https://telegra.ph/file/714c7545f23cf077ec013.png](https://telegra.ph/file/714c7545f23cf077ec013.png)
  1. SITE:
* This is your heroku backend site address, which should be as follows:

![https://telegra.ph/file/54853b23660ac00d5170c.png](https://telegra.ph/file/54853b23660ac00d5170c.png)
  1. EMAILID:
* Put the Email id that You have Created.
* If Not, [Go to Here](https://github.com/tks18/gindex-v4/wiki/Setting-Things-Up#4-create-a-mail-account) and Follow the Steps.

![https://telegra.ph/file/25ef1499c5004a8a50cee.png](https://telegra.ph/file/25ef1499c5004a8a50cee.png)
  1. EMAILPASS:
* Put Your Email Password for the SMTP Mail Account you have Created.
* If Not, [Go to Here](https://github.com/tks18/gindex-v4/wiki/Setting-Things-Up#4-create-a-mail-account) and Follow the Steps.

![https://telegra.ph/file/53d1600e721b6f8449a87.png](https://telegra.ph/file/53d1600e721b6f8449a87.png)
  1. EMAILPORT:
* Put the SMTP Port of the SMTP Mail Account.
* If Not, [Go to Here](https://github.com/tks18/gindex-v4/wiki/Setting-Things-Up#4-create-a-mail-account) and Follow the Steps.

![https://telegra.ph/file/db269b59f966f71c9c29f.png](https://telegra.ph/file/db269b59f966f71c9c29f.png)
  1. EMAILSERVICE:
* Enter the SMTP Mail Provider Name.
* Example: Yahoo, Yandex.

![https://telegra.ph/file/fe6271d0f75887186ce9c.png](https://telegra.ph/file/fe6271d0f75887186ce9c.png)
  1. EMAILSMTP:
* Enter the SMTP address you have Copied for the SMTP Mail Account.
* If Not, [Go to Here](https://github.com/tks18/gindex-v4/wiki/Setting-Things-Up#4-create-a-mail-account) and Follow the Steps.

![https://telegra.ph/file/f2df03abd3ef74bda2c7a.png](https://telegra.ph/file/f2df03abd3ef74bda2c7a.png)
  1. ADMINEMAIL:
* Enter the Root User's Email id - can be Anything, Need not be Same as the SMTP Mail Account email id.
* User Requests to Join will be Sent to this Admin Email, then the Admin can Accept the Requests.

![https://telegra.ph/file/2af4a67f683b1c43fdcba.png](https://telegra.ph/file/2af4a67f683b1c43fdcba.png)
  1. REPLYTOMAIL:
* Enter the Email same as Admin Email Variable before.

![https://telegra.ph/file/58c13104b287ca6f996ba.png](https://telegra.ph/file/58c13104b287ca6f996ba.png)
  1. MAXSESSIONS:
* This is used to restrict usage of account on desired number of login on different devices/browsers.

* For example: if you enter 2 maxsessions then you can login in 2 devices/browsers at one time and if you login in 3rd device then 1st one will get logged out

* Enter numeric value only!
  1. EMAILGIF:
* This will be used to enter a photo on top of emails.

* Enter a JPG/PNG/GIF and maintain 4:5 ratio otherwise it will land in spam!

![https://telegra.ph/file/e345ab0e7c5f515920d35.png](https://telegra.ph/file/e345ab0e7c5f515920d35.png)
  1. SITESECRET:
* This will be used when setting up root/superadmin user in backend to verify its you.

![https://telegra.ph/file/4b24d7c706a33d8ce5801.png](https://telegra.ph/file/4b24d7c706a33d8ce5801.png)
  1. TMDBAPI:
* This will be used to render Movies/TV Series posters and information.
Clone this wiki locally