VSTS Service Fabric Release to Azure: Exception ca

2019-07-09 02:09发布

问题:

Following this: https://docs.microsoft.com/en-us/azure/service-fabric/service-fabric-set-up-continuous-integration

But when I run the actual deploy, I get the following constructor error which is not very helpful.

==============================================================================
Task         : Service Fabric Application Deployment
Description  : Deploy a Service Fabric application to a cluster.
Version      : 1.1.2
Author       : Microsoft Corporation
Help         : [More Information](https://go.microsoft.com/fwlink/?LinkId=820528)
==============================================================================
Searching for path: C:\a\r1\a\LONG_PATH\PublishProfiles\Dev.xml
Found path: C:\a\r1\a\LONG_PATH\PublishProfiles\Dev.xml
Searching for path: C:\a\r1\a\**\drop\applicationpackage
Found path: C:\a\r1\a\PATH\drop\applicationpackage
AAD Authority: 
Cluster Application ID: 
Client Application ID: 
##[error]Exception calling ".ctor" with "1" argument(s): "Value cannot be null. Parameter name: authority"
##[section]Finishing: Deploy Service Fabric Application
##[section]Finishing: Release

Any ideas? Where can I look for possibly a better error message? If I deploy from my desktop and VS2015 it works fine. Thank you.

IN REPLY TO MATT THALMAN:

ConnectionEndpoint   : {myapp.eastus.cloudapp.azure.com:19000}
FabricClientSettings : {
                       ClientFriendlyName                   : PowerShell-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
                       PartitionLocationCacheLimit          : 100000
                       PartitionLocationCacheBucketCount    : 1024
                       ServiceChangePollInterval            : 00:02:00
                       ConnectionInitializationTimeout      : 00:00:02
                       KeepAliveInterval                    : 00:00:20
                       HealthOperationTimeout               : 00:02:00
                       HealthReportSendInterval             : 00:00:00
                       HealthReportRetrySendInterval        : 00:00:30
                       NotificationGatewayConnectionTimeout : 00:00:30
                       NotificationCacheUpdateTimeout       : 00:00:30
                       AuthTokenBufferSize                  : 4096
                       }

回答1:

There is the feedback of this issue, you can track it, based on that feedback, the workaround is using certificate authentication.

On the other hand, you can check the source code of that task from here.



回答2:

I've got this issue when I try execute powershell without quotes (""). Visual Studio during deploy in first time generate powershell script, which use for deploy. Try execute this script manually, and you will see which arguments put in parameters without quotes.