Hi all,
Is it possible to disable the "feature" within Apache that it displays the first VirtualHost when visiting a domain that is still pointing to the IP but not setup as an account?
It previously used to redirect to http://requested-domain.tld/cgi-sys/defaultwebpage.cgi but now it's loading the first VirtualHost without changing the URL.
This could potentially cause issues with indexing and duplicate content, so we're keen to prevent it on our servers.
I've had a look at the domain forwarding functionality but it's flagging that we don't have any IP's, despite there being one or more setup with multiple accounts attached.
I have also tried adding a VirtualHost entry (the commented out sections are various attempts):
to the following files:
/etc/apache2/conf.d/includes/pre_virtualhost_2.conf
/etc/apache2/conf.d/000-default.conf
Is it possible to disable the "feature" within Apache that it displays the first VirtualHost when visiting a domain that is still pointing to the IP but not setup as an account?
It previously used to redirect to http://requested-domain.tld/cgi-sys/defaultwebpage.cgi but now it's loading the first VirtualHost without changing the URL.
This could potentially cause issues with indexing and duplicate content, so we're keen to prevent it on our servers.
I've had a look at the domain forwarding functionality but it's flagging that we don't have any IP's, despite there being one or more setup with multiple accounts attached.
I have also tried adding a VirtualHost entry (the commented out sections are various attempts):
Code:
<VirtualHost *>
ServerName subdomain.server-domain.tld
RedirectPermanent / /cgi-sys/defaultwebpage.cgi
#RewriteEngine on
#RewriteCond %{HTTPS} on
#RewriteRule (.*) http://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
#RewriteCond %{HTTPS} off
#RewriteRule ^/(.*)$ /cgi-sys/defaultwebpage.cgi [L,R=302]
</VirtualHost>
/etc/apache2/conf.d/includes/pre_virtualhost_2.conf
/etc/apache2/conf.d/000-default.conf
Last edited by a moderator: