Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ptpb/pb
pb is a formerly-lightweight pastebin and url shortener
https://github.com/ptpb/pb
flask mongodb pastebin pastebin-service pb python
Last synced: about 14 hours ago
JSON representation
pb is a formerly-lightweight pastebin and url shortener
- Host: GitHub
- URL: https://github.com/ptpb/pb
- Owner: ptpb
- License: other
- Created: 2014-11-30T00:17:17.000Z (almost 10 years ago)
- Default Branch: master
- Last Pushed: 2024-10-31T11:15:34.000Z (3 days ago)
- Last Synced: 2024-10-31T12:22:18.250Z (3 days ago)
- Topics: flask, mongodb, pastebin, pastebin-service, pb, python
- Language: Python
- Homepage:
- Size: 312 KB
- Stars: 551
- Watchers: 13
- Forks: 52
- Open Issues: 26
-
Metadata Files:
- Readme: README.rst
- License: LICENSE
Awesome Lists containing this project
- starred-awesome - pb - pb is a lightweight pastebin and url shortener built using flask. (Python)
README
==
pb
==.. image:: https://img.shields.io/circleci/project/github/ptpb/pb.svg
:target: https://circleci.com/gh/ptpb/pb.. image:: https://img.shields.io/codecov/c/github/ptpb/pb.svg
:target: https://codecov.io/gh/ptpb/pb.. image:: https://img.shields.io/docker/automated/ptpb/pb.svg
:target: https://hub.docker.com/r/ptpb/pbOverview
--------``pb`` is a lightweight pastebin and url shortener built using
`flask `_.There is currently no known general-purpose public pb deployment. See `#246
`_ for details.Features
--------* full paste and short-url CRUD
* private pastes
* tweakable syntax highlighting
* terminal recording playback
* markup renderingSuggested versions
------------------- python >= 3.6
- mongodb >= 3.2
- docker >= 17.04Development
-----------pb comes with a ``Dockerfile`` and ``docker-compose.yaml`` to start development
environments easily. Refer to relevant documentation for how to install ``docker``
and ``docker-compose``.start pb with::
docker-compose up
pb will be listening on ``http://localhost:10002``
Deployment
----------ptpb.pw (the reference deployment) uses `ptpb-deploy
`_, which includes TLS termination,
automatic x509 certificate rotation, and response caching.For a simpler deployment, the included ``Dockerfile`` and
``docker-compose.yaml`` can be used verbatim, and are easy to read/study.Other best practices include:
- not using a shared/system python, when this is shared with packages other than pb
- using site-packages is fine/preferred inside a container or isolated
filesystem, otherwise use `venv
`_- if you need/want a version of python other than what your distribution
packages, `pyenv `_ is a good option- not using debian or centos
- these provide severely outdated packages, and require additional work to
compensate for this