I have loads of domains all pointing to my servers IP but because they are just holding domains I haven't configured them in WHM / Apache. Therefore they just get "can't display website" messages when visited.
Is it possible to set up rule (or whatever! (Virtual Host?)) that will point any domains not configured on my server (but pointed to it) to a generic holding page?
I was thinking I could use a VirtualHost like this:
<VirtualHost 123.123.123.123:80>
DocumentRoot /www/path/to/holding/account/
ServerName *
</VirtualHost>
Hope that makes sense! Thanks
Just omit the ServerName
directive.
From my /etc/apache2/sites-enabled/000-default
- note that only the DocumentRoot directive is needed:
<VirtualHost *:80>
DocumentRoot /var/www/default
ErrorLog ${APACHE_LOG_DIR}/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
I have loads of domains all pointing to my servers IP but because they are just holding domains I haven't configured them in WHM / Apache. Therefore they just get "can't display website" messages when visited.
Is it possible to set up rule (or whatever! (Virtual Host?)) that will point any domains not configured on my server (but pointed to it) to a generic holding page?
I was thinking I could use a VirtualHost like this:
<VirtualHost 123.123.123.123:80>
DocumentRoot /www/path/to/holding/account/
ServerName *
</VirtualHost>
Hope that makes sense! Thanks
Just omit the ServerName
directive.
From my /etc/apache2/sites-enabled/000-default
- note that only the DocumentRoot directive is needed:
<VirtualHost *:80>
DocumentRoot /var/www/default
ErrorLog ${APACHE_LOG_DIR}/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
0 commentaires:
Enregistrer un commentaire