A buildpack designed to pull environment variables out of VCAP_SERVICES
when using a user-provided service on Cloud Foundry.
This buildpack should be used as part of a multi-buildpack setup.
If an app has user-provided services, Cloud Foundry provides information about those services in an environment variable called VCAP_SERVICES
. It's JSON, and you can read more about it in the CF docs. This buildpack pulls out the name
and credentials
values, and provides them as separate environment variables in the format NAME_CREDENTIAL_KEY=credential_value
. Note that hyphens in name
will cause errors, so the buildpack converts them to underscores.
By default, the buildpack converts variable keys to uppercase. To leave them as-is, set UPPERCASE: false
in the manifest.
To remove the name
from the variable, set SHORTEN_VCAP: true
in the manifest.
If you are setting your own buildpacks, be aware that you are taking on the responsibility for the security of those buildpacks in your application. You should check them to be aware of what you're running. To see which buildpacks are supported and maintained on your Cloud Foundry instance, you can run cf buildpacks
.
See CONTRIBUTING for additional information.
- Main branch:
release
- Development branch:
develop
This project is in the worldwide public domain. As stated in CONTRIBUTING:
This project is in the public domain within the United States, and copyright and related rights in the work worldwide are waived through the CC0 1.0 Universal public domain dedication.
All contributions to this project will be released under the CC0 dedication. By submitting a pull request, you are agreeing to comply with this waiver of copyright interest.