Skip to content

Conversation

@vicb
Copy link
Contributor

@vicb vicb commented Nov 17, 2025

Use wrangler r2 bulk put instead of relying on rclone

The DX with rclone is not great:

  • need to create S3 tokens and provide them as environment variables
  • does not work well across all OSes (see pending issues)
  • does not work in local dev - albeit R2 population is as slow as with remote objects

wrangler r2 bulk put is instant in local dev and fast for remote buckets (not as fast as rclone).

The e2e for e2e/app-router lasts 5min before this PR and <50s after.

TODO:

@changeset-bot
Copy link

changeset-bot bot commented Nov 17, 2025

🦋 Changeset detected

Latest commit: ba11c46

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@opennextjs/cloudflare Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@pkg-pr-new
Copy link

pkg-pr-new bot commented Nov 17, 2025

Open in StackBlitz

npm i https://pkg.pr.new/@opennextjs/cloudflare@991

commit: ba11c46

@vicb vicb mentioned this pull request Nov 17, 2025
Copy link
Contributor

@dario-piotrowicz dario-piotrowicz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow! this looks like a great UX improvement! 🫶

I think that https://opennext.js.org/cloudflare/cli#populatecache-command also needs updating?

@vicb
Copy link
Contributor Author

vicb commented Nov 18, 2025

Wow! this looks like a great UX improvement! 🫶

I think that https://opennext.js.org/cloudflare/cli#populatecache-command also needs updating?

Thanks for the review and the reminder on the docs. I'll update the docs right after the release.

@vicb vicb merged commit b95e7ca into main Nov 18, 2025
7 checks passed
@vicb vicb deleted the vicb/r2-bulk-put branch November 18, 2025 15:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants