Re: cannot replace the default buildpacks. Is it expected?


CF Runtime
 

When the cloud controller instances come up, they install any buildpacks
configured in the manifest. If you want a buildpack NOT to be replaced
automatically (because you've updated it yourself), you'll need to update
the 'locked' attribute of the buildpack.

http://apidocs.cloudfoundry.org/215/buildpacks/lock_or_unlock_a_buildpack.html

You will then need to unlock it before you are able to update it again.

Joseph & Dies
CF OSS Release Integration Team

On Tue, Aug 25, 2015 at 10:25 AM, Guangcai Wang <guangcai.wang(a)gmail.com>
wrote:

steps:
1. replace php_buildpack
2. stop all components by "nova stop"
3. start all components by "nova start"
4. check php_buildpack

I expected it was the version in step 1. However, step 4 got the default
php_buildpack.


On Tue, Aug 25, 2015 at 10:10 PM, Daniel Mikusa <dmikusa(a)pivotal.io>
wrote:

What do you mean by "after restarting cf"? How are you doing that?
There's a lot of components, which one or ones are you restarting? What
steps are you running?

Dan


On Tue, Aug 25, 2015 at 3:37 AM, Guangcai Wang <guangcai.wang(a)gmail.com>
wrote:

Hi all,

We tried to update the default buildpacks with a new version. However,
after restarting cf, the old version comes back. (See below) It seems all
the default buildpacks will be ensured to be installed with the default
version in the releases. Is this an expected behavior?

Default buildpacks (cf 212)
buildpack position enabled locked filename
java_buildpack 1 true false
java-buildpack-v3.0.zip
ruby_buildpack 2 true false
ruby_buildpack-cached-v1.4.2.zip
nodejs_buildpack 3 true false
nodejs_buildpack-cached-v1.3.4.zip
go_buildpack 4 true false
go_buildpack-cached-v1.3.1.zip
python_buildpack 5 true false
python_buildpack-cached-v1.3.5.zip
php_buildpack 6 true false
php_buildpack-cached-v3.2.2.zip

Updated php_buildpack:
buildpack position enabled locked filename
java_buildpack 1 true false
java-buildpack-v3.0.zip
ruby_buildpack 2 true false
ruby_buildpack-cached-v1.4.2.zip
nodejs_buildpack 3 true false
nodejs_buildpack-cached-v1.3.4.zip
go_buildpack 4 true false
go_buildpack-cached-v1.3.1.zip
python_buildpack 5 true false
python_buildpack-cached-v1.3.5.zip
php_buildpack 6 true false
php_buildpack-cached-v4.0.0.zip

However, after restarting all cf VMs, I got default php_buildpack
(php_buildpack-cached-v3.2.2.zip), not the updated version
(php_buildpack-cached-v4.0.0.zip)
buildpack position enabled locked filename
java_buildpack 1 true false
java-buildpack-v3.0.zip
ruby_buildpack 2 true false
ruby_buildpack-cached-v1.4.2.zip
nodejs_buildpack 3 true false
nodejs_buildpack-cached-v1.3.4.zip
go_buildpack 4 true false
go_buildpack-cached-v1.3.1.zip
python_buildpack 5 true false
python_buildpack-cached-v1.3.5.zip
php_buildpack 6 true false
php_buildpack-cached-v3.2.2.zip


I checked the cloud_controller_ng.log. From the log, all the default
buildpacks (defined in manifest) were installed every time when cf is
restarted,

{"timestamp":1440476666.1351752,"message":"Installing buildpack
java_buildpack","log_level":"info","source":"cc.background","data":{},"thread_id":70279906579220,"fiber_id":70279930973800,"process_id":1990,"file":"/var/vcap/data/packages/cloud_controller_ng/5d255d62301e734cfabb032a882d67f172318971.1-80d3ab4a46e7622a789a3ebc915713a0714ea06a/cloud_controller_ng/app/jobs/runtime/buildpack_installer.rb","lineno":15,"method":"perform"}
{"timestamp":1440476667.8460865,"message":"Installing buildpack
ruby_buildpack","log_level":"info","source":"cc.background","data":{},"thread_id":70279906579220,"fiber_id":70279930973800,"process_id":1990,"file":"/var/vcap/data/packages/cloud_controller_ng/5d255d62301e734cfabb032a882d67f172318971.1-80d3ab4a46e7622a789a3ebc915713a0714ea06a/cloud_controller_ng/app/jobs/runtime/buildpack_installer.rb","lineno":15,"method":"perform"}
{"timestamp":1440476670.4481,"message":"Installing buildpack
nodejs_buildpack","log_level":"info","source":"cc.background","data":{},"thread_id":70155356951340,"fiber_id":70155381353720,"process_id":1949,"file":"/var/vcap/data/packages/cloud_controller_ng/5d255d62301e734cfabb032a882d67f172318971.1-80d3ab4a46e7622a789a3ebc915713a0714ea06a/cloud_controller_ng/app/jobs/runtime/buildpack_installer.rb","lineno":15,"method":"perform"}
{"timestamp":1440476675.2146842,"message":"Installing buildpack
go_buildpack","log_level":"info","source":"cc.background","data":{},"thread_id":70155356951340,"fiber_id":70155381353720,"process_id":1949,"file":"/var/vcap/data/packages/cloud_controller_ng/5d255d62301e734cfabb032a882d67f172318971.1-80d3ab4a46e7622a789a3ebc915713a0714ea06a/cloud_controller_ng/app/jobs/runtime/buildpack_installer.rb","lineno":15,"method":"perform"}
{"timestamp":1440476688.722021,"message":"Installing buildpack
python_buildpack","log_level":"info","source":"cc.background","data":{},"thread_id":70279906579220,"fiber_id":70279930973800,"process_id":1990,"file":"/var/vcap/data/packages/cloud_controller_ng/5d255d62301e734cfabb032a882d67f172318971.1-80d3ab4a46e7622a789a3ebc915713a0714ea06a/cloud_controller_ng/app/jobs/runtime/buildpack_installer.rb","lineno":15,"method":"perform"}
{"timestamp":1440476696.635555,"message":"Installing buildpack
php_buildpack","log_level":"info","source":"cc.background","data":{},"thread_id":70155356951340,"fiber_id":70155381353720,"process_id":1949,"file":"/var/vcap/data/packages/cloud_controller_ng/5d255d62301e734cfabb032a882d67f172318971.1-80d3ab4a46e7622a789a3ebc915713a0714ea06a/cloud_controller_ng/app/jobs/runtime/buildpack_installer.rb","lineno":15,"method":"perform"}

Join cf-dev@lists.cloudfoundry.org to automatically receive all group messages.