Open zhongyi-zhang opened 6 years ago
It is for secure binding delivery. See overview https://github.com/cloudfoundry-incubator/credhub/blob/master/docs/secure-service-credentials.md and the example service broker for POC https://github.com/cloudfoundry/secure-credentials-broker. OSBA can support fetching Credhub connection info from the environment variables like these:
CREDHUB_SERVER: https://credhub.service.cf.internal:8844 CREDHUB_CLIENT: secure-credentials-broker CREDHUB_SECRET: my-secret
Then OSBA stores credentials to Credhub and returns Credhub ref uri to the platform: https://github.com/Azure/open-service-broker-azure/blob/master/pkg/api/bind.go#L285. Of course unbinding should also delete the credentials from Credhub before deleting the binding from broker store: https://github.com/Azure/open-service-broker-azure/blob/master/pkg/api/unbind.go#L98.
Though Credhub is designed in CF world, the feature in OSBA won't depend on CF. Someday Credhub published a K8s deployment, K8s users can also benefit from it.
We should probably have an explicit flag to enable credhub integration as well?
Yes, I agree. It helps OSBA to determine whether it fetches Credhub info from env vars.
It is for secure binding delivery. See overview https://github.com/cloudfoundry-incubator/credhub/blob/master/docs/secure-service-credentials.md and the example service broker for POC https://github.com/cloudfoundry/secure-credentials-broker. OSBA can support fetching Credhub connection info from the environment variables like these:
Then OSBA stores credentials to Credhub and returns Credhub ref uri to the platform: https://github.com/Azure/open-service-broker-azure/blob/master/pkg/api/bind.go#L285. Of course unbinding should also delete the credentials from Credhub before deleting the binding from broker store: https://github.com/Azure/open-service-broker-azure/blob/master/pkg/api/unbind.go#L98.
Though Credhub is designed in CF world, the feature in OSBA won't depend on CF. Someday Credhub published a K8s deployment, K8s users can also benefit from it.