@@ -139,13 +139,39 @@ in how service bindings are consumed by buildpacks. The v3 buildpacks expect
139
139
service bindings to follow the [ Kubernetes Service Binding specification] ( https://github.com/servicebinding/spec ) ,
140
140
which places service binding credentials on the filesystem. Cloud Foundry and
141
141
v2 buildpacks instead use environment variables for service binding
142
- credentials.
142
+ credentials. The majority of the v2 and v3 buildpacks do not consume service
143
+ bindings, so solving this problem will not block execution for most buildpacks.
144
+
145
+ At time of writing, there are two viable solutions to integrate the Paketo
146
+ buildpacks with CF Deployment: emulating Kubernetes Service Bindings in Diego
147
+ or updating the Paketo buildpacks to consume Cloud Foundry environment
148
+ variables.
149
+
150
+ #### Emulating Kubernetes Service Bindings
143
151
144
152
In order to securely place credentials on the filesystem, Diego will need the
145
153
ability to mount in-memory filesystems (e.g. ` tmpfs ` ) in application
146
154
containers. Once an in-memory filesystem is available, select ` VCAP_SERVICES `
147
155
environment variables can be translated into their Kubernetes Service Binding
148
- equivalents by the shim orchestrator, for consumption by the v3 buildpacks.
156
+ equivalents by the shim orchestrator, for consumption by the Paketo buildpacks.
157
+
158
+ #### Paketo Buildpacks Consume Environment Variables
159
+
160
+ There is work in progress for v3 buldpacks using the libcnb package to read
161
+ Cloud Foundry environment variables in addition to Kubernetes Service Bindings
162
+ (see [ buildpacks/libcnb #227 ] ( https://github.com/buildpacks/libcnb/pull/227 ) ).
163
+ Outside of the Java buildpacks, the Paketo buildpacks do not currently use
164
+ libcnb, so the remaining Paketo buildpacks that consume envionrment variables
165
+ will need to be updated to use libcnb or add equivalent logic. If the Paketo
166
+ buildpacks are updated, then no changes will be needed to the core Cloud
167
+ Foundry runtime.
168
+
169
+ #### Recommendation
170
+
171
+ Updating the Paketo buildpacks to consume Cloud Foundry environment variables
172
+ appears to be the easier option. However, given that there are at least two
173
+ viable options for buildpack service binding consumption, this RFC proposes
174
+ making the final decision at implementation time.
149
175
150
176
### Governance and Release
151
177
0 commit comments