Skip to content

Commit

Permalink
Remove ip_hosted flag
Browse files Browse the repository at this point in the history
Install `ngrok` as extension
Update README.md and docs
  • Loading branch information
dormant-user committed Dec 4, 2023
1 parent 44d6f8b commit e025ac7
Show file tree
Hide file tree
Showing 14 changed files with 44 additions and 119 deletions.
7 changes: 1 addition & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,19 +29,14 @@ if __name__ == '__main__':
**Mandatory**
- **USERNAME**: Any username of choice.
- **PASSWORD**: Any password of choice.
- **VIDEO_SOURCE**: Source path for videos.
- **VIDEO_SOURCE**: Source path for `.mp4` files.

**Optional**
- **IP_HOSTED**: Boolean flag to specify if the API is hosted via public IP
- **VIDEO_HOST**: IP address to host the video. Defaults to `127.0.0.1`
- **VIDEO_PORT**: Port number to host the application. Defaults to `8000`
- **WEBSITE**: Website to add to CORS configuration.
- **WORKERS**: Number of workers to spin up the `uvicorn` server. Defaults to 1.

> - `IP_HOSTED` is typically set to `True` if port forwarding is used to expose the API
> - This will allow the application to host the API on local IP instead of `localhost` (if `VIDEO_HOST` is `None`)
> - This can also be done by specifying the local IP for the env var `VIDEO_HOST` manually
## Coding Standards
Docstring format: [`Google`][google-docs] <br>
Styling conventions: [`PEP 8`][pep8] and [`isort`][isort]
Expand Down
10 changes: 1 addition & 9 deletions docs/README.html
Original file line number Diff line number Diff line change
Expand Up @@ -74,23 +74,15 @@ <h3>Env Variables<a class="headerlink" href="#env-variables" title="Permalink to
<ul class="simple">
<li><p><strong>USERNAME</strong>: Any username of choice.</p></li>
<li><p><strong>PASSWORD</strong>: Any password of choice.</p></li>
<li><p><strong>VIDEO_SOURCE</strong>: Source path for videos.</p></li>
<li><p><strong>VIDEO_SOURCE</strong>: Source path for <code class="docutils literal notranslate"><span class="pre">.mp4</span></code> files.</p></li>
</ul>
<p><strong>Optional</strong></p>
<ul class="simple">
<li><p><strong>IP_HOSTED</strong>: Boolean flag to specify if the API is hosted via public IP</p></li>
<li><p><strong>VIDEO_HOST</strong>: IP address to host the video. Defaults to <code class="docutils literal notranslate"><span class="pre">127.0.0.1</span></code></p></li>
<li><p><strong>VIDEO_PORT</strong>: Port number to host the application. Defaults to <code class="docutils literal notranslate"><span class="pre">8000</span></code></p></li>
<li><p><strong>WEBSITE</strong>: Website to add to CORS configuration.</p></li>
<li><p><strong>WORKERS</strong>: Number of workers to spin up the <code class="docutils literal notranslate"><span class="pre">uvicorn</span></code> server. Defaults to 1.</p></li>
</ul>
<blockquote>
<div><ul class="simple">
<li><p><code class="docutils literal notranslate"><span class="pre">IP_HOSTED</span></code> is typically set to <code class="docutils literal notranslate"><span class="pre">True</span></code> if port forwarding is used to expose the API</p></li>
<li><p>This will allow the application to host the API on local IP instead of <code class="docutils literal notranslate"><span class="pre">localhost</span></code> (if <code class="docutils literal notranslate"><span class="pre">VIDEO_HOST</span></code> is <code class="docutils literal notranslate"><span class="pre">None</span></code>)</p></li>
<li><p>This can also be done by specifying the local IP for the env var <code class="docutils literal notranslate"><span class="pre">VIDEO_HOST</span></code> manually</p></li>
</ul>
</div></blockquote>
</section>
</section>
<section id="coding-standards">
Expand Down
7 changes: 1 addition & 6 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,19 +29,14 @@ if __name__ == '__main__':
**Mandatory**
- **USERNAME**: Any username of choice.
- **PASSWORD**: Any password of choice.
- **VIDEO_SOURCE**: Source path for videos.
- **VIDEO_SOURCE**: Source path for `.mp4` files.

**Optional**
- **IP_HOSTED**: Boolean flag to specify if the API is hosted via public IP
- **VIDEO_HOST**: IP address to host the video. Defaults to `127.0.0.1`
- **VIDEO_PORT**: Port number to host the application. Defaults to `8000`
- **WEBSITE**: Website to add to CORS configuration.
- **WORKERS**: Number of workers to spin up the `uvicorn` server. Defaults to 1.

> - `IP_HOSTED` is typically set to `True` if port forwarding is used to expose the API
> - This will allow the application to host the API on local IP instead of `localhost` (if `VIDEO_HOST` is `None`)
> - This can also be done by specifying the local IP for the env var `VIDEO_HOST` manually
## Coding Standards
Docstring format: [`Google`][google-docs] <br>
Styling conventions: [`PEP 8`][pep8] and [`isort`][isort]
Expand Down
7 changes: 1 addition & 6 deletions docs/_sources/README.md.txt
Original file line number Diff line number Diff line change
Expand Up @@ -29,19 +29,14 @@ if __name__ == '__main__':
**Mandatory**
- **USERNAME**: Any username of choice.
- **PASSWORD**: Any password of choice.
- **VIDEO_SOURCE**: Source path for videos.
- **VIDEO_SOURCE**: Source path for `.mp4` files.

**Optional**
- **IP_HOSTED**: Boolean flag to specify if the API is hosted via public IP
- **VIDEO_HOST**: IP address to host the video. Defaults to `127.0.0.1`
- **VIDEO_PORT**: Port number to host the application. Defaults to `8000`
- **WEBSITE**: Website to add to CORS configuration.
- **WORKERS**: Number of workers to spin up the `uvicorn` server. Defaults to 1.

> - `IP_HOSTED` is typically set to `True` if port forwarding is used to expose the API
> - This will allow the application to host the API on local IP instead of `localhost` (if `VIDEO_HOST` is `None`)
> - This can also be done by specifying the local IP for the env var `VIDEO_HOST` manually

## Coding Standards
Docstring format: [`Google`][google-docs] <br>
Styling conventions: [`PEP 8`][pep8] and [`isort`][isort]
Expand Down
8 changes: 1 addition & 7 deletions docs/genindex.html
Original file line number Diff line number Diff line change
Expand Up @@ -123,14 +123,10 @@ <h2 id="I">I</h2>
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%; vertical-align: top;"><ul>
<li><a href="index.html#pystream.models.config.FileIO.index">index (pystream.models.config.FileIO attribute)</a>
</li>
<li><a href="index.html#pystream.models.config.Session.info">info (pystream.models.config.Session attribute)</a>
</li>
</ul></td>
<td style="width: 33%; vertical-align: top;"><ul>
<li><a href="index.html#pystream.models.config.ip_address">ip_address() (in module pystream.models.config)</a>
</li>
<li><a href="index.html#pystream.models.config.EnvConfig.ip_hosted">ip_hosted (pystream.models.config.EnvConfig attribute)</a>
<li><a href="index.html#pystream.models.config.Session.info">info (pystream.models.config.Session attribute)</a>
</li>
</ul></td>
</tr></table>
Expand Down Expand Up @@ -317,8 +313,6 @@ <h2 id="U">U</h2>
<h2 id="V">V</h2>
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%; vertical-align: top;"><ul>
<li><a href="index.html#pystream.models.config.EnvConfig.validate_video_host">validate_video_host() (pystream.models.config.EnvConfig class method)</a>
</li>
<li><a href="index.html#pystream.models.config.Static.VAULT">VAULT (pystream.models.config.Static attribute)</a>
</li>
<li><a href="index.html#pystream.models.authenticator.verify">verify() (in module pystream.models.authenticator)</a>
Expand Down
Loading

0 comments on commit e025ac7

Please sign in to comment.