Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Multiple Domains to One Virtual Host | Wildcard Host (shared hosting)?

I have the following task: Create one website which is accessible with 20 different domains names.

Same files, same folder, same ip.

Question (shared hosting): Can this be accomplish with a bare cname's pointing to the same common subdomain or do we need one static ip for all?

The problem is sure shared hosting and I'm trying to avoid creating manually "cpanel addon domains" one by one. Shared hosting doesn't allow to modify httpd conf which allows me to create a wildcard virtual host for an IP.

I guess my question is auto answered; I'll need a static unless I'm only using subdomain's w wildcard, which works on shared hosting. "*.domain.com", "two.domain.com", "three.domain.com" => directory/

like image 704
Codex73 Avatar asked Dec 31 '22 04:12

Codex73


1 Answers

I think you have answered your own question, the options open to you are

  • Add ServerAlias entries to the vhost config, via whatever means available to you
  • Ensure the default virtual host on the target IP is the one which handles your site
like image 99
Paul Dixon Avatar answered Jan 06 '23 02:01

Paul Dixon