Enigma
Here are details.
As suggested aaPanel, after initial install aaPanel to change everything on setting. Previously I changed default site dir www/wwwroot to www/otherfoldername
I'm using nginx 1.17.10, php 7.4, Positive SSL, Forced Https ON, DNZ Zone A record www pointing to ip address, CNAME www pointing to domain.tld.
After checked. When user entry domain 2 in browser have various result:
- domain2.tld >> Secure. Auto forward to https://domain2.tld
- www.domain2.tld >> Not secure - 403 Forbidden. Not auto forward to https
- http://domain2.tld >> Secure auto forward to https://domain2.tld
- http://www.domain2.tld >> Not secure - 403 Forbidden. Not auto forward to https
- https://domain2.tld >> Secure
- https://www.domain2.tld >> Not secure. invalid/wrong certificate or domain1.tld certificate
When checked domain 1 in browser, everything is OK and autoforward to https except when user entry http://www.domain1.tld have result 403 Forbidden and not auto forward to https.
Other subdomain host.domain.tld with let's encript is OK and autoforward to https
So I have 3 problems.
- Wrong SSL on domain2.tld
- Not auto forward to https on both domain1.tld and domain2.tld
- Not secure - 403 Forbidden on both domain1.tld and domain2.tld
What's wrong?
I hope when user entry domain.tld or www.domain.tld by http or https, browser will display secure page and auto forward to https. Thanks.