liprec / vsts-release-aas

Repository for my Analysis Service Azure pipelines tasks related to Azure Analysis Service or Power BI Premium
Other
27 stars 28 forks source link

Login type "inherit" fails with error "Cannot bind argument to parameter 'String' because it is null" #127

Open traberc opened 9 months ago

traberc commented 9 months ago

I am updating an existing deployment using SPN to use the service connection identity instead, using "loginType: Inherit". This fails with the error "Cannot bind argument to parameter 'String' because it is null". In my case, I am using an ADO managed identity service connection.

ADO task output:

==============================================================================
Task         : Tabular Database Deployment
Description  : Deploy tabular databases to Azure Analysis Services or Power BI Premium
Version      : 1.5.11
Author       : Jan Pieter Posthuma
Help         : [More Information](https://github.com/liprec/vsts-release-aas)
==============================================================================
Added TLS 1.2 in session.
##[warning]The 'overwrite' option will be deprecated in a future version.
##[error]Cannot bind argument to parameter 'String' because it is null.

Working YAML task definition using SPN:

  - task: deploy-aas-db@1
    displayName: 'GeneralLedger: Deploy model'
    inputs:
      # Azure DevOps connection info
      connectedServiceNameSelector: connectedServiceNameARM
      connectedServiceNameARM: ${{ parameters.ServiceConnectionName }}
      # Analysis Services connection info
      aasServer: ${{ parameters.ServerURL }}
      databaseName: ${{ parameters.DatabaseName }}
      # Authentication type
      loginType: SPN
      # Type-specific authentication details
      appId: ${{ parameters.SpnId }}
      appKey: ${{ parameters.SpnPassword }}
      tenantId: ${{ parameters.TenantId }}
      # Model deployment info
      pathToModel: ${{ parameters.BuildArtifactPath }}/${{ parameters.PathToModel }}
      partitionDeployment: retainpartitions
      roleDeployment: deployrolesretainmembers
      # Source connection info
      connectionType: ${{ parameters.SourceConnectionType }}
      sourceSQLDatabase: ${{ parameters.SourceSqlDatabaseName }}
      sourceSQLPassword: ${{ parameters.SourceSqlPassword }}
      sourceSQLServer: ${{ parameters.SourceSqlServerFqdn }}
      sourceSQLUsername: ${{ parameters.SourceSqlUserName }}

Failing task definition using "inherit". The only difference is using "loginType: Inherit" and leaving off the appId, 'appKey, andtenantId` parameters, although I did also try leaving those parameters in with both real values and blanks.

  - task: deploy-aas-db@1
    displayName: 'GeneralLedger: Deploy model'
    inputs:
      # Azure DevOps connection info
      connectedServiceNameSelector: connectedServiceNameARM
      connectedServiceNameARM: ${{ parameters.ServiceConnectionName }}
      # Analysis Services connection info
      aasServer: ${{ parameters.ServerURL }}
      databaseName: ${{ parameters.DatabaseName }}
      # Authentication type
      loginType: Inherit
      # Model deployment info
      pathToModel: ${{ parameters.BuildArtifactPath }}/${{ parameters.PathToModel }}
      partitionDeployment: retainpartitions
      roleDeployment: deployrolesretainmembers
      # Source connection info
      connectionType: ${{ parameters.SourceConnectionType }}
      sourceSQLDatabase: ${{ parameters.SourceSqlDatabaseName }}
      sourceSQLPassword: ${{ parameters.SourceSqlPassword }}
      sourceSQLServer: ${{ parameters.SourceSqlServerFqdn }}
      sourceSQLUsername: ${{ parameters.SourceSqlUserName }}
stale[bot] commented 3 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.