In comp.infosystems.www.servers.unix, harryalder <
harryalder@gmail.com> wrote:
Hi, First, I want to say that I am a Noob at all of this and have no
Hint: paragraph breaks are your friend. You've provided a lot of detail, though, so thumbs up for that.
My overall idea is to create a website in WordPress that will serve up
the same content for four different domains in http and https. The
domains are the .com, .net, .info, and .org versions of the same site.
I'd not use virtual hosts for this, I'd use Apache's ServerAlias
inside one entry instead. Since you have two different IP addresses,
you'd need either one config covering all possible IPs or one for
each of the two.
<VirtualHost 192.168.100.188:80>
ServerName wordpress.example.com
ServerAlias wordpress.example.org wordpress.example.net wordpress.example.info
...
</VirtualHost>
<VirtualHost pub.lic.ip.add:80>
ServerName wordpress.example.com
ServerAlias wordpress.example.org wordpress.example.net wordpress.example.info
...
</VirtualHost>
Or
<VirtualHost *:80>
ServerName wordpress.example.com
ServerAlias wordpress.example.org wordpress.example.net wordpress.example.info
...
</VirtualHost>
I'd probably use the second form. It will also cover the IP addresses
you don't think about like localhost's 127.0.0.1.
You can stick a lot of hostnames on that server alias line, including
www. and non-www. versions of all the ones I listed.
Example.org would be the main site. What I have done so far is build an
Note that if you serve the same content on multiple hostnames (URLs)
Google will ding you as a spammer unless you include an html meta
header noting which one is the preferred name:
https://yoast.com/rel-canonical/
Intel server with two NIC cards. One NIC for our local network with a private IP like 192.168.100.188 the second NIC is for the Public IP
address for use in the DNS. I then set up each domains DNS to point to
the single Public IP. Next, I installed and configured CentOS 7.5.1804, installed the LAMP stack including Apache 2.4.6 and php 2.4.0. Installed
That is an implausible PHP version. Perhaps you mean 7.4.0? It doesn't
matter for this, however.
[...]
ran certbot --apache without any domains. I was prompted for the
domains. Upon Entering the domains and continuing I got the message:
"Unable to find a virtual host listening on port 80 which is currently
needed for Certbot to prove to the CA that you control your domain.
Please add a virtual host for port 80." I know that I should create a virtual host for each domain but I'm not exactly sure how.
I'm very confident that so long as you name the sites in a ServerName
or ServerAlias directive certbot will find the right spot.
Can four domains share the same DocumentRoot directory?
Yes. Even if it were four different virtual host entries.
Also, how would I determine exactly where WordPress is storing the
needed info for DocumentRoot?
It's been a while since I've done wordpress, but I'm pretty sure
that *if* it cares, it has it in /(documentroot)/wordpress/wp-config.php
But since you can use a single directory, you shouldn't need to edit
that for this reason.
Thanks very much, ahead of time, for your
help. Please be nice. Ten days ago I couldn't even spell Linux,
I've come this far, but I'm truly lost now.
You are off to a good start. But... you'll get more eyes posting at stackoverflow.com than on Usenet.
Elijah
------
domain "parking" is a common example of massively shared DocumentRoot
--- SoupGate-Win32 v1.05
* Origin: fsxNet Usenet Gateway (21:1/5)