Report this

What is the reason for this report?

How do I mask a domain powered by Wordpress Multisite?

Posted on May 22, 2015

Hi, I’m running a Wordpress multisite instance on a Cent OS box. I’m having a problem figuring out how to mask the intended domain.

Here’s what I’m trying to do:

Specs:

domain1.com’s conf

<VirtualHost *:80>
        ServerAdmin admin@domain1.com
        ServerName www.domain1.com
        ServerAlias domain1.com
        DocumentRoot /var/www/html
        ErrorLog /var/log/httpd/error.log
        CustomLog /var/log/httpd/access.log combined
        <Directory "/var/www/html">
                AllowOverride All
                Require all granted
        </Directory>
</VirtualHost>

domain2.com’s conf

<VirtualHost *:80>
        ServerAdmin admin@domain1.com
        ServerName www.domain2.com
        ServerAlias domain2.com
        DocumentRoot /var/www/html
        ErrorLog /var/log/httpd/domain2.com-error.log
        CustomLog /var/log/httpd/domain2.com-access.log combined

        <Location "/">
                ProxyPass  "http://domain1.com/wordpress2"
                ProxyPassReverse "http://domain1.com/wordpress2"
        </Location>
</VirtualHost>

The result is domain2.com will redirect to domain1.com/wordpress2, but the domain isn’t masked. Thank you for any guidance.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Start building today

From GPU-powered inference and Kubernetes to managed databases and storage, get everything you need to build, scale, and deploy intelligent applications.