Azure / template-specs

MIT License
31 stars 4 forks source link

TemplateSpec and URI co-exist #46

Closed slavizh closed 3 years ago

slavizh commented 3 years ago

Hi, I think I know the answer but can you have a template that works for both being deployed via template spec and via storage account URIs. As far as my research shows it is not possible. For example I have tried to use conditions to either put uri or relativePath value in templateLink but such approach works only when you do New-AzDeployment and URIs as the conditions are evaluated at the deployment but when you do New-AzTemplateSpec with relativePath it does not work as the upon creation of template spec conditions inside the template are not evaluated. So is there some other method I do not see to achieve this or not possible?

slavizh commented 3 years ago

never-mind, found the example: https://github.com/ajf214/personal-arm-templates/tree/main/ARM-Templates/testing/linked-template-relPath