Quantcast
Channel: User Nathan Basanese - Stack Overflow
Viewing all articles
Browse latest Browse all 64

How do we register a PCF Service Broker as reachable from two spaces in the same PCF Org (with org admin permissions)?

$
0
0

How do I register a Pivotal Cloud Foundry Service Broker to make it accessible from multiple spaces within the same Organization, if I have Org-level permissions?

We tried to register a PCF Service broker (cf create-service-broker ...) in one space, then use it as a 'service instance' (cf create-service ...) in another space.

To illustrate the problem, consider the following work flow, from a HashiCorp Vault guide:

$ cf create-space examplespace
$ cf target -s examplespace
$ cf create-service-broker vault-broker "${AUTH_USERNAME}" "${AUTH_PASSWORD}" "https://${BROKER_URL}" --space-scoped
$ cf marketplace
service           plans             description
hashicorp-vault   shared            HashiCorp Vault Service Broker
# ...
$ cf create-service hashicorp-vault shared my-vault

The above works fine. The problem comes up when we have an app in a different space that we want to consume the HashiCorp Vault API:

$ cf target -s myappspace
$ cf bind-service my-app my-vault

This last part fails.

Also, now that I'm in the space myappspace, cf marketplace does **notCC show the new service broker.

Now, we have someone on our team with org-admin permissions.

I figured that we could just register the new service broker at the org level, using enable-service-access subcommand:

https://docs.cloudfoundry.org/services/access-control.html#enable-access-to-service-plans

$ cf enable-service-access my-vault -o WebOrg

This failed as well, because, even though he had Admin permissions for the entire org, he got a permission denied error.

If we then go on to registering the service broker in the second space, myappspace, we get a

All three of these methods failed, but there has to be some way to make a service from one space available to the others, within an Org., if I have administrative permissions for that PCF Org.

How?

A similar (although more specific) type of this issue is documented in the following two github issues for PCF's cloud_controller_ng repository:

https://github.com/cloudfoundry/cloud_controller_ng/issues/935

https://github.com/cloudfoundry/cloud_controller_ng/issues/837

I've done the following research:

https://docs.cloudfoundry.org/services/managing-service-brokers.html#register-broker

https://docs.cloudfoundry.org/services/access-control.html

https://docs.cloudfoundry.org/services/access-control.html#enable-access-to-service-plans

https://starkandwayne.com/blog/register-your-own-service-broker-with-any-cloud-foundry/

(We ran variations of every command on this page.)

The most similar of the existing questions on Stack Overflow were these:

WebSphere Message Broker - how to send a PCF message

Need help on Registering App on PCF with Spring Cloud Data Flow which is also on PCF

They don't seem to have much to do with name spacing issues in the PCF marketplace, or with PCF permissions management.

Note: At first I wanted to post this to serverfault.com, because this has more to do with the infrastructure for an application, rather than just programming. But, while serverfault.com has no tag for Pivotal Cloud Foundry, Stack Overflow has a pivotal-cloud-foundry tag with 588 uses, already.


Viewing all articles
Browse latest Browse all 64

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>