I have made some scripting to automate the certificate creation and renewal, I have added some functionalities simple but I think useful:
-Precheck if the challenge directory is reachable.
-Check the expire date of the certificate an renew only when an specified number of days is reached.
-Alert with an email if the process of renewal is failing.
-Check all the existing certificates
I have done with some curl and openssl stuff, you can see the details here http://eblog.damia.net/2015/12/03/lets-encrypt-automation-on-debian/