1
votes

I am trying to follow this tutorial:

https://anthonychu.ca/post/arm-template-storage-sendgrid/

My build pipeline worked fine, but when it got to the release it failed with this error:

"User failed validation to purchase resources. Error message: 'Legal terms have not been accepted for this item on this subscription: '87ce59eb-a0b7-428c-8b0a-506da6569d92'. To accept legal terms using PowerShell, please use Get-AzureRmMarketplaceTerms and Set-AzureRmMarketplaceTerms API(https://go.microsoft.com/fwlink/?linkid=862451), to accept the terms using Azure CLI, please use az vm image accpet-terms (https://go.microsoft.com/fwlink/?linkid=2110637) or deploy via the Azure portal to accept the terms'"

It states I can use powershell, but that doesn't seem to apply when using ARM templates and I can't seem to find an option to accept the terms when deploying.

Does anyone know how this can be done without using powershell?

1

1 Answers

1
votes

2 options, either use the powershell cmdlets provided to accept term:

Get-AzMarketplaceTerms -Publisher 'Sendgrid' -Product 'sendgrid_azure' -Name 'free' | Set-AzMarketplaceTerms -Accept

Or use the portal to create sendgrid once, after that the template will work

both options you have to carry out for each subscription you plan on using this template in