Skip to content

Commit

Permalink
chore: Update examples README as well
Browse files Browse the repository at this point in the history
  • Loading branch information
playpauseandstop committed Mar 20, 2020
1 parent 5f4862d commit d2bfb76
Showing 1 changed file with 14 additions and 12 deletions.
26 changes: 14 additions & 12 deletions examples/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ aiohttp-tus Examples
aiohttp_tus_app
===============

To illustrate that uploading via `tus.py <https://pypi.org/project/tus.py/>` library
To illustrate that uploading via `tus.py <https://pypi.org/project/tus.py/>`_ library
works well.

To run,
Expand All @@ -18,7 +18,7 @@ After, upload large files as,

.. code-block:: bash
poetry run tus-upload --chunk-size=1000000 /path/to/large-file http://localhost:8300/uploads
cd .. && poetry run tus-upload --chunk-size=1000000 /path/to/large-file http://localhost:8300/uploads
Then check that files uploaded to upload directory.

Expand All @@ -34,18 +34,20 @@ To run,
make -C .. EXAMPLE=uploads example
After, open ``http://localhost:8080`` to try upload. All uploads will be available in
temporary directory.
After, open ``http://localhost:8080`` and try to upload some files. All uploads will be
available in temporary directory.

.. important::
This example uses chunks size of 4MB, but you might want customize things by
setting up other chunk size via ``AIOHTTP_CLIENT_MAX_SIZE`` env var.
Chunk Size
----------

For example,
This example uses chunks size of 4MB, but you might want customize things by setting up
other chunk size via ``AIOHTTP_CLIENT_MAX_SIZE`` env var.

.. code-block:: bash
For example,

AIOHTTP_CLIENT_MAX_SIZE=10MB make -C .. EXAMPLE=uploads example
.. code-block:: bash
AIOHTTP_CLIENT_MAX_SIZE=10MB make -C .. EXAMPLE=uploads example
will set `client_max_size <https://docs.aiohttp.org/en/stable/web_reference.html#aiohttp.web.Application>`_
param to ``10_000_000`` bytes.
will set `client_max_size <https://docs.aiohttp.org/en/stable/web_reference.html#aiohttp.web.Application>`_
param to ``10_000_000`` bytes.

0 comments on commit d2bfb76

Please sign in to comment.