I've set the JAVA_HOME variable
heroku config:add JAVA_HOME=/usr/lib/jvm/java-6-openjdk
checked that heroku config shows this variable with value, then pushed:
git push heroku master
and still get
JAVA_HOME is not set
error while bundler is installing RJB gem.
I can successfully deploy the same source to another Heroku application, and all environment variables are the same.
What is wrong?
I had the same question, and in case anyone else wants to know, this is what Heroku told me:
By default the config variables aren't made available when the application is compiled - only at runtime.
You can change this by making sure you have the latest heroku gem install, then enable the user_env_compile lab flag
$ heroku labs:enable user-env-compile
this will make JAVA_HOME available when the gem installs, hopefully getting you past this issue.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With