Subserver Wildcard SSL redirect to main domain

Operating system: Debian Linux 8

Webmin version: 1.831

Virtualmin version: 5.05

Kernel and CPU Linux 3.16.0-4-amd64 on x86_64

Hi, i have a problem. My server mydomain.com have many subservers, edu.mydomain.com, info.mydomain…
I bought Wildcart SSL cert, imported it to mydomain.com, under manage SSL certificate I see:
Web server hostname *.mydomain.com Issuer name COMODO RSA Domain Validation Secure Server CA
Issuer organization COMODO CA Limited Expiry date Sep 21 23:59:59 2019 GMT
Certificate type Signed by CA
Other domain names *.mydomain.com | mydomain.com
Also used by domains edu.mydomain.com
info.mydomain.com

All seems ok. BUT, when I trying access https://edu.mydomain.com or https://info.mydomain.com, it automatically redirects to https://mydomai.com

SSL website enabled? checked

In Server configuration- > Webiste options -> Website matches all sub-domains? -> No

Any ideas?

Hello dequi,

Have you created your sub-domains as alias or as a true sub-domain ( individual path under /home/mydomain/domains/edu.mydomain.com/public_html ) ?

as a true subdomain.

And path is /home/mydomain/domains/edu.mydomain.com/public_html as you say

I have similar issues. any subdomain setup has its own path it works ok as http://sub.domain.com but soon as I try https://sub.domain.com it shows the contents from the main domain. I checked the vhost settings for the 443 port a thousand times and nothing weird shows.

certificate used is a letsencrypt cert. having domain.com, www.domain.com, sub.domain.com.

setting up a true sub2.domain.com with a self signed cert shows the same behaviour.

the domain.com is NOT the default on the server. Checking for redirects did not reveal any odd stuff.

I am still stuck on this.

domain.com has letsencrypt setup.
sub.domain.com also has its letsecnrypt setup. Pointing to another path.
as wildcard does is not allowed with letsencrypt sub has its own.

Weird thing now is that when accessing https://sub.domain.com it shows the content of domain.com, whereas without https:// it is ok.
Settings in virtualmin for both SSL and non SSL site point to same path. So same content is expected.

Even when I change sub.domain.com path for the SSL site to whatever other path, contents of domain.com keep showing.

On this same machine I do have a (comodo) wildcard certificate setup for another domain and its subdomains… this works like a charm…

Is this caused by letsencrypt way of handling things?