Azure / bicep

Bicep is a declarative language for describing and deploying Azure resources
MIT License
3.18k stars 730 forks source link

Allow module references to be local template json files #3160

Closed obiwanjacobi closed 3 years ago

obiwanjacobi commented 3 years ago

Is your feature request related to a problem? Please describe. This would ease the adoption of bicep and in particular be necessary for existing LogicApps. LogicApp development happens in the same file as the deployment and all the designer tools still use the json arm template format - as well as export template from the Azure Portal.

Describe the solution you'd like I think the module syntax can stay the same but 'simply' allow a .json file to be specified.

module myModule './legacyTemplate.json' = {
  name: 'legacyDeploy'
  scope: myResourceGroup      // not sure about this?
  params: {
    name: name
    location: location
  }
}
alex-frankel commented 3 years ago

LogicApp development happens in the same file as the deployment and all the designer tools still use the json arm template format

Can you clarify this one? My understanding is the LogicApp syntax is written in JSON, but is not itself an ARM template. It is more "ARM-template-like". Am I thinking about this right?

We are in the process of adding an "includeFile()" (#471) function to bring in external JSON or other text like powershell scripts. I'm hoping this is part of the solution for logic apps, policy, etc.

obiwanjacobi commented 3 years ago

The LogicApp json is the ARM deployment template as well as the definition of the workflow (yes that sucks).