Share files using Cloudflare Workers and GitHub Private Repositories!
- Clone this repository
- Create a new GitHub Personal Access Token with the
reposcope - Create a private repository to store your files
- Make sure you have
npmandwranglerinstalled and configured - Create a new D1 Database by running
wrangler d1 create file-share-data - Update file
wrangler.toml:
name = "file-share"
main = "Source/index.ts"
compatibility_date = "2023-10-02"
[[d1_databases]]
binding = "FileShareBufferDatabase"
database_name = "file-share-data"
database_id = "..." // The ID of the database you created, output in step 5- Run
npm installto install dependencies - Run
wrangler deployto publish your project - Run
wrangler secret put GithubPAT,wrangler secret put GithubOwnerandwrangler secret put GithubRepoto store your GitHub Personal Access Token, GitHub Owner and GitHub Repository - Your file share is now live! 🎉
This project is licensed under the terms of the GNU General Public License v3.0.