Last Updated: February 25, 2016
· xijo

Get puma jungle scripts working with rvm

Recently I had some trouble getting the puma webserver to run with the following setup:

  • ruby 1.9.3-p374
  • rvm 1.18.0
  • nginx 1.2.4
  • puma 1.6.3

I wanted to use the jungle scripts ( to run several instances. Unfortunately everything looked good but the puma startup process was silently failing. It turned out, that the crash happened because rvm could not be found and loaded.

What I had to do was loading the rvm function by hand

source ~/.bash_profile

during the jungle startup and in order to use the source command I had to change the jungle script to behave as bash script


#! /bin/sh


#! /bin/bash

The whole setup is explained by Tommy Chheng ( and I added a gem for convenient capistrano integration (

1 Response
Add your response

Why not just create an RVM wrapper script:

rvm wrapper ruby-1.9.3-p374 p193 puma

Would create a script p193_puma which would use the correct rvm ruby to launch puma.

over 1 year ago ·