InternalServerError with AddCertificate
See original GitHub issueHello,
I try to add a certificate, but I get a InternalServerError in the response when it tries to add the certificate to the app service. Any idea what the problem can be? Thank you?
Orchestrator function ‘AddCertificate’ failed: The activity function ‘UpdateCertificate’ failed: “Failed to deserialize exception from TaskActivity: {”$type":“Microsoft.Azure.Management.WebSites.Models.DefaultErrorResponseException, Microsoft.Azure.Management.Websites”,“Request”:{“$type”:“Microsoft.Rest.HttpRequestMessageWrapper, Microsoft.Rest.ClientRuntime”,“Method”:{“$type”:“System.Net.Http.HttpMethod, System.Net.Http”,“Method”:“PUT”},“RequestUri”:“https://management.azure.com/subscriptions/1683198f-4c7d-4609-aaef-6ae9084e4682/resourceGroups/MSCLOUD-RG01/providers/Microsoft.Web/certificates/mijn.ubnuitzendbureau.com-1D3F7F2917DF29E03F286FC45EFEFCABF77A1FCD?api-version=2018-11-01",“Properties”:{“$type”:"System.Collections.Generic.Dictionary`2[[System.String, System.Private.CoreLib],[System.Object, System.Private.CoreLib]], System.Private.CoreLib”},“Content”:“{\r\n "properties": {\r\n "pfxBlob": "Mrj5S",\r\n "password": "Pd",\r\n "serverFarmId": "/subscriptions/1683198f-4c7d-4609-aaef-6ae9084e4682/resourceGroups/MSCLOUD-RG01/providers/Microsoft.Web/serverfarms/PORTALS"\r\n },\r\n "location": "West Europe"\r\n}”,“Headers”:{“$type”:“System.Collections.Generic.Dictionary2[[System.String, System.Private.CoreLib],[System.Collections.Generic.IEnumerable
1[[System.String, System.Private.CoreLib]], System.Private.CoreLib]], System.Private.CoreLib”,“x-ms-client-request-id”:[“2401a0c9-9e1e-4570-9a0e-38f3c7277352”],“Accept-Language”:[“en-US”],“Authorization”:[“Bearer eyJ0e4Q”],“User-Agent”:[“FxVersion/4.6.28207.03”,“OSName/Windows”,“OSVersion/Microsoft.Windows.10.0.14393.”,“Microsoft.Azure.Management.WebSites.WebSiteManagementClient/2.2.0”],“Request-Context”:[“appId=cid-v1:3945ab3b-2765-48b1-bfb1-4c7c7d56c12f”],“traceparent”:[“00-1f89ba052cc11540a960983455b96bfb-aef7c8ac223e8d4e-00”],“Request-Id”:[“|1f89ba052cc11540a960983455b96bfb.aef7c8ac223e8d4e.”],“Content-Type”:[“application/json; charset=utf-8”],“Content-Length”:[“4206”]}},“Response”:{“$type”:“Microsoft.Rest.HttpResponseMessageWrapper, Microsoft.Rest.ClientRuntime”,“StatusCode”:500,“ReasonPhrase”:“Internal Server Error”,“Content”:“{"Message":"An error has occurred."}”,“Headers”:{“$type”:“System.Collections.Generic.Dictionary2[[System.String, System.Private.CoreLib],[System.Collections.Generic.IEnumerable
1[[System.String, System.Private.CoreLib]], System.Private.CoreLib]], System.Private.CoreLib”,“Cache-Control”:[“no-cache”],“Pragma”:[“no-cache”],“Strict-Transport-Security”:[“max-age=31536000; includeSubDomains”],“Server”:[“Microsoft-IIS/10.0”],“X-AspNet-Version”:[“4.0.30319”],“X-Powered-By”:[“ASP.NET”],“x-ms-failure-cause”:[“service”],“x-ms-ratelimit-remaining-subscription-writes”:[“1199”],“x-ms-request-id”:[“7573bfd1-b9bd-466b-bf76-6771e8f23038”],“x-ms-correlation-request-id”:[“7573bfd1-b9bd-466b-bf76-6771e8f23038”],“x-ms-routing-request-id”:[“WESTEUROPE:20191223T153459Z:7573bfd1-b9bd-466b-bf76-6771e8f23038”],“X-Content-Type-Options”:[“nosniff”],“Date”:[“Mon, 23 Dec 2019 15:34:59 GMT”],“Connection”:[“close”],“Content-Length”:[“36”],“Content-Type”:[“application/json; charset=utf-8”],“Expires”:[“-1”]}},“Body”:{“$type”:“Microsoft.Azure.Management.WebSites.Models.DefaultErrorResponse, Microsoft.Azure.Management.Websites”,“error”:null},“Message”:“Operation returned an invalid status code ‘InternalServerError’”,“Data”:{“$type”:“System.Collections.ListDictionaryInternal, System.Private.CoreLib”},“InnerException”:null,“StackTrace”:" at Microsoft.Azure.Management.WebSites.CertificatesOperations.CreateOrUpdateWithHttpMessagesAsync(String resourceGroupName, String name, Certificate certificateEnvelope, Dictionary2 customHeaders, CancellationToken cancellationToken)\r\n at Microsoft.Azure.Management.WebSites.CertificatesOperationsExtensions.CreateOrUpdateAsync(ICertificatesOperations operations, String resourceGroupName, String name, Certificate certificateEnvelope, CancellationToken cancellationToken)\r\n at Microsoft.Azure.WebJobs.Host.Executors.VoidTaskMethodInvoker
2.InvokeAsync(TReflected instance, Object[] arguments) in C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Executors\VoidTaskMethodInvoker.cs:line 20\r\n at Microsoft.Azure.WebJobs.Host.Executors.FunctionInvoker`2.InvokeAsync(Object instance, Object[] arguments) in C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Executors\FunctionInvoker.cs:line 52\r\n at Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.InvokeAsync(IFunctionInvoker invoker, ParameterHelper parameterHelper, CancellationTokenSource timeoutTokenSource, CancellationTokenSource functionCancellationTokenSource, Boolean throwOnTimeout, TimeSpan timerInterval, IFunctionInstance instance) in C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Executors\FunctionExecutor.cs:line 585\r\n at Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithWatchersAsync(IFunctionInstanceEx instance, ParameterHelper parameterHelper, ILogger logger, CancellationTokenSource functionCancellationTokenSource) in C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Executors\FunctionExecutor.cs:line 532\r\n at Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(IFunctionInstanceEx instance, ParameterHelper parameterHelper, IFunctionOutputDefinition outputDefinition, ILogger logger, CancellationTokenSource functionCancellationTokenSource) in C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Executors\FunctionExecutor.cs:line 468\r\n at Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(IFunctionInstanceEx instance, FunctionStartedMessage message, FunctionInstanceLogEntry instanceLogEntry, ParameterHelper parameterHelper, ILogger logger, CancellationToken cancellationToken) in C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Executors\FunctionExecutor.cs:line 278",“HelpLink”:null,“Source”:“Microsoft.Azure.Management.Websites”,“HResult”:-2146233088}". See the function execution logs for additional details.
Issue Analytics
- State:
- Created 4 years ago
- Comments:9 (4 by maintainers)
Top GitHub Comments
Thank you for reporting.
The problem has been reproduced and will be fixed soon.
Tested now, worked perfect when I added the certificates!
Thank you @shibayan for this great tool, it’s the best way we have to work with Let’s Encrypt in Azure Apps!