Publish faster with an edge-native blog powered by Cloudflare Workers, D1, and R2
Publish faster with an edge-native blog powered by Cloudflare Workers, D1, and R2
English | 简体中文
Rin is a modern, serverless blog platform built entirely on Cloudflare's developer platform: Pages for hosting, Workers for serverless functions, D1 for SQLite database, and R2 for object storage. Deploy your personal blog with just a domain name pointed to Cloudflare—no server management required.
https://yourblog.com/about using custom article aliases.#Blog #Cloudflare and have them automatically parsed and displayed.@rin/api package.# 1. Clone the repository
git clone https://github.com/openRin/Rin.git && cd Rin
# 2. Install dependencies
bun install
# 3. Configure environment variables
cp .env.example .env.local
# Edit .env.local with your own configuration
# 4. Start the development server
bun run devVisit http://localhost:5173 to start hacking!
Run the test suite to ensure everything works:
# Run all tests (client + server)
bun run test
# Run client tests only
bun run test:client
# Run server tests only
bun run test:server
# Run tests with coverage
bun run test:coverageDeploy both frontend and backend to Cloudflare with a single command:
# Deploy everything (frontend + backend)
bun run deploy
# Deploy only backend
bun run deploy:server
# Deploy only frontend
bun run deploy:clientRequired environment variables:
CLOUDFLARE_API_TOKEN - Your Cloudflare API tokenCLOUDFLARE_ACCOUNT_ID - Your Cloudflare account IDOptional environment variables:
WORKER_NAME - Backend worker name (default: rin-server)PAGES_NAME - Frontend pages name (default: rin-client)DB_NAME - D1 database name (default: rin)R2_BUCKET_NAME - R2 bucket name. If set, deploy derives the matching S3_* values automatically. If unset, no bucket is auto-selected.The deployment script will automatically:
S3_* storage settings from R2_BUCKET_NAME only when it is explicitly setThe repository includes several automated workflows:
ci.yml - Runs type checking and formatting validation on every push/PRtest.yml - Runs comprehensive tests (server + client) with coverage reportingbuild.yml - Builds the project and triggers deploymentdeploy.yml - Deploys to Cloudflare Pages and WorkersRequired secrets (Repository Settings → Secrets and variables → Actions):
CLOUDFLARE_API_TOKEN - Your Cloudflare API token with Workers and Pages permissionsCLOUDFLARE_ACCOUNT_ID - Your Cloudflare account IDOptional configuration (Repository Settings → Secrets and variables → Variables):
WORKER_NAME, PAGES_NAME, DB_NAME - Resource namesNAME, DESCRIPTION, AVATAR - Site configurationR2_BUCKET_NAME - Specific R2 bucket to useFull documentation is available at https://docs.openrin.org.
We welcome contributions of all kinds—code, documentation, design, and ideas. Please check out our contributing guidelines and join us in building Rin together!
…No open issues yet, or sync has not completed.