0
votes

I am trying to deploy a new Azure Resource group using a ARM template. The template uses a webdeploy package that is hosted on my storage account. Now when I try to deploy the template I get an error.

This is the powershell command I run

New-AzureRmResourceGroupDeployment -Name $Name -ResourceGroupName $Name -TemplateUri $ArmTemplateUrl -TemplateParameterFile $paramJsonFile

Now in my parameters file I have a reference to a web deploy package that included a sas token in the URL:

"singleMsDeployPackageUrl":  {
                                 "value":  "https://<MYNAME>.blob.core.windows.net/sitecore/Sitecore%208.2%20rev.%20170407_single.scwdp.zip?<MYTOKEN>"
                             },

I posted the full error below. This used to work but something changed in Azure?

New-AzureRmResourceGroupDeployment : 1:43:59 PM - Resource Microsoft.Resources/deployments 'habitatazure-application' failed with message '{ "status": "Failed", "error": { "code": "ResourceDeploymentFailure", "message": "The resource operation completed with terminal provisioning state 'Failed'.", "details": [ { "code": "DeploymentFailed", "message": "At least one resource deployment operation failed. Please list deployment operations for details. Please see https://aka.ms/arm-debug for usage details.", "details": [ { "code": "Conflict", "message": "{\r\n \"status\": \"failed\",\r\n \"error\": {\r\n \"code\": \"ResourceDeploymentFailure\",\r\n \"message\": \"The resource operation completed with terminal provisioning state 'failed'.\",\r\n \"details\": [\r\n {\r\n \"code\": \"Failed\",\r\n \"message\": \"Failed to download package.\r\nAppGallery Deploy Failed: 'System.Net.WebException: The request was aborted: Could not create SSL/TLS secure channel.\r\n at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)\r\n at System.Net.WebClient.GetWebResponse(WebRequest request, IAsyncResult result)\r\n at System.Net.WebClient.DownloadBitsResponseCallback(IAsyncResult result)\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.AppGalleryPackage.&amp;amp;amp;lt;Download&amp;amp;amp;gt;d__a.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.AppGalleryPackage.&amp;amp;amp;lt;Download&amp;amp;amp;gt;d__0.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.DeploymentController.&amp;amp;amp;lt;DownloadPackageAndSettings&amp;amp;amp;gt;d__27.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.DeploymentController.&amp;amp;amp;lt;DownloadAndDeployPackage&amp;amp;amp;gt;d__17.MoveNext()'\r\nFailed to download package.\r\nAppGallery Deploy Failed: 'System.Net.WebException: The request was aborted: Could not create SSL/TLS secure channel.\r\n at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)\r\n at System.Net.WebClient.GetWebResponse(WebRequest request, IAsyncResult result)\r\n at System.Net.WebClient.DownloadBitsResponseCallback(IAsyncResult result)\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.AppGalleryPackage.&amp;amp;lt;Download&amp;amp;gt;d__a.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.AppGalleryPackage.&amp;amp;lt;Download&amp;amp;gt;d__0.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.DeploymentController.&amp;amp;lt;DownloadPackageAndSettings&amp;amp;gt;d__27.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.DeploymentController.&amp;amp;lt;DownloadAndDeployPackage&amp;amp;gt;d__17.MoveNext()'\r\nFailed to download package.\r\nAppGallery Deploy Failed: 'System.Net.WebException: The request was aborted: Could not create SSL/TLS secure channel.\r\n at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)\r\n at System.Net.WebClient.GetWebResponse(WebRequest request, IAsyncResult result)\r\n at System.Net.WebClient.DownloadBitsResponseCallback(IAsyncResult result)\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.AppGalleryPackage.&amp;lt;Download&amp;gt;d__a.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.AppGalleryPackage.&amp;lt;Download&amp;gt;d__0.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.DeploymentController.&amp;lt;DownloadPackageAndSettings&amp;gt;d__27.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.DeploymentController.&amp;lt;DownloadAndDeployPackage&amp;gt;d__17.MoveNext()'\r\nFailed to download package.\r\nAppGallery Deploy Failed: 'System.Net.WebException: The request was aborted: Could not create SSL/TLS secure channel.\r\n at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)\r\n at System.Net.WebClient.GetWebResponse(WebRequest request, IAsyncResult result)\r\n at System.Net.WebClient.DownloadBitsResponseCallback(IAsyncResult result)\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.AppGalleryPackage.&lt;Download&gt;d__a.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.AppGalleryPackage.&lt;Download&gt;d__0.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.DeploymentController.&lt;DownloadPackageAndSettings&gt;d__27.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.DeploymentController.&lt;DownloadAndDeployPackage&gt;d__17.MoveNext()'\r\nFailed to download package.\r\nAppGallery Deploy Failed: 'System.Net.WebException: The request was aborted: Could not create SSL/TLS secure channel.\r\n at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)\r\n at System.Net.WebClient.GetWebResponse(WebRequest request, IAsyncResult result)\r\n at System.Net.WebClient.DownloadBitsResponseCallback(IAsyncResult result)\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.AppGalleryPackage.<Download>d__a.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.AppGalleryPackage.<Download>d__0.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.DeploymentController.<DownloadPackageAndSettings>d__27.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.Web.Deployment.WebApi.DeploymentController.<DownloadAndDeployPackage>d__17.MoveNext()'\"\r\n }\r\n ]\r\n }\r\n}" } ] } ] } }'

1
Are you pulling anything from github.com there by any chance?evilSnobu
Just the ARM template itself (JSON) is hosted on github:raw.githubusercontent.com/Sitecore/…Gluip
Okay, try this workaround in PowerShell (before invoking New-AzureRmResourceGroupDeployment): github.com/snobu/… - it's probably related to this change: githubengineering.com/crypto-removal-noticeevilSnobu
You should also try this iwr https://ACCOUNT.blob.core.windows.net/, the result should be a query parameter error but not a TLS one.evilSnobu
Any luck with setting the ServicePointManager before invoking your deployment? (my first link - github.com/snobu/…)evilSnobu

1 Answers

0
votes

For anyone's information (and future reference). I have figured out (part of) the problem. Looking with KUDU tools on the app service I was able to pinpoint more precisely the package that is the culprit. I have found the following error :

Downloading package path 'Sitecore/Sitecore-Azure-Quickstart-Templates/releases/download/v1.5.0/SetCompatibilityLevel.scwdp.zip' from blob 'https://github.com' Failed to download package.

So downloading a package from Github.com is the problem. I will try to alter the templates to get this elsewhere.