Deployment of Logic App using VS 2015

I have got the “Parameter ‘Environment’ is obsolete.” error, while deploying my first Logic app through Visual Studio 2015, which has no meaning to the actual error.

13:53:14 – ‘C:\Users\{username}\documents\visual studio 2015\Projects\Auto\Auto\bin\Debug\staging\Auto\Deploy-AzureResourceGroup.ps1’ -StorageAccountName ” -ResourceGroupName ‘baraneespecific’ -ResourceGroupLocation ‘centralus’ -TemplateFile ‘c:\users\{username}\documents\visual studio 2015\projects\auto\auto\azuredeploy.json’ -TemplateParametersFile ‘c:\users\{username}\documents\visual studio 2015\projects\auto\auto\logicapp.parameters.json’ -ArtifactStagingDirectory ‘.’ -DSCSourceFolder ‘.\DSC’ -ValidateOnly
13:53:14 – [WARNING] Parameter ‘Environment’ is obsolete. This parameter is only for backwards compatibility; users should use EnvironmentName instead.
13:53:16 –
13:53:16 –
13:53:16 – Environment : AzureCloud
13:53:16 – Account : {email}
13:53:16 – TenantId : {GUID}
13:53:16 – SubscriptionId : {GUID}
13:53:16 – SubscriptionName : Visual Studio Enterprise
13:53:16 – CurrentStorageAccount :
13:53:16 –
13:53:16 – [VERBOSE] Performing the operation “Replacing resource group …” on target “”.
13:53:19 – [VERBOSE] 1:53:19 PM – Created resource group ‘baraneespecific’ in location ‘centralus’
13:53:19 –
13:53:19 – ResourceGroupName : baraneespecific
13:53:19 – Location : centralus
13:53:19 – ProvisioningState : Succeeded
13:53:19 – Tags :
13:53:19 – TagsTable :
13:53:19 – ResourceId : /subscriptions/{GUID}/resourc
13:53:19 – eGroups/baraneespecific
13:53:19 –
13:53:19 –
13:53:19 – Validating template using PowerShell script failed.
13:53:19 – Tell us about your experience at https://go.microsoft.com/fwlink/?LinkId=691202

Solution
Run the same in Powershell Window, so we get detailed error. In my case, I had JSON parameter wrong.
PS C:\windows\system32> cd “C:\Users\{username}\documents\visual studio 2015\Projects\Auto\Auto\bin\Debug\staging\Auto\”

PS C:\Users\{username}\documents\visual studio 2015\Projects\Auto\Auto\bin\Debug\staging\Auto> .\Deploy-AzureResourceGroup.ps1 -StorageAccountName ” -ResourceGroupName ‘baraneespecific’ -ResourceGroupLocation ‘centralus’ -TemplateFile ‘c:\users\{username}\documents\visual studio 2015\projects\auto\auto\azuredeploy.json’ -TemplateParametersFile ‘c:\users\{username}\documents\visual studio 2015\projects\auto\auto\logicapp.parameters.json’ -ArtifactStagingDirectory ‘.’ -DSCSourceFolder ‘.\DSC’ -ValidateOnly
VERBOSE: Performing the operation “Replacing resource group …” on target “”.
VERBOSE: 1:57:57 PM – Created resource group ‘baraneespecific’ in location ‘centralus’
ResourceGroupName : baraneespecific
Location : centralus
ProvisioningState : Succeeded
Tags :
ResourceId : /subscriptions/{GUID}/resourceGroups/baraneespecific

C:\Users\{username}\documents\visual studio 2015\Projects\Auto\Auto\bin\Debug\staging\Auto\Deploy-AzureResourceGroup.ps1 : Cannot retrieve the dynamic parameters for the cmdlet. Unexpected
end when deserializing object. Path ‘parameters’, line 8, position 2.
At line:1 char:1
+ .\Deploy-AzureResourceGroup.ps1 -StorageAccountName ” -ResourceGroup …
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidArgument: (:) [Deploy-AzureResourceGroup.ps1], ParameterBindingException
+ FullyQualifiedErrorId : GetDynamicParametersException,Deploy-AzureResourceGroup.ps1

PS C:\Users\{username}\documents\visual studio 2015\Projects\Auto\Auto\bin\Debug\staging\Auto> .\Deploy-AzureResourceGroup.ps1 -StorageAccountName ” -ResourceGroupName ‘baraneespecific’ -ResourceGroupLocation ‘centralus’ -TemplateFile ‘c:\users\{username}\documents\visual studio 2015\projects\auto\auto\azuredeploy.json’ -TemplateParametersFile ‘c:\users\{username}\documents\visual studio 2015\projects\auto\auto\logicapp.parameters.json’ -ArtifactStagingDirectory ‘.’ -DSCSourceFolder ‘.\DSC’ -ValidateOnly
VERBOSE: Performing the operation “Replacing resource group …” on target “”.
VERBOSE: 1:58:24 PM – Created resource group ‘baraneespecific’ in location ‘centralus’
ResourceGroupName : baraneespecific
Location : centralus
ProvisioningState : Succeeded
Tags :
ResourceId : /subscriptions/{GUID}/resourceGroups/baraneespecific
Validation returned the following errors:
: Deployment template validation failed: ‘The template parameters ‘logicAppName’ in the parameters file are not valid; they are not present in the original template and can therefore not be
provided at deployment time. The only supported parameters for this template are ”. Please see https://aka.ms/arm-deploy/#parameter-filefor usage details.’.

Template is invalid.

PS C:\Users\{username}\documents\visual studio 2015\Projects\Auto\Auto\bin\Debug\staging\Auto> .\Deploy-AzureResourceGroup.ps1 -StorageAccountName ” -ResourceGroupName ‘baraneespecific’ -ResourceGroupLocation ‘centralus’ -TemplateFile ‘c:\users\{username}\documents\visual studio 2015\projects\auto\auto\azuredeploy.json’ -TemplateParametersFile ‘c:\users\{username}\documents\visual studio 2015\projects\auto\auto\logicapp.parameters.json’ -ArtifactStagingDirectory ‘.’ -DSCSourceFolder ‘.\DSC’ -ValidateOnly
VERBOSE: Performing the operation “Replacing resource group …” on target “”.
VERBOSE: 2:03:05 PM – Created resource group ‘baraneespecific’ in location ‘centralus’
ResourceGroupName : baraneespecific
Location : centralus
ProvisioningState : Succeeded
Tags :
ResourceId : /subscriptions/{GUID}/resourceGroups/baraneespecific
Template is valid.

PS C:\Users\{username}\documents\visual studio 2015\Projects\Auto\Auto\bin\Debug\staging\Auto>

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

WordPress.com.

Up ↑

%d bloggers like this: