www/rubygem-passenger now requires bash?

Paul Mather paul at gromit.dlib.vt.edu
Tue Jun 11 19:11:54 UTC 2013

On Jun 11, 2013, at 10:04 AM, "Steve Wills" <swills at FreeBSD.org> wrote:

>> I'm running FreeBSD/amd64 8-STABLE (r250276) and, yesterday, updated
>> www/rubygem-passenger from 3.0.19 to 4.0.5 via portmaster.  Although the
>> port upgraded without error, the resultant Passenger no longer works: it
>> complains it can't find "bash" and Rails apps won't spawn.
>> I don't have shells/bash installed, and didn't need to with version 3.0.19
>> of the www/rubygem-passenger port.  The shells/bash port isn't listed as a
>> runtime dependency for www/rubygem-passenger in its Makefile, either.
>> If I install shells/bash and also put a symlink from /usr/bin/bash to
>> /usr/local/bin/bash then Passenger will run once again.  I don't like this
>> solution, though.  Does anyone know of a way of running the Passenger
>> 4.0.5 port without needing bash?
>> I've included at the end a snippet from httpd-error.log showing the
>> behaviour of the new Passenger 4.0.5 prior to the workaround I put in
>> place mentioned in the preceding paragraph.
> I think it only calls bash like that when it crashes, so that it can
> generate a crash report of some kind and possibly submit it somewhere.

I just found this entry in Appendix D of the Passenger documentation for Apache (http://www.modrails.com/documentation/Users%20guide%20Apache.html#about_environment_variables):

14.3.5. Phusion Passenger-served apps

You can pass environment variables to Phusion Passenger-served apps through various methods:
	• Through your bashrc. Starting from version 4.0, Phusion Passenger 4.0 spawns applications through bash and inherit all bash environment variables. Phusion Passenger Standalone tends to be started from the shell and thus inherits all environment variables set by the shell.

So, it seems that Passenger 4.x explicitly assumes bash is the shell when spawning Rails apps via the Apache module.

In the installed version of Passenger 4.0.5, under /usr/local/lib/ruby/gems/1.9/gems/passenger-4.0.5/ext/common/ApplicationPool2, there appear to be hardcoded references to "bash" in the code.  Is this a creeping Linuxism?



More information about the freebsd-ports mailing list