Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/lamehost/pastrami
Text paste web service
https://github.com/lamehost/pastrami
pastebin
Last synced: 17 days ago
JSON representation
Text paste web service
- Host: GitHub
- URL: https://github.com/lamehost/pastrami
- Owner: lamehost
- License: mit
- Created: 2019-01-26T10:09:35.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2024-07-08T06:38:34.000Z (5 months ago)
- Last Synced: 2024-08-08T18:21:55.074Z (4 months ago)
- Topics: pastebin
- Language: Python
- Homepage: https://p.lamehost.it
- Size: 488 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-starred - lamehost/pastrami - Pastebin web service (others)
README
# Pastrami
Pastrami is a lightweight solution for securely storing encrypted text. It is designed to provide a quick and efficient way to store sensitive information, ensuring that each piece of data is encrypted using its own unique item ID as the encryption key.# Features
- **Memory-Only database**: Pastrami can operate entirely in memory, offering fast access and retrieval of encrypted text without persisting data to disk.
- **Item ID Encryption**: Each piece of text is encrypted using its corresponding item ID. This ensures that the encryption key is unique to each stored item, enhancing the security of your sensitive data.
- **Simple and Lightweight**: The service is designed to be easy to use and does not impose unnecessary complexity. Integration with your applications or systems is straightforward.# Getting started
To use the Pastrami web service, follow these steps:
```
git clone https://github.com/lamehost/pastrami.git
cd pastrami
poetry install
```
After Pastrami is installed, you can launch it as follows:
```
cp pastrami.conf.sample pastrami.conf
poetry run pastrami
```## CLI arguments
By default Pastrami binds to port 8080 on localhost. Settings can be changed via CLI:
```
$ poetry run pastrami -h
usage: pastrami [-h] [-d] [HOST] [PORT]A lightweight solution for securely storing encrypted text.
positional arguments:
HOST Host to bind to. Default: 127.0.0.1
PORT Port to bind to. Default: 8080options:
-h, --help show this help message and exit
-d, --debug Turns uviconr debugging onConfiguration file name is hardcoded: pastrami.conf
```## Docker
To use pastrami with Docker or Podman, follow these steps:
```
podman build -t pastrami:latest .
cp pastrami.conf.sample pastrami.conf
podman run -it --rm -p 8080:8080 -v $(pwd)/pastrami.conf:/tmp/pastrami.conf pastrami -d
```# Usage
Access web frontend at http://localhost:8080. Write text and hit ctrl+s to save.## API endpoints
You can use API endpoints to save and retrieve text. If *pastrami_docs* is set to true in *pastrami.conf*, then swagger is available at http://localhost:8080/docs/.## Formatting options:
By default Text content is formated as HTML page and colorized with *Google Code Prettify* stylesheet. Other formatting options can be returned by attaching an extension at the end of the URL:
- **No extension**: Google Code Prettify (default)
- **.txt**: Regular text file
- **.md**: Content is interpreted as Markdown and rendered as HTML