Disabling CDN & S3, returning to local storage for images - best practice?

I have a small Discourse forum that’s set up with Backblaze B2 as an object store and BunnyCDN as the CDN, but want to move all that back to the local storage of the Discourse server as traffic is so low it’s not worth the current complexity and cost of the separate CDN & object storage.

Is there a best practice or documentation around reverting back to local storage after using a CDN? I found this post on the forum:

Is that all there is to it?

Run rake uploads:migrate_from_s3, disable S3/CDN in the site settings, then run rake posts:rebake to fix all the post URLs?

Replying to my own answer - but rake uploads:migrate_from_s3 doesn’t appear to be an option available.

Running rake --tasks and there’s no tasks with S3 listed.

I am running Discourse v3.4.2.

To answer this, it looks like it was removed a few years ago: FIX: remove migrate_from_s3 task that silently corrupts data by johnsonm · Pull Request #11703 · discourse/discourse · GitHub (related topic: Migrate_from_s3 problems)

1 Like

I think you want to Enable hidden setting to include S3 uploads in the backups and the restore to a new site that doesn’t have S3 configured.

That’s what cdck does when someone leaves their hosting and it works just fine.

4 Likes

Ahh, I understand. Will give this a shot.

2 Likes