Skip to main content

What if we change media storage later?

UPDATE: Heard back from Fluent Support on this. And what they say about the sub domain is true, I tested that.

"According to the current architecture, if you decide to move away from Cloudflare, the links will remain intact as long as you don't delete Cloudflare R2. Unfortunately, there's no option to download the images back to the server or rewrite the links using Fluent Community.

Additionally, I'm sorry to inform you that there's no way to adjust the image compression. We automatically resize and convert all uploaded images to WebP format, which helps reduce file size and enhance performance."

What I don't like is the inability to change image quality. We need that option. But not a complaint. I freaking love this new community.

--

Have Cloudflare R2 setup and it's working great.

But worried about what happens if I were to move away from Cloudflare β€” All of my community images would be gone.

Basically I'm turning my self-maintained community into a community 100% dependent on a 3rd party.

Will there be a way within Fluent to migrate images back? If there won't be, I might need to either store them like normal, or do something like WP Offload Media as that has an option to download them back. Would rather not do that route thought.

Ramsis Kasis

good question

Mat β€Ž

kyler boudreauΒ if you currently use R2 with your custom subdomain (cdn.yourDomain.com not subdomain.r2.dev) and you move your files to any other CDN with the same url structure (same subdomain) it shouldnt be any issue - you just reconfigure your subdomain IP to the new CDN.

However if you want bring your images back to wordpress then you need to copy them manually and rewrite all images links in WP DB manually with SQL query.

Maybe we could have a setting allowing us to specify the base domain for images and if the domain of url was changed then it will be automatically rewritten in our DB to the new place example: WP standard fCommunity folder for images.

kyler boudreau

Mat β€ŽΒ good point. I just tested what you said and yeah, all images are good as the sub domain link is pointing to them. But a rewrite option would be nice for sure.

Vibe Code

same question but for S3 - can S3 be on subdomain too?

Mat β€Ž

@hello_1732691548Β you can create a bucket with your subdomain.domain.com shouldn't be a problem. The only challenge you might have is with the SSL ($3 doesn't support the capability natively) - you will need a CloudFront config AFAIK

Vibe Code

Mat β€ŽΒ yup, all works fine

Daniel Iser

The real problem with converting everything to Webp is that means its impossible to upload your own animated gifs! 😒

Daniel Iser

It can be disableable at least, here is how to fix animated gifs

add_filter( 'fluent_community/convert_image_to_webp', 'no_fluentcomm_optimize_gif', 10, 2 );

function no_fluentcomm_optimize_gif( $willConvert, $file) {
    $ext = pathinfo($file['url'], PATHINFO_EXTENSION);
    if ( 'gif' === $ext ) {
        return false;
    }

    return $willConvert;
}

kyler boudreau

Daniel IserΒ whoa! I need this for all images. How can we disable the webp stuff? It's ruining my images.

Admin j

What do you guys recommend for media storage?

kyler boudreau

Cloudflare worked great for me. It's the webp conversion that's driving me crazy. But that's Fluent not Cloudflare.

Admin j

kyler boudreauΒ Thanks! For the moment I am self hosting the media, but what would happen to these media that is being uploaded in case I change to Cloudflare? Would it get lost?

kyler boudreau

Admin jΒ no, here's what happes: If you switched over to Cloudflare, NEW images would go there. Old ones would stay on your server. You can tell by looking at the URLs of the images. Fluent Community is not taking all of your current media and uploading it. And if you turn off Cloudflare in the community settings, the Cloudflare URLs stay the same. So if you changed your mind and went back to server, but kept the Cloudflare bucket active, nothing breaks. New images would on the server, old images would reference the Cloudflare URL.

Admin j

kyler boudreauΒ Thanks a lot for your help!!