Why can't I certbot -d toastmastervoice.com and create a new VirtualHost and certificate?

OK, I’ve figured it out:

The Augeas parser doesn’t like indented comments at the end of the configuration file…

For example, this is fine (for clarity, I left out the top most of the file):

(...)
</VirtualHost>
#Foo

An extra blank line doesn’t matter, this is also fine:

(...)
</VirtualHost>

#Foo

However, when you try adding spaces or tabs, it doesn’t like that! These configuration files return the error!

(...)
</VirtualHost>
 #Foo

(Notice the subtle space before the comment.)

(...)
</VirtualHost>

     #Foo

Not good too!

So: remove the trailing comments (not required anyway) and you’re good to go!

4 Likes