Skip to content
This repository has been archived by the owner on Jan 26, 2021. It is now read-only.

Deployed the Application on Heroku and added Instruction guide with other files #1160

Open
wants to merge 7 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 60 additions & 0 deletions Instruction for Heroku Deployment.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# How to deploy the web app to Heroku

**Step 1.** For deploying the vms web app to heroku, you will need heroku cli.

For Installing Heroku CLI refer to this [Heroku Installation Documentation](https://devcenter.heroku.com/articles/heroku-cli) for different installation methods.


**Step 2.** Create Procfile for Heroku Deployment

You will need to create a Procfile which will provide the instruction for Heroku Deployment,make sure Procfile should be created inside the `vms` directory.

Procfile should look like:

```
web: gunicorn vms.wsgi --log-file -
```

**Step 3.** Edit the requirements.txt file

Add `gunicorn` inside the requirements.txt below all packages.

**Step 4.** Create a .env file which is same as .env.example

**Step 5.** Run the following cmd's to deploy the web app to heroku.

**Note:** Make sure you are inside `vms/vms` directory during deployment process

```
$ git init
$ heroku git:clone -a vms-r
$ git add .
$ git commit -m "commits"
$ git push heroku master
$ heroku ps:scale web=1
```
Check logs using `heroku logs --tail`

**Note:** vms-r is the name of the web app created in the heroku for deployment.

**Note:** Procfile and .env should be created inside main vms folder as metioned in Step 2 refer to below file structure.

```
vms
|___ Procfile
|___ requirements.txt
|___ .env
|___ vms
| |__ wsgi.py
| |__ utils.py
| |__ ...other files
|
|__ ...other files
```







Binary file modified requirements.txt
Binary file not shown.
1 change: 1 addition & 0 deletions vms/Procfile
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
web: gunicorn vms.wsgi --log-file -