A minimal AT Protocol Personal Data Server written in JavaScript.
at main 37 lines 1.0 kB view raw view rendered
1# Deno PDS Example 2 3Minimal PDS server running on Deno. 4 5## Requirements 6 7- Deno 2.2+ (for `node:sqlite` support) 8 9## Quick Start 10 11```bash 12cd examples/deno 13deno run --allow-net --allow-read --allow-write --allow-env main.ts 14``` 15 16## Environment Variables 17 18| Variable | Description | Default | 19|----------|-------------|---------| 20| `PDS_DB_PATH` | SQLite database path | `./pds.db` | 21| `PDS_BLOBS_DIR` | Blob storage directory | `./blobs` | 22| `JWT_SECRET` | JWT signing secret | `development-secret` | 23| `PORT` | Server port | `3000` | 24| `HOSTNAME` | PDS hostname | - | 25| `APPVIEW_URL` | AppView URL for proxying | - | 26| `APPVIEW_DID` | AppView DID for service auth | - | 27| `RELAY_URL` | Relay URL for firehose | - | 28| `PDS_PASSWORD` | Password for createSession | - | 29 30## Permissions 31 32The server requires these Deno permissions: 33 34- `--allow-net` - HTTP server and outbound requests 35- `--allow-read` - Read database and blob files 36- `--allow-write` - Write database and blob files 37- `--allow-env` - Read environment variables