Questions tagged [azure-bicep]

Bicep is a Domain Specific Language (DSL) for deploying Azure resources declaratively. It aims to drastically simplify the authoring experience with a cleaner syntax and better support for modularity and code re-use. Bicep compiles down to standard ARM Template JSON files, which means the ARM JSON is effectively being treated as an Intermediate Language (IL).

Bicep is an alternative to using terraform as Infrastructure-as-Code to programmatically create, modify or destroy Azure resources.

A productive aspect of Bicep is the ability to take a snapshot of an existing Azure resource then compile that snapshot into the Bicep language to be used as a template from which to manage such a resource.

A common usage pattern is to execute your Bicep code in an Azure pipeline to engage its definitions to manage resources

688 questions
0
votes
1 answer

ARM templates how to add public IP to dns zone

I'm using arm templates for deployments (preferable bicep). Is there a simple way to add my public ip resource to preexisting DNS zone? Public IP has property named dnsSettings, but it seems that it only can set DNS pointing to azure default domain…
kirsie
  • 11
  • 4
0
votes
1 answer

How can I create an Azure Network Security Group / NSG flow log within a Bicep template?

I want to create a NSG flow log for a network security group and storage account I created with Bicep. I am deploying a NSG like resource nsg 'Microsoft.Network/networkSecurityGroups@2020-06-01' = { name: networkSecurityGroupName location:…
0
votes
1 answer

Webhook Url for Azure EventGrid Subscription with Azure Bicep Fails

I'm new to Azure Bicep (which in itself i pretty new) but have some experience with ARM templates. I'm trying to learn how to create an Azure Event Grid subscription to an Azure Blog storage container. This is not production code I've been following…
-1
votes
0 answers

Hi i want to create an Azure custom policy for vm by using bicep it should not create public ip and also follow naming convention

Hi i want to create an Azure custom policy for vm by using bicep it should not create public ip and also follow naming convention. i Have it in powershell but i am not able to convert it in Bicep. I am expecting a bicep script to create Custom…
-1
votes
1 answer

Bicep Region Pairs

For Azure Bicep: Given an array of region names ['eastus','westeurope','westus'], how can I produce an array of unique region pairs? i.e.: [{ A:'eastus', B:'westeurope' },{ A:'westeurope', B:'westus' },{ A:'westus', B:'eastus' }]
Nathan
  • 6,095
  • 2
  • 35
  • 61
-1
votes
1 answer

How can I add roles to a Azure AD group in bicep format?

I have a questions regarding "How can I add roles to a Azure AD group in bicep format" Is it possible , i will not be able to do that . If someone know ,please share with me I have a Project to make it Possible by BICEP Solution I have a some…
-1
votes
1 answer

Unable to edit or replace deployment {deploymentName}: previous deployment from {datetime} is still active (expiration time is {datetime})

I'm trying to deploy an Azure Bicep template with az deployment sub create --name "deploymentName" --template-file template.json --location="westeurope" --parameters ... When I go to Azure Portal to review my resource group deployments I can see…
Sergio
  • 175
  • 5
  • 21
-1
votes
1 answer

How to omit a storage policy rule based on a condition in bicep?

I have this bicep code to apply two rules to a storage account policy on an Azure Storage Account: @description('Name of the storage account') param name string @description('Number of days before moving from Hot to Cool storage') param…
Mark Allison
  • 6,838
  • 33
  • 102
  • 151
-1
votes
1 answer

How can I run a specific Network Security Group module in an existing Azure Bicep file using Azure DevOps YAML pipeline?

How to run only Network security group module in an existing Azure Bicep file using Azure DevOps YAML pipeline?
Satish B
  • 1
  • 1
-1
votes
1 answer

function getsecret is not valid at this location

iam using existing secrets in keyvault for my bicep file. Since last week it's working fine. But now it's throwing error. Pls help to fix this issue. function getsecret is not valid at this location function getsecret is not valid at this location.
-1
votes
1 answer

How to you variable groups in azure biceps file

How to use variable groups in azure biceps file In order to pass variables like retention days and others from library I haven't tried yet
-1
votes
2 answers

Bicep and json parameter new variable within variable

I want to create a new variable with an existing one inside a json parameter file for bicep { "myVNet_name": "test_vnet", "myVNet_name2": "????", } I want myVNet_name2 for example equal as $myVNet_name_2 , how to do that ?
Wanexa
  • 59
  • 1
  • 6
-1
votes
2 answers

Azure bicep and parameter

Is there a way to add a resourceid as a parameter ? param ftports array = [ { name: 'test' value_id:resourceId('Microsoft.Network/virtualNetworks/subnets', myVNet_name, 'mySubnet') } ] can't get rid of the error "This symbol cannot be…
Wanexa
  • 59
  • 1
  • 6
-1
votes
1 answer

How to create alerts through bicep for KQL commands

We are trying to create Azure alerts through bicep and KQL queries and using for loop to create multiple alerts. Unfortunately we are getting the errors while executing the code alerts.bicep // Parameters @description('Log alerts parameter…
-1
votes
1 answer

Azure Bicep - load excel file in Bicep

I would like to load the values from excel file, they are only names inside it and I have a lot of them. So I don't want to copy all of them and place them in an array. I want some solution if it's possible like [loadJsonContent].
1 2 3
45
46