Virtualhost not able to be selected - Can't install certificate in a second website

Sure, but Apache configuration files with the -le-ssl.conf suffix are usually generated automatically by the apache plugin from Certbot. Certbot does NOT add those HTTP vhosts to the ...-le-ssl.conf file, but keeps it in the original configuration file Certbot is basing the ...-le-ssl.conf file on. So that leads to two possibilities:

  • Either someone has named their non-Certbot configuration file with the -le-ssl.conf suffix coincidentally, OR;
  • Someone has manually modified the Certbot generated -le-ssl.conf file.

If it's the latter, which IMO is the most likely option, they've manually added two HTTP vhosts where there already was one.. Which doesn't make much sense. Especially with a ServerAlias with the same value as ServerName...

1 Like

We are agreed on the misconfiguration.
I'm just saying that "it should not be in there" is a bit strong.
And is allowed to be in there (somewhere/anywhere in the config) by nature.
Yes, certbot did NOT put it there.
But even certbot will continue to work with it there.

Back to the problem at hand...
Reduce the three down to one [pick one] and let's see if that one (with the right names) can point to the correct content location.

2 Likes

Maybe. With "should not be in there" I meant "Certbot didn't do it, someone messed it up". Maybe a little bit strong, maybe some people can't handle the truth :wink:

3 Likes

Just some of A Few Good Men :laughing:

2 Likes

So, I have never edited the -le-ssl.conf files before following suggestions on this thread.

Moreover, I have never accessed the /apache2/sites-enabled folder before.

This was very strange, also after reading your responses, because I have never messed up with files inside /sites-enabled.

The only thing I've done (beyond what you suggested here) was to use Certbot to delete both SSL certificates and install them again (procedure done more than 2 times).

Well, guys, I am really sorry for posting things not related to Let's Encrypt in the most part of this thread. But is that those problems arose after some Certbot run, so I was (and I still am) a bit confused.

Hm, then I'm wondering where all those extra HTTP vhosts were coming from..

2 Likes

I really don´t understand that yet. :slight_smile:

And, well, if I try to curl neosys.com.br, for example, now I get a message as below:

<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>301 Moved Permanently</title>
</head><body>
<h1>Moved Permanently</h1>
<p>The document has moved <a href="https://neosys.com.br/">here</a>.</p>
<hr>
<address>Apache/2.4.52 (Ubuntu) Server at neosys.com.br Port 80</address>
</body></html>

I really don't know if the above is correct, but, well, just noticed it right now.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.