ohadschn / letsencrypt-webapp-renewer

[PLEASE USE FREE MS MANAGED CERTS INSTEAD] Simple WebJob-ready console application for renewing Azure Web App SSL certificates
https://www.ohadsoft.com/
Apache License 2.0
282 stars 51 forks source link

Support deployment slots #35

Closed dhilgarth closed 6 years ago

dhilgarth commented 6 years ago

It would be great if you could support deployment slots. My Web App is named simple-dms and one of my slots is named test I have tried to configure it like this:

  1. letsencrypt:webApps: simple-dms-test
  2. letsencrypt:webApps: simple-dms(test)
  3. letsencrypt:webApps: simple-dms letsencrypt:simple-dms-hosts: simple-dms.test.fire-development.com

Nothing worked.

The first two fail with

Encountered exception: Microsoft.Rest.Azure.CloudException: The Resource 'Microsoft.Web/sites/simple-dms(test)' under resource group 'SimpleDms' was not found."

The third doesn't fail but also doesn't renew the certificate and I am seeing this in the log:

[12/20/2017 11:37:03 > c2d2b2: INFO] AzureLetsEncryptRenewer.exe Information: 0 : Starting renew of certificate simple-dms.test.fire-development.com expiration date 6/4/2017 2:51:00 PM [12/20/2017 11:37:03 > c2d2b2: INFO] AzureLetsEncryptRenewer.exe Information: 0 : Certificate 7ED69005259A90EA11F142E27DBC0C80F0C7BB50 was not assigned any hostname, skipping update

ohadschn commented 6 years ago

Have you tried the letsencrypt:webAppName-siteSlotName setting?

I haven't tested it myself but reports suggest it works: https://github.com/ohadschn/letsencrypt-webapp-renewer/issues/2.

dhilgarth commented 6 years ago

Based on your comments in that issue, I would need one webjob per slot. I have a total of four slots... I agree with Geert, that is a lot of work.

ohadschn commented 6 years ago

I see. In that case I'll close this one and re-open that one.