Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8533589
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T09:59:47+00:00 2026-06-11T09:59:47+00:00

I’m cloning this repo: https://github.com/freeformz/sinatra-jruby-heroku.git to try and use JRuby/Sinatra on Heroku’s Cedar stack.

  • 0

I’m cloning this repo:

https://github.com/freeformz/sinatra-jruby-heroku.git

to try and use JRuby/Sinatra on Heroku’s Cedar stack. I follow the included instructions and everything runs great locally with a ‘foreman start’. I then git push to Heroku and it initially loads up fine but when I try to access the site I get an error in the logs:

jruby: No such file or directory -- trinidad (LoadError)

So it seems jruby can’t find the “/app/.gems/bin/trinidad” file. I initially thought it wasn’t there because .gems/ is in the .gitignore file, but I’m pretty sure Heroku creates that server side on a git push.

$APPDIR/.gems is added to the PATH so Heroku should be able to see the trinidad script. I’ve also tried to change the Procfile around to play with the path like:

web: script/jruby -S bin/trinidad -p $PORT

But no dice. Has anyone had any success deploying anything JRuby to Heroku cedar?

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T09:59:49+00:00Added an answer on June 11, 2026 at 9:59 am

    As of Bundler 1.2 you are now able to specify the Ruby implementation and version in your Gemfile. The nice thing about this is that Heroku will understand these settings and prepare the your Heroku application for your environment.

    Take this Gemfile for example:

    source "https://rubygems.org"
    
    ruby "1.9.3"
    
    gem "rails"
    gem "puma"
    

    What’s cool about this is that by default Celadon Cedar uses Ruby 1.9.2. However, when you specify ruby "1.9.3" in the Gemfile it’ll actually compile Ruby 1.9.3 for your Heroku environment.

    Now, if you want to add a different Ruby implementation to your Heroku environment, you can do so like this:

    source "https://rubygems.org"
    
    ruby "1.9.3", :engine => "jruby", :engine_version => "1.7.0.preview1"
    
    gem "rails"
    gem "puma"
    

    Now it’ll install and use JRuby 1.7.0.preview1 in Ruby 1.9 mode for your Heroku application upon deployment. It’ll also even define the proper JVM options in the Heroku environment variables.

    Best of all is that this comes with the official Heroku buildpack, so there is no need to switch to a 3rd party buildpack to get the JRuby/JVM going on Heroku. Although I haven’t gotten it to work yet, this should also work with Rubinius, but I believe it’s currently bugged. Either that, or I’m doing it wrong.

    This is in my opinion an awesome and scalable feature. Just define the Ruby implementation/version/mode you’re using in your Gemfile along with your other dependencies and Heroku will ensure the environment is prepared.


    Now, with all this in place, Heroku should create binstubs (through Bundler) in APP_ROOT/bin so what you can do is for example this:

    web: bin/trinidad -p $PORT -e $RACK_ENV --threaded
    

    Just don’t use bundle exec since JRuby doesn’t play nice with that. Always use the binstubs provided by Bundler which are always located in APP_ROOT/bin on Heroku.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
link Im having trouble converting the html entites into html characters, (&# 8217;) i
For some reason, after submitting a string like this Jack’s Spindle from a text
I am trying to understand how to use SyndicationItem to display feed which is
this is what i have right now Drawing an RSS feed into the php,
I have this code to decode numeric html entities to the UTF8 equivalent character.
I want use html5's new tag to play a wav file (currently only supported
I have this code: - (void)parser:(NSXMLParser *)parser foundCDATA:(NSData *)CDATABlock { NSString *someString = [[NSString
This could be a duplicate question, but I have no idea what search terms

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.