What you need before you start

A Cloudflare account with R2 turned on and a GitHub account. Workers Free is enough.

What you need

You need

Why

A Cloudflare account

Each site runs there as a Worker, with a database, file storage and a key-value store.

R2 turned on in that account

Each site keeps its media in an R2 bucket.

A GitHub account

Each site has a repository, and its build runs there in GitHub Actions.

An email address, a passkey, or a GitHub or Google account

To sign in to Fleet. Fleet has no password.

The Cloudflare and GitHub accounts can be yours or an End User's. For an End User's account, send a one-time link. See End User grants.

Cloudflare Workers Free is enough

Fleet accepts a Cloudflare account on Workers Free and never blocks a step because of the plan. It shows the Free limits where a Cloudflare connection is created: when you connect an account, when you ask an owner for access, and on the page an End User opens to grant it.

Workers Free: up to 5 sites and 100,000 requests a day. Workers Paid (USD 5 per month, billed by Cloudflare to the account owner) raises these limits.

Workers Free also allows 10 ms of CPU per invocation and a database of up to 500 MB. It keeps restore points for 7 days and logs for 3 days, and holds at most 100 Workers and 5 Cron Triggers in the account. Every site Worker carries one Cron Trigger, so a Free account holds at most 5 sites. The full tables are in Limits, and Workers Free and Workers Paid explains what changes between the plans. Cloudflare publishes its own Workers limits.

The checkbox

When you connect a Cloudflare account, select This account is on Workers Paid if it is. Fleet reads the plan from Cloudflare when it can, and follows the checkbox when it cannot. The checkbox never blocks anything.

  • If the read contradicts a selected checkbox, Fleet shows "Cloudflare reports this account is on Workers Free" and carries on.
  • If Fleet cannot read the plan, it shows "Fleet cannot see this account's plan. Select the checkbox if the account is on Workers Paid." next to the checkbox.

R2 must be turned on

Fleet creates an R2 bucket for every new site, so R2 must be on first. If it is not, Cloudflare refuses the request with error code 10042, provisioning stops, and Fleet shows this message with a link to the R2 page of the Cloudflare dashboard and a Retry button:

R2 file storage is not turned on for this Cloudflare account. Turn it on in the Cloudflare dashboard, then select Retry.

Turn R2 on, then select Retry. Cloudflare lists its codes in R2 error codes.

GitHub and its allowance

Each site builds with GitHub Actions in its own repository, within the repository owner's allowance. GitHub Free gives the repository owner USD 12 of usage a month and 500 MB of artifact storage. GitHub charges the owner for more, and blocks usage once the included amount is used up when no payment method is on file. A build that GitHub refuses ends as failed: see The build failed or did not finish. GitHub lists the allowance in What is included in each plan.

What an existing site needs

To link a site that already runs, Fleet needs a Worker in the connected Cloudflare account with a D1 database bound as DB. A GitHub repository you add must depend on emdash. To create a site from an existing repository, it must be an EmDash Cloudflare project: its package.json depends on emdash and @emdash-cms/cloudflare, and astro.config.mjs exists. See Create or link a site.

Related

Report a problem with this page