~ knotless Search/
↑↓ move↵ open⇧↵ all results

chadtmiller.com/pds.js

An atproto PDS in JavaScript, for Cloudflare Workers and Node

0
0
main
37 lines · 1.0 KB Raw History
# Deno PDS Example

Minimal PDS server running on Deno.

## Requirements

- Deno 2.2+ (for `node:sqlite` support)

## Quick Start

```bash
cd examples/deno
deno run --allow-net --allow-read --allow-write --allow-env main.ts
```

## Environment Variables

| Variable | Description | Default |
|----------|-------------|---------|
| `PDS_DB_PATH` | SQLite database path | `./pds.db` |
| `PDS_BLOBS_DIR` | Blob storage directory | `./blobs` |
| `JWT_SECRET` | JWT signing secret | `development-secret` |
| `PORT` | Server port | `3000` |
| `HOSTNAME` | PDS hostname | - |
| `APPVIEW_URL` | AppView URL for proxying | - |
| `APPVIEW_DID` | AppView DID for service auth | - |
| `RELAY_URL` | Relay URL for firehose | - |
| `PDS_PASSWORD` | Password for createSession | - |

## Permissions

The server requires these Deno permissions:

- `--allow-net` - HTTP server and outbound requests
- `--allow-read` - Read database and blob files
- `--allow-write` - Write database and blob files
- `--allow-env` - Read environment variables