diff options
| author | Your Name <you@example.com> | 2026-05-26 16:11:05 +0530 |
|---|---|---|
| committer | Your Name <you@example.com> | 2026-05-26 16:11:05 +0530 |
| commit | 8816a192c95cf539b65975469a2d61aed46f0414 (patch) | |
| tree | 7590318244a56fabbfa6919ef6d0fab5be529134 /Cargo.toml | |
feat: initial implementation of grasp-mirror daemon
GRASP mirror daemon that discovers repos from watched npubs and mirrors
git data + Nostr events across all known GRASP servers for redundancy.
Features:
- Configurable npub watch list via .env (MIRROR_NPUBS)
- TOML config for GRASP server list, index relays, storage paths
- NIP-11 verification of GRASP servers on startup
- Discovery of repos via kind:30617 announcements on index relays
- Git mirroring (bare clone + push --mirror) to missing GRASP servers
- Nostr event forwarding to all GRASP server embedded relays
- SQLite state tracking for sync status and event dedup
- Optional signing key for updating announcements with new clone URLs
- CLI subcommands: daemon, status, verify, mirror-once
Architecture:
config.rs - TOML + .env config loading
db.rs - SQLite state tracking
health.rs - NIP-11 GRASP server verification
discovery.rs - Relay subscription, kind:30617 parsing
git_mirror.rs - Bare clone + push to GRASP servers
nostr_mirror.rs - Event forwarding to all GRASP relays
signing.rs - Optional announcement updates
main.rs - CLI entry point, daemon loop
Diffstat (limited to 'Cargo.toml')
| -rw-r--r-- | Cargo.toml | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/Cargo.toml b/Cargo.toml new file mode 100644 index 0000000..a093dbb --- /dev/null +++ b/Cargo.toml | |||
| @@ -0,0 +1,24 @@ | |||
| 1 | [package] | ||
| 2 | name = "grasp-mirror" | ||
| 3 | version = "0.1.0" | ||
| 4 | edition = "2021" | ||
| 5 | description = "GRASP mirror daemon — mirrors git data and Nostr events across GRASP servers" | ||
| 6 | license = "MIT" | ||
| 7 | |||
| 8 | [dependencies] | ||
| 9 | nostr-sdk = "0.39" | ||
| 10 | nostr = "0.39" | ||
| 11 | tokio = { version = "1", features = ["full"] } | ||
| 12 | sqlx = { version = "0.8", features = ["runtime-tokio", "sqlite"] } | ||
| 13 | toml = "0.8" | ||
| 14 | serde = { version = "1", features = ["derive"] } | ||
| 15 | serde_json = "1" | ||
| 16 | tracing = "0.1" | ||
| 17 | tracing-subscriber = { version = "0.3", features = ["env-filter", "json"] } | ||
| 18 | reqwest = { version = "0.12", features = ["json"] } | ||
| 19 | dotenvy = "0.15" | ||
| 20 | anyhow = "1" | ||
| 21 | git2 = "0.20" | ||
| 22 | hex = "0.4" | ||
| 23 | clap = { version = "4", features = ["derive", "env"] } | ||
| 24 | dirs = "6" | ||