azure-powershell icon indicating copy to clipboard operation
azure-powershell copied to clipboard

Template as hash table for New-AzureRmResourceGroupDeployment

Open gregjhogan opened this issue 10 years ago • 6 comments

Please add a TemplateObject parameter to New-AzureRmResourceGroupDeployment

New-AzureRmResourceGroupDeployment -ResourceGroupName $resourceGroup -TemplateObject $template -TemplateParameterObject $params

I can of course write it out to a file first, but it would be a lot more convenient when building template files dynamically to pass the powershell object that represents the template directly.

gregjhogan avatar Mar 18 '16 18:03 gregjhogan

We wont be able provide support for this in the near future. From a usability point of view, it will not be trivial to construct the object which represents your template.

ravbhatnagar avatar Aug 12 '16 20:08 ravbhatnagar

This would be pretty useful to have. :+1:

sahammer avatar Aug 19 '16 21:08 sahammer

@ravbhatnagar I don't understand your comment "it will not be trivial to construct the object which represents your template". I am constructing the template as an object. Currently when a local template file is used, you read it in as an object and post it to an API endpoint. I just want to construct the exact same object that would be placed in a template file and then pass that as a parameter (instead of having to save it to a file first). It is a convenience thing when you are dynamically generating templates.

gregjhogan avatar Aug 19 '16 23:08 gregjhogan

I honestly don't see value in this, maybe for small templates, but I have templates at 500 lines and more, it would be a nightmare to construct them in PS + I have some pretty weird login in most of those so, I see why they are hesitating to work on this, would be nice to have, but meh

4c74356b41 avatar Apr 10 '17 21:04 4c74356b41

Closing due to the comment.

vladimir-shcherbakov avatar Jun 26 '18 22:06 vladimir-shcherbakov

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @rthorn17

ghost avatar Aug 14 '19 19:08 ghost