Assistance Needed with HTTPS Redirection from S3 to Cloudflare R2 Bucket


I am currently working on redirecting an entire S3 bucket to a Cloudflare R2 bucket. On my website, the URLs are hard-coded, using the original URLs from S3.

I have successfully managed to implement the redirection, but it seems to be functional only with HTTP. Unfortunately, the URLs on my website are specified with HTTPS, and this is causing the redirection to fail.

Could you please advise me on how to configure the redirect to work with HTTPS? Your assistance with this matter would be greatly appreciated.

Thank you!

Best regards,