docs: update readme

This commit is contained in:
2026-03-01 13:05:04 +01:00
parent 53dd416c17
commit cf492f9798

View File

@@ -13,11 +13,13 @@ A secure, self-hostable "burn after reading" paste service with ephemeral storag
## Architecture
- Gleam: Type-safe language built upon the BEAM
- Web: Wisp framework + Mist HTTP server
- Frontend: Lustre for HTML rendering
- Storage: In-memory only (no persistence)
- Security: AES-256-GCM client-side encryption, CSRF tokens, rate limiting, security headers
| Component | Description |
| ------------ | -------------------------------------------------------------------------------- |
| Backend/Core | Gleam (type-safe language built upon the BEAM) |
| Web | Wisp framework + Mist HTTP server |
| Frontend | Lustre for HTML rendering |
| Storage | In-memory only (no persistence) |
| Security | AES-256-GCM client-side encryption, CSRF tokens, rate limiting, security headers |
## Configuration
@@ -47,7 +49,9 @@ For development, you can use:
SECRET_KEY_BASE=dev gleam run
```
## Quick Start
## How to run
### Development
```bash
# Clone and build
@@ -58,22 +62,26 @@ gleam run
The server starts on `http://localhost:3000`.
## Docker image+deployment
Note: you can run tests with `gleam test`.
### Build
### Production
Production environment is meant to be run via Docker.
You can build the Docker image with:
```bash
docker build -t spasteg .
```
### Run
Then run the container with:
```bash
# Generate a secure key
docker run -p 3000:3000 -e SECRET_KEY_BASE=$(openssl rand -base64 48) spasteg
```
**With custom port:**
Or use a custom port:
```bash
docker run -p 8080:3000 -e SECRET_KEY_BASE=$(openssl rand -base64 48) -e PORT=3000 spasteg