Azure / powershell

GH Action to run Az PowerShell scripts for developers and administrators to develop, deploy, and manage Microsoft Azure applications.
MIT License
64 stars 41 forks source link

Error parsing boolean value. Path '', line 1, position 1. #44

Closed dkirrane closed 3 years ago

dkirrane commented 3 years ago

I'm attempting to deploy a Bicep file that I don't have issues deploying locally

I keep hitting Error parsing boolean value. Path '', line 1, position 1.

    - name: Bicep Hyperscale
      uses: azure/powershell@v1.1.0
      with:
        azPSVersion: '3.5.0'
        inlineScript: |
          Set-Location ${{ github.workspace }}/script/
          New-AzResourceGroupDeployment -ResourceGroupName "test-rg" -TemplateFile my.bicep -Mode Incremental
matsest commented 3 years ago

Seeing parameter parsing issues with azPSVersion: 'latest' also for Azure Deployments with Powershell.

BALAGA-GAYATRI commented 3 years ago
  1. Since the path parameter is not accepting, you might need to try with putting " "(double-quotes) for my.bicep so that your command looks like New-AzResourceGroupDeployment -ResourceGroupName "test-rg" -TemplateFile "my.bicep" -Mode Incremental also make sure you give a valid working path of TemplateFile.
  2. You should add a step for azure/login@v1 before you execute az-pwsh commands as a prerequisite. Make sure you set enable-AzPSSession: true in azure/login

Have a look at the detailed example . Let us know if it works.

dkirrane commented 3 years ago

still hitting the issue with quotes added and I have enable-AzPSSession: true Maybe related to https://github.com/Azure/bicep/discussions/3140

dkirrane commented 3 years ago

Seems to be ok now. I had to upgrade to azPSVersion: "6.4.0"

BALAGA-GAYATRI commented 3 years ago

@dkirrane Good to hear. It is also recommended to use azPSVersion: "latest" or explicitly provide the latest version in our workflow unless you have any version preference in specific. Usually any bugs in the previous versions are covered in later versions. Closing this issue as this page deals with only issues regarding azure/powershell action.