Oops "Scripts in .profile.d/ should only be written by buildpacks. If you need to perform application specific initialization tasks at the time a dyno boots, you should use .profile scripts, which are guaranteed to run after the scripts in .profile.d/." https://devcenter.heroku.com/articles/buildpack-api#profile-d-scripts