Skip to content

Commit a10a2b9

Browse files
Merge pull request #439 from microsoft/PSL-BUG-21651
fix: Update Bicep file path for cross-platform compatibility in deployment script
2 parents 5516f95 + 9982a77 commit a10a2b9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Deployment/resourcedeployment.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,7 @@ function DeployAzureResources([string]$location, [string]$modelLocation) {
246246

247247
# Perform a what-if deployment to preview changes
248248
Write-Host "Evaluating Deployment resource availabilities to preview changes..." -ForegroundColor Yellow
249-
$whatIfResult = az deployment group what-if --resource-group $resourceGroupName --template-file .\main.bicep --name $deploymentName --parameters modeldatacenter=$modelLocation location=$location environmentName=$environmentName
249+
$whatIfResult = az deployment group what-if --resource-group $resourceGroupName --template-file "./main.bicep" --name $deploymentName --parameters modeldatacenter=$modelLocation location=$location environmentName=$environmentName
250250

251251
if ($LASTEXITCODE -ne 0) {
252252
Write-Host "There might be something wrong with your deployment." -ForegroundColor Red
@@ -257,7 +257,7 @@ function DeployAzureResources([string]$location, [string]$modelLocation) {
257257
# Proceed with the actual deployment
258258
Write-Host "Proceeding with Deployment..." -ForegroundColor Yellow
259259
Write-Host "Resource Group Name: $resourceGroupName" -ForegroundColor Yellow
260-
$deploymentResult = az deployment group create --resource-group $resourceGroupName --template-file .\main.bicep --name $deploymentName --parameters modeldatacenter=$modelLocation location=$location environmentName=$environmentName
260+
$deploymentResult = az deployment group create --resource-group $resourceGroupName --template-file "./main.bicep" --name $deploymentName --parameters modeldatacenter=$modelLocation location=$location environmentName=$environmentName
261261
# Check if deploymentResult is valid
262262
ValidateVariableIsNullOrEmpty -variableValue $deploymentResult -variableName "Deployment Result"
263263
if ($LASTEXITCODE -ne 0) {

0 commit comments

Comments
 (0)