I Cannot succeed to force an https connection to a sub-domain with Cloudflare


#1

Hello. My name used to be michelangelo on the old site. On the new site, it was no longer available, so I picked michel_angelo to minimise confusion.

My main site, hosted on Dreamhost, is located at “abeille-cyclotourisme.fr”.

I have not succeeded to force an https connection on it.

For testing purpose, I have created the sub-domain “test-2030.—”, I have requested a LetsEncrypt certificate for HTTPS connections and distribution via Cloudflare (free plan).

To avoid the “too many redirections” error, I have:

On the http main CP, selected, for www: “leave it alone” (no redirection)
on the HTTPS CP, I have selected for www, “copy non-secure settings”
On the .htaccess file, I have only requested a redirection to the secure version, as follows:

RewriteEngine On

RewriteCond %{HTTPS} !=on

RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

The site’s files on this test subdomain are brand new, so I assume the redirections cannot come from anything written on them.

Nevertheless, any connection attempts, whether at the http://test-2030.— address or at the
https://test-2030.— address fail with the message: “err_too_many_redirects”

If I remove the htaccess file, it works, but without redirection.

I have done all possible tests with different settings than the above, no success so far.

What am I doing wrong ? TIA


#3

Hello, il just works, right away (including for subdomains) !!! Cheers to you.


#5

I’m not able to handle this trouble with my blog site (Assist Login)


#6

Best android and ios application
Tutuapp


#7

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.