-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor main.bicep and vnets.bicep for accurate workload subnet refe…
…rencing and streamline firewall module integration. Corrected subnet indexing and ensured proper parameter passing between modules
- Loading branch information
1 parent
d3fb057
commit f2fa1aa
Showing
3 changed files
with
40 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# PowerShell script for validating Azure Bicep templates | ||
|
||
# Ensuring Azure CLI and Bicep are installed | ||
if (-not (Get-Command "az" -ErrorAction SilentlyContinue)) { | ||
Write-Error "Azure CLI is not installed. Please install it from https://aka.ms/installazurecliwindows" | ||
exit | ||
} | ||
|
||
if (-not (Get-Command "bicep" -ErrorAction SilentlyContinue)) { | ||
Write-Error "Bicep CLI is not installed. Please install it from https://aka.ms/installbicep" | ||
exit | ||
} | ||
|
||
# Validate main.bicep | ||
Write-Host "Validating main.bicep..." | ||
az bicep build --file ./bicep/main.bicep | ||
|
||
# Validate firewall.bicep | ||
Write-Host "Validating firewall.bicep..." | ||
az bicep build --file ./bicep/firewall.bicep | ||
|
||
# Validate vnets.bicep | ||
Write-Host "Validating firewall.bicep..." | ||
az bicep build --file ./bicep/vnets.bicep | ||
|
||
Write-Host "Validation completed." |