Help with my conditions #18322
GBCSIM1
started this conversation in
Authoring Help
Replies: 1 comment
-
|
Are you doing something like this? var arrayList = [
'value1'
'value2'
'value3'
]
module module2 './module2.bicep' = [ for item in arrayList: if(item != 'value2') {
name: 'module2-${item}'
}
]
// Forgot the if condition
output moduleOutputs array = [ for (mod, i) in arrayList: {
item: arrayList[i]
output: module2[i].outputs.someOutput
} ]The error message var arrayList = [
'value1'
'value2'
'value3'
]
var filteredArrays = filter(arrayList, item => item != 'value2')
module module2 './module2.bicep' = [ for item in filteredArrays: {
name: 'module2-${item}'
}
]
// If condition no longer needed
output moduleOutputs array = [ for (mod, i) in filteredArrays: {
item: filteredArrays[i]
output: module2[i].outputs.someOutput
} ] |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
When trying to deploy Recovery Services Vault in our landing zone repo.
My module is this:
The problem i have now that the name
name: '${pipelineId}-recoveryServicesVault_${subnet.subnetName}'
Doesn't just pick up the "Backup" subnet it also tries to do others in our list too.
Is there anyway my condition can specify the Backup subnet.
This deploys the Backup Subnet and then tries with the mgmt subnet.
This is the Pipeline error.
Deployment '873574-recoveryServicesVault_mgmt' could not be found. (Code: DeploymentNotFound)
Beta Was this translation helpful? Give feedback.
All reactions