Skip to content

Commit

Permalink
Add virtual environment and how to run notes
Browse files Browse the repository at this point in the history
  • Loading branch information
campb303 committed Jun 30, 2021
1 parent f9a8616 commit ed870f8
Showing 1 changed file with 22 additions and 3 deletions.
25 changes: 22 additions & 3 deletions docs-src/api/Installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,29 @@ The code is available on [GitHub]({{ config.repo_url }}). Available package vers
pip install -U pop
```

!!! tip "Using a virtual environment is recommended for reproducibility."
Create a virtual environment called `__venv__`:
```bash
python3 -m venv __venv__
```

Activate the virtual environment:
```bash
source __venv__/bin/activate
```

Update pip:
```bash
pip install -U pip
```

=== "Install via pip"
To install webqueue2-api 0.9.1, you can run:

```
pip install git+{{ config.repo_url }}@0.9.1#egg=webqueue2-api
```

If you'd like a version other than 0.9.1 simply replace the that version number with a different version listed on the [releases page]({{ config.repo_url }}/releases).

=== "Install via requirements file"
To install webqueue2-api 0.9.1, place the following line your requirements file:

Expand All @@ -28,4 +42,9 @@ The code is available on [GitHub]({{ config.repo_url }}). Available package vers
pip install -r requirements.txt
```

If you'd like a version other than 0.9.1 simply replace the that version number with a different version listed on the [releases page]({{ config.repo_url }}/releases).
If you'd like a version other than 0.9.1 simply replace the that version number with a different version listed on the [releases page]({{ config.repo_url }}/releases).

To start the server, run the following while your virtual environment is activated:
```bash
gunicorn webqueue2api.api:app
```

0 comments on commit ed870f8

Please sign in to comment.