0

根据https://docs.developer.swisscom.com/services/services/managing-services.html#service-connector,我应该能够运行

cf service-connector 13000 XXXXSHOST.service.consul:XXXXSPORT

然而,这就是发生的事情:

PS C:\Users\XXXX> cf install-plugin .\Downloads\swisscom-plugin.exe    
Installing plugin .\Downloads\swisscom-plugin.exe... 
OK 

Plugin SwisscomPlugin successfully installed. 
PS C:\Users\XXXX> cf plugins 
Listing Installed Plugins... 
OK

Plugin name Version Command name Command Help 
SwisscomPlugin 1.0.2 service-connector, sc Create a local listener for a service instance 
PS C:\Users\XXXX> cf service-connector help

FAILED 
Incorrect usage.

NAME: 
service-connector - Create a local listener for a service instance

ALIAS: 
sc

USAGE: 
cf service-connector LOCAL_PORT SERVICE_HOST:SERVICE_PORT [--skip-ssl-validation]

OPTIONS: 
-skip-ssl-validation Please don't

PS C:\Users\XXXX> cf service-connector 13000 XXXXSHOST.service.consul:XXXXSPORT

FAILED 
No org or space targeted, use 'cf target -o ORG -s SPACE' 
PS C:\Users\XXXX>

(XXXXSHOST and XXXXSPORT are the actual values from VCAP_SERVICES.)
4

1 回答 1

1

它会检查您是否被允许预先访问该服务,因此您必须登录并预先选择您的组织/空间;

即您是否预先登录并选择了您的组织空间?

#cf login

#cf target –o <YourOrg> –s <YourSpace> 
(with cf orgs and cf spaces you can see your available/created orgs)

# cf service-connector 13000 XXXXSHOST.service.consul:XXXXSPORT

最佳马可

于 2015-10-17T09:56:11.110 回答