I have the Drupal 8 site was working with HTTP on the port 80. I switched it to HTTPS with port 443. I got the problem for ERR_TOO_MANY_REDIRECTS when accessing some images from physicals path.
For example path: https://www.example.com/theme/sites/basic/img/fileimage.png
It happened on some files which are display on the pages. I tried access other files on the same level folder "img" is working. (i.e img/logo.png)
I guess it's cache problem. Here what I did: - Clear cache - Drush cr - Deleted some special table within cache_ inside. - I stop mysqld, it's still happened.
Here is my .htaccess:
# ensure www.
RewriteCond %{HTTP_HOST} !^www\. [NC]
RewriteRule ^ https://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
# ensure https
RewriteCond %{HTTP:X-Forwarded-Proto} !https
RewriteCond %{HTTPS} off
RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
From my admin/config/Basic Site Setting. I still saw
Default front page: http://www.example.com
It should be https? How I can resolve it? Thanks