Open jsoref opened 6 months ago
So what you have there is a Include vhosts/*.conf
stanza, and then in those files you have a bunch of VirtualHosts, some of which have bunch of Vhost defintions, and taken together, to Apache httpd this looks somewhat like this
#v1
<VirtualHost *:80>
ServerName v1
</VirtualHost>
<IfModule mod_ssl.c>
<VirtualHost *:443>
ServerName v1
</VirtualHost>
# nothing to see here!
#v2
<VirtualHost *:80>
ServerName v2
</VirtualHost>
<IfModule mod_ssl.c>
<VirtualHost *:443>
ServerName v1
</VirtualHost>
</IfModule>
So the only reason why apachectl doesn't complain, is because it sees the full picture. my opinion is that it should complain.
šµ
Apache2 conforms to Postel's law
apache2 (e.g.
apachectl -S
orapachectl reload
) doesn't mind if you have something like:But the lens will complain that there's a syntax error on that last line (because there's a missing
</IfModule>
).The end result to a consumer of
certbot
is something like: