Re: Question on Custom script working as part of PHP buildpack
On Mon, Sep 14, 2015 at 8:25 PM, Amishi Shah (amishish) <amishish(a)cisco.com>
Hi team,The easiest way to do this is with a `.profile.d` script. Any script you
put into the `.profile.d` folder (in the root of your application) will be
executed prior to your application starting in the runtime environment.
Just bear in mind that these scripts must run quick as they need to finish
before your application will start and your application plus the
`.profile.d` scripts all need to start within the health check timeout.
The requirement is the Web Policy Agent should have OpenJDK configuredThat's tricky since the PHP is not going to install that for you. You
might try the multi-buildpack, configured to run the Java & PHP build packs.
Could anyone please share any thoughts on how I can achieve thisI prefer a `.profile.d` script when possible. It's lightweight and is a
shell script, so it's pretty easy to make it do what you want. If you need
to do something at staging time, then I would suggest a build pack
You could certainly write your own build pack or fork one of the existing
ones, but that's a lot more work and puts a maintenance burden on you going
I tried it as part of the custom extension, but seems like it is notCan you be more specific? Both in regards to what you tried and in regards
to what didn't work.