A small pyramid webapp for self-hosted pastebin-like service
development.inicontains a version suitable for testing, you might want to changedebugtoolbar.hoststo something suitable.production.inicontains a version suitable for deployment, and disables testing functions and removes the toolbar.- By default, a user test with password test is enabled. Edit
security.pyto add users and passwords.
- First, get the contents of this repository : git clone git://github.com/epithumia/SimpleWebPaste
- Edit the files mentioned above
- Run
pip setup -e .(or better yet, make a virtualenv first, then$venv/bin/pip setup -e .) - Start the server with
pserve development.ini(or$venv/bin/pserve development.ini). - The development.ini and production.ini files are usable as-is with nginx, but will run fine without.
The template used for the login page is templates/login.jinja2, for the paste page it is paste.jinja2, the pastes are generated using render.jinja2 and finally the viewer uses a placeholder view.jinja2 to either display the paste or an error message. All of them rely on css files located in static/css.
The code to convert input into pretty output was done by Ninjifox and can be found at https://github.com/Ninjifox/SimplePaste