https://github.com/emadda/durafetch
CLI to download your Cloudflare Durable Objects to a SQLite db.
https://github.com/emadda/durafetch
cloudflare cloudflare-worker cloudflare-workers sqlite
Last synced: 11 months ago
JSON representation
CLI to download your Cloudflare Durable Objects to a SQLite db.
- Host: GitHub
- URL: https://github.com/emadda/durafetch
- Owner: emadda
- License: mit
- Created: 2023-05-31T00:11:15.000Z (over 2 years ago)
- Default Branch: master
- Last Pushed: 2023-06-03T22:25:02.000Z (over 2 years ago)
- Last Synced: 2025-02-15T17:45:15.594Z (12 months ago)
- Topics: cloudflare, cloudflare-worker, cloudflare-workers, sqlite
- Language: TypeScript
- Homepage: https://madebyenzo.com/#durafetch
- Size: 28.3 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
# Durafetch
Durafetch is a CLI that downloads your Cloudflare Durable Object state to a local SQLite database.
See [durafetch-server](https://github.com/emadda/durafetch-server) for more details.
# Usage
Assuming you have added the server side component to your Cloudflare worker:
Install:
- `npm install --global durafetch`
Write to `config.json`:
```
{
"db_file": "./db.sqlite",
"servers": [
{
"ws_url": "wss://durafetch_worker-1.your-domain.com",
"auth_token": "secret_http_auth_bearer_token_replace_this_with_more_than_40_chars"
}
],
"poll": {
"every_ms": 1000
},
"concurrent_downloads": 50,
"logging": {
"ndjson": false
}
}
```
Run:
- `durafetch --config-file config.json`