Page 1 of 1

Wildcard SubDomains Issue

Posted: Fri Jun 10, 2016 6:43 pm
by lotusming
I've search for a solution for this over and over to no avail. I added the DNS entries as mentioned here:
http://forum.vestacp.com/viewtopic.php? ... ard#p26681

whatever.domain.com works fine when I try to load the url. However, whatever.domain.com/folder/blahblah.php etc shows me a 404 error. Any ideas on how to fix this?

Re: Wildcard SubDomains Issue

Posted: Sat Jun 11, 2016 6:15 pm
by lotusming
Anyone?

Re: Wildcard SubDomains Issue

Posted: Tue Jun 14, 2016 1:48 pm
by lotusming
Anyone who came across the same issues. People seem to avoid answering issues on this properly. Here's how to add a wildcard domain properly so anything.domain.com works properly.

1. Go to Web->Edit->Aliases

Code: Select all

*.yourdomain.com
2. DNS -> Add Record->CNAME

Code: Select all

*.yourdomain.com
You could probably add the same value for an A entry under DNS too. Worked fine for me.

Re: Wildcard SubDomains Issue

Posted: Sun Sep 11, 2016 5:08 pm
by host79
can't add

Code: Select all

*.domain.com
Usage: apache2 {start|stop|graceful-stop|restart|reload|force-reload|start-htcacheclean|stop-htcacheclean}
* Restarting web server apache2
...fail!
* The apache2 configtest failed.
Output of config test was:
AH00526: Syntax error on line 103 of /home/admin/conf/web/apache2.conf:
The address or port is invalid
Action 'configtest' failed.
The Apache error log may have more information.

Re: Wildcard SubDomains Issue

Posted: Sun Sep 11, 2016 10:37 pm
by lotusming
I was using nginx so not sure for apache.

Re: Wildcard SubDomains Issue

Posted: Mon Sep 12, 2016 8:58 am
by tjebbeke
host79 wrote:can't add

Code: Select all

*.domain.com
Usage: apache2 {start|stop|graceful-stop|restart|reload|force-reload|start-htcacheclean|stop-htcacheclean}
* Restarting web server apache2
...fail!
* The apache2 configtest failed.
Output of config test was:
AH00526: Syntax error on line 103 of /home/admin/conf/web/apache2.conf:
The address or port is invalid
Action 'configtest' failed.
The Apache error log may have more information.
You can check the apache error log and the file /home/admin/conf/web/apache2.conf on line 103 to fix your problem.