In Apache webserver, you can set virtual server configuration to allow several domains to access the same concrete5 installation on your server. This guide assumes you are under Debian Linux regarding the folder structure but the Apache configuration will work in any Apache installation, although the configuration files might be stored in different locations.
Assuming you have concrete5 installed in /home/user/public_html/, this is how you setup a virtual server to map multiple domains into that folder (and concrete5 installation):
The virtual server configuration you need to put into the Apache configuration file is something like this (just an example, your actual configuration may differ):
<VirtualHost *:80> ServerName yourdomain.com # *.yourdomain.com for all the sub-domains # separate additional addresses with space ServerAlias *.yourdomain.com www.other-domain.com www.third-domain.com ServerAdmin [email protected] # The root directory of your concrete5 installation DocumentRoot /home/user/public_html/ </VirtualHost>
If you need to map all the sub-domains for your domain, this is the correct DNS setup to do so:
yourdomain.com. IN A 18.104.22.168 *.yourdomain.com. IN CNAME yourdomain.com.
If you don't have straight access to modify the DNS configuration files on your name server and need to do this through a GUI, you can probably set the wildcard just by adding a CNAME record for *.yourdomain.com that will point to the main domain that you've already setup properly. This is supported by many of the DNS service providers but we cannot guarantee it will work with every service provider.