Skip to content

Can you use module deployment without referencing any parameters #6771

Answered by johnlokerse
uky2019 asked this question in Q&A
Discussion options

You must be logged in to vote

@uky2019 You don't have to specify parameters if your template doesn't have any. Does your Deploy_VPN_gateway.bicep contain parameters?

For example, when you want to deploy a resource group and you don't have parameters you can call this module without specifing parameters:

ResourceGroup.bicep

targetScope = 'subscription'
resource resNewRg 'Microsoft.Resources/resourceGroups@2021-04-01' = {
  name: 'my-rg'
  location: 'westeurope'
}

Orchestration using a module referring the ResourceGroup.bicep:

targetScope = 'subscription'
module modNewRg 'ResourceGroup.bicep' = {
  name: 'deploy-rg'
}

Replies: 5 comments 11 replies

Comment options

You must be logged in to vote
4 replies
@uky2019
Comment options

@kevball2
Comment options

@johnlokerse
Comment options

@johnlokerse
Comment options

Answer selected by brwilkinson
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@kevball2
Comment options

@johnlokerse
Comment options

Comment options

You must be logged in to vote
2 replies
@brwilkinson
Comment options

@uky2019
Comment options

Comment options

You must be logged in to vote
3 replies
@brwilkinson
Comment options

@Demic198
Comment options

@brwilkinson
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
5 participants