• Introducing WebPros Cloud - a fully managed infrastructure platform purpose-built to simplify the deployment of WebPros products !  WebPros Cloud enables you to easily deliver WebPros solutions — without the complexity of managing the infrastructure.
    Join the pilot program today!
  • Support for BIND DNS has been removed from Plesk for Windows due to security and maintenance risks.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS.

redirection *.domain problem

isabelleR

New Pleskian
I have some subdomains configured in plesk, and everything is working just fine.

Now I need to redirect people that access to any other subdomain (except the ones configured in plesk) to a different default directory.

For example http://xxx.mydomain.com to /var/www/vhosts/mydomain.com/httpdocs/default.

Ive tried to create a wildcard, with the code listed bellow, but it only works if I paste it to the end of http.include, which is discarded after any other plesk change.

If I use the vhost.conf as suggested , I get errors, because the include line at http.include is inside the first and lead me to problems with the others subdomains.


<VirtualHost xxx:80>
ServerName mydomain.com:80
ServerAlias *.mydomain.com
DocumentRoot /var/www/vhosts/mydomain.com/httpdocs/default
CustomLog /var/www/vhosts/mydomain.com/statistics/logs/access_log plesklog
ErrorLog /var/www/vhosts/mydomain.com/statistics/logs/error_log
</VirtualHost>
Is there any other way to do this ? Am I doing something wrong ?
 
Back
Top