Am 2021-11-08 um 17:36 schrieb Mark Thomas:
On 08/11/2021 15:36, Michael Osipov wrote:
Folks,

consider the following in httpd.conf:

Listen {IP}:8443
Listen {IP}:8444

later:
<Virtualhost {IP}:8443>
   DocumentRoot /www/webapps1
   ServerName {hostname}
   mod_ssl config...
</VirtualHost>
<Virtualhost {IP}:8444>
   DocumentRoot /www/webapps2
   ServerName {hostname}
   mod_ssl config2...
</VirtualHost>

The second virtual host shall deliver only a subset of webapps1, but configured client cert auth to avoid issues with PHA and renotiation.

Now, I am looking for the same in Tomcat. Given that I have one Server, one Service, two Connectors one Engine and two Hosts there is no way to bind a Host in Tomcat to an listen address, but only to a hostname/IP address.  From my understanding of the server.xml I would need set up *two* Service elements with one Engine, Connector and Host each.

Is my understanding correct?

Yes. Connector elements are associated with a Service so if you want different Hosts on different ports you need different Services.


Thanks, I already thought so. This is a solution I can happily live with.

Maybe this could be simplified in Tomcat 11 from an admin/developer point of view.

M

Reply via email to