R
R
Roman2022-04-13 09:25:44
Apache HTTP Server
Roman, 2022-04-13 09:25:44

How to set up Apache on multiple hosts with SSL and one external IP?

Hello!

There are VPS. On it stand:
Debian 9
Apache 2.4.25
OpenSSL 1.1.0l
The ssl module for Apache is included

Separately at once I will tell about Nginx. It is not installed and I do not want to install it yet (I do not exclude installation in the future), because there is no particular need and I would like to understand Apache first.

And so, 3 virtual hosts are configured, 3 domains are attached to them, conditionally mysite1.ru, mysite2.ru, mysite3.ru Also installed and, it seems to me, certbot works fine (no errors occur in the process of obtaining keys, everything is successfull). With it, I got 3 SSL certificates for these 3 domains. The first domain opens normally, but the second and third try to open with the certificate of the first. I think both you and I understand why - the SNI technology does not work correctly or at all. I probably read almost everything that is recommended on the network, but nothing helped, well, the crookedness of my hands apparently also affects.

The question is simple - how to set it all up to make it work?
Any ideas welcome!

PS According to the results, the person whose advice will help resolve the issue is ready to treat him to an ice cream or other material "bun"!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
AlexVWill, 2022-04-13
@AlexVWill

The question is simple - how to set it all up to make it work?

Post the configs of all three domains here... Maybe somewhere the redirect rule from 80 to 443 is incorrectly specified

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question