mirror of
https://github.com/besoeasy/file-drop.git
synced 2026-01-27 13:48:50 -06:00
b05655227a3fb823a28058f20d42f1200fa84679
File Drop
Private, decentralized file sharing for Nostr and the web.
One all-in-one storage backend you can drop into anything: your own apps, screenshot tools, pastebin-style pastes, Nostr clients, Reddit posts, forum embeds—anything that needs durable, anonymous file hosting. One File Drop to rule them all and keep you anonymous.
Why File Drop
- Anonymous uploads: no accounts, no tracking, no logs
- Resilient by design: served from IPFS; your node needn’t be online 24/7
- Nostr-optimized: you are your own media host (no domain or servers)
- Self-healing: content repopulates across IPFS when your node comes online
Supported Platforms
FileDrop is integrated into the following platforms:
| Platform | Description | Link |
|---|---|---|
| 0xchat | Private, decentralized Nostr chat | 0xchat.com |
Quick Start
docker run -d --restart unless-stopped \
-p 3232:3232 \
-p 4001:4001/tcp \
-p 4001:4001/udp \
-v file-drop-data:/data \
-e STORAGE_MAX=200GB \
-e FILE_LIMIT=5GB \
-e REMOTE_FILE_LIMIT=250MB \
-e NPUB=npub1yourkey1...,npub2yourkey2...,npub3yourkey3... \
--stop-timeout 15 \
--name file-drop \
ghcr.io/besoeasy/file-drop:main
Docker Compose:
services:
file-drop:
image: ghcr.io/besoeasy/file-drop:main
container_name: file-drop
restart: unless-stopped
stop_grace_period: 15s
ports:
- "3232:3232"
- "4001:4001/tcp"
- "4001:4001/udp"
volumes:
- file-drop-data:/data
environment:
- STORAGE_MAX=200GB
- FILE_LIMIT=5GB
- REMOTE_FILE_LIMIT=250MB
- NPUB=npub1yourkey1...,npub2yourkey2...,npub3yourkey3...
volumes:
file-drop-data:
Open http://localhost:3232 after starting.
Configuration
STORAGE_MAX(default: 200GB) – IPFS storage cap before GCFILE_LIMIT(default: 5GB) – Max size per file uploadREMOTE_FILE_LIMIT(default: 250MB) – Max size for remote URL uploadsNPUB– Comma-separated list of Nostr pubkeys (npub or hex) to enable Nostr mode. Example:npub1abc...,npub2def...,npub3ghi...
Persist your IPFS repo by mounting /data (recommended).
How It Works
- Upload – Files stream to your local IPFS node (unpinned)
- Propagate – Content spreads via IPFS as peers request it
- Repopulate – If garbage collected, your node repopulates content when it comes online
- Optional Nostr mode – Automatically fetches your notes, extracts IPFS CIDs, and pins them
Nostr Mode (Optional)
- Supports multiple NPUBs (comma-separated)
- Fetches all posts from each configured NPUB (with pagination) and filters out expired notes
- Extracts IPFS CIDs and pins them locally (permanent)
- Caches media from people you follow for redundancy (ephemeral, garbage collected)
- Runs automatically every 3 hours; view status in the admin
API Endpoints
File Upload
Upload a file directly from your local system:
curl -X POST -F "file=@yourfile.pdf" http://localhost:3232/upload
Response:
{
"status": "success",
"cid": "QmX...",
"url": "https://dweb.link/ipfs/QmX...?filename=yourfile.pdf",
"size": 12345,
"type": "application/pdf",
"filename": "yourfile.pdf"
}
Remote URL Upload
Download and upload content from any URL to IPFS:
curl -X POST http://localhost:3232/remoteupload \
-H "Content-Type: application/json" \
-d '{"url":"https://example.com/image.png"}'
Response:
{
"status": "success",
"cid": "QmX...",
"url": "https://dweb.link/ipfs/QmX...",
"filename": "image.png",
"size": 12345,
"type": "image/png",
"sourceUrl": "https://example.com/image.png",
"timing": {
"download_ms": 1234,
"upload_ms": 5678,
"total_ms": 6912
},
"timestamp": "2026-01-07T03:18:00.000Z"
}
Features:
- Supports any HTTP/HTTPS URL
- Streams content efficiently (doesn't load entire file into memory)
- Enforces size limit (default 250 MB, configurable via
REMOTE_FILE_LIMIT) - Automatic MIME type detection
- Returns detailed timing information
Dashboard
- Dashboard: /dashboard.html
- Web UI: /
Description
A decentralized, open-source solution for sharing images, videos, and any other files.
⚠️ ARCHIVED: Original GitHub repository no longer exists. Preserved as backup on 2026-01-28T03:45:30.846Z
Languages
JavaScript
52.5%
HTML
46.3%
Dockerfile
1.2%