docs: add guides and summary
This commit is contained in:
parent
6b96bf8efb
commit
0b16acf68c
12 changed files with 146 additions and 70 deletions
|
|
@ -1,68 +1,68 @@
|
|||
Get Started
|
||||
===========
|
||||
|
||||
Installation
|
||||
------------
|
||||
Install
|
||||
"""""""
|
||||
|
||||
.. code-block:: shell
|
||||
|
||||
$ python3 -m pip install httpaste-victorykit
|
||||
$ httpaste --help
|
||||
|
||||
Create configuration
|
||||
--------------------
|
||||
|
||||
Create Configuration
|
||||
""""""""""""""""""""
|
||||
|
||||
.. code-block:: shell
|
||||
|
||||
$ httpaste default-config --dump myconfig.ini
|
||||
|
||||
Run a local test server
|
||||
-----------------------
|
||||
.. note::
|
||||
The default configuration creates an in-memory SQLite backend, which is not
|
||||
suitable for WWW deployments. Visit `backend`, for more
|
||||
information on configuring the backend.
|
||||
|
||||
|
||||
Run a Local Evaluation Server
|
||||
"""""""""""""""""""""""""""""
|
||||
|
||||
.. code-block:: shell
|
||||
|
||||
$ httpaste standalone --config myconfig.ini --port 8080
|
||||
* Serving Flask app 'httpaste' (lazy loading)
|
||||
* Environment: production
|
||||
WARNING: This is a development server. Do not use it in a production deployment.
|
||||
Use a production WSGI server instead.
|
||||
* Debug mode: off
|
||||
* Running on all addresses.
|
||||
WARNING: This is a development server. Do not use it in a production deployment.
|
||||
* Running on http://localhost:8080/ (Press CTRL+C to quit)
|
||||
|
||||
|
||||
Publish a Private Paste
|
||||
-----------------------
|
||||
"""""""""""""""""""""""
|
||||
|
||||
.. code-block:: shell
|
||||
|
||||
$ echo 'My first private paste' | curl -F 'data=<-' \
|
||||
-u myusername:mypassword \
|
||||
http://localhost:8080/paste/private
|
||||
$ echo 'My first private paste' | curl -F 'data=<-' -u myusername:mypassword http://localhost:8080/paste/private
|
||||
http://localhost:8080/paste/private/UALUA9
|
||||
|
||||
.. note::
|
||||
If the user does not exist, they will be created upon authentication.
|
||||
|
||||
|
||||
Retrieve a Private Paste
|
||||
------------------------
|
||||
""""""""""""""""""""""""
|
||||
|
||||
.. code-block:: shell
|
||||
|
||||
$ curl -u myusername:mypassword http://localhost:8080/paste/private/UALUA9
|
||||
My first private paste
|
||||
|
||||
|
||||
Publish a Public Paste
|
||||
-----------------------
|
||||
""""""""""""""""""""""
|
||||
|
||||
.. code-block:: shell
|
||||
|
||||
$ echo 'My first public paste' | curl -F 'data=<-' \
|
||||
http://localhost:8080/paste/public
|
||||
$ echo 'My first public paste' | curl -F 'data=<-' http://localhost:8080/paste/public
|
||||
http://localhost:8080/paste/public/X4L39J
|
||||
|
||||
|
||||
Retrieve a Public Paste
|
||||
------------------------
|
||||
""""""""""""""""""""""""
|
||||
|
||||
.. code-block:: shell
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue