nickjj / ansible-letsencrypt

Install and auto-renew SSL certificates with Let's Encrypt and Ansible.
MIT License
29 stars 9 forks source link

Allow specifying more than one service to reload #3

Open cristoper opened 6 years ago

cristoper commented 6 years ago

This pull request implements two changes (in two separate commits):

Both changes are backward compatible with the existing letsencrypt_restart_service_name variable.

nickjj commented 6 years ago

Hi,

Can you provide a use case for when multiple services would be necessary to restart? Typically you would have SSL termination done once.

Oh yeah, in the upcoming rewrite it's no longer limited to just restarting services, but you can provide an entire command to execute. This could be useful because who knows what you're running on your server. It might be a service, a docker container or part of a docker-compose project. You would be able to issue a restart or reload too using this strategy.

cristoper commented 6 years ago

In installations with several SSL-enabled services (https, smtps, imaps) on the same machine, I'd expect it is more common to configure them all to directly use the same certificate than to put them behind a multi-protocol reverse proxy doing SSL termination (I could be wrong, though). It seems much more straight-forward to me, anyway.

Regarding the upcoming rewrite: sounds good!

nickjj commented 6 years ago

Ok, good to know. It will be a list of commands to restart then, instead of just 1, as per your PR suggestion, just applied to full commands.