Skip to main content

Posts

Showing posts with the label Bicep

Azure Automation variables in Bicep

If you want to create an Azure Automation variable in Bicep you will use a resource definition like this. resource existingAutomationAccountResource 'Microsoft.Automation/automationAccounts@2023-11-01' existing = { name: 'automationAccountName' } resource variablesResource 'Microsoft.Automation/automationAccounts/variables@2023-11-01' = { name: 'variableName' parent: existingAutomationAccountResource properties: { description: 'description' isEncrypted: 'false' value: 'value' } } For variables Azure Automation supports different types: String , Boolean , DateTime , Integer and Not Specified . Below you can find some examples how to define these values in Bicep format. String values should be put between double quotes. resource stringVariablesResource 'Microsoft.Automation/automationAccounts/variables@2023-11-01' = { name: 'stringVariable' parent: existingAutomationAccountResource ...

How to control the 'Propagate Default Route' setting of a Azure VHub Network Connection from code

 Using Azure Virtual WAN for your hub/spoke network and want to know how to control the 'Propagate Default Route' setting on a Azure VHub Network Connection via code? Modifying this setting via the UI is easy. Go to the specific virtual network connection in the Virtual network connections setting of the Virtual WAN and change the value from Enable into Disable or vice versa. How to do this via code was a mystery for me until I consulted Microsoft support. If you consult the documentation for maintaining the virtual hub network connection you don't find a setting named 'Propogate Default Route' or a mention in the description about it. ARM / Bicep - Hub virtual network connections PowerShell - New-AzVirtualHubVnetConnection Azure CLI - az network vhub connection Microsoft Support explained that the attribute  enableInternetSecurity , with description 'Enable internet security.', is actually controlling the behavior off the option 'Propagate Default Ro...