How can I configure my TYPO3 website by using the new Site management module to match these tasks:
- domain.tld should be the base
- www.domain.tld should redirect to domain.tld
- SSL should be enforced as well
With earlier versions of TYPO3 i have achieved this by creating two domain records: one for domain.tld and the other for www.domain.tld, defined as permanent redirect to https://domain.tld. SSL was enforced by htaccess:
RewriteCond %{HTTPS}s ^on(s)| [NC]
RewriteRule ^(.*) http%1://domain.tld/? [R=301,L]
In the Site management module of TYPO3 v9 I defined 'https://domain.tld' as Entry point. This works fine so far, but requests for 'www.domain.tld' or 'http://domain.tld' are resulting in a redirect error. I have created the domain records for 'www.domain.tld' and 'domain.tld' as well. Meanwhile I have changed the entry point to '/', at least the requests for 'www.domain.tld' are working now. But what is the best practice to achieve the goals by using the Site management and Redirects modules?