From owner-freebsd-ports@FreeBSD.ORG Tue Jun 11 19:11:54 2013 Return-Path: Delivered-To: freebsd-ports@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id CFA841BF; Tue, 11 Jun 2013 19:11:54 +0000 (UTC) (envelope-from paul@gromit.dlib.vt.edu) Received: from lennier.cc.vt.edu (lennier.cc.vt.edu [198.82.162.213]) by mx1.freebsd.org (Postfix) with ESMTP id 8A0561749; Tue, 11 Jun 2013 19:11:54 +0000 (UTC) Received: from steiner.cc.vt.edu (steiner.cc.vt.edu [198.82.163.51]) by lennier.cc.vt.edu (8.13.8/8.13.8) with ESMTP id r5BJBNeJ026165; Tue, 11 Jun 2013 15:11:23 -0400 Received: from auth3.smtp.vt.edu (EHLO auth3.smtp.vt.edu) ([198.82.161.152]) by steiner.cc.vt.edu (MOS 4.3.3-GA FastPath queued) with ESMTP id XXW70060; Tue, 11 Jun 2013 15:11:23 -0400 (EDT) Received: from pmather.tower.lib.vt.edu (pmather.tower.lib.vt.edu [128.173.51.28]) (authenticated bits=0) by auth3.smtp.vt.edu (8.13.8/8.13.8) with ESMTP id r5BJBNdb021494 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Tue, 11 Jun 2013 15:11:23 -0400 Subject: Re: www/rubygem-passenger now requires bash? Mime-Version: 1.0 (Mac OS X Mail 6.5 \(1508\)) Content-Type: text/plain; charset=windows-1252 From: Paul Mather X-Priority: 3 (Normal) In-Reply-To: <71c953f9ebbd220a72258fb1dbf322f8.squirrel@mouf.net> Date: Tue, 11 Jun 2013 15:11:22 -0400 Content-Transfer-Encoding: quoted-printable Message-Id: References: <71c953f9ebbd220a72258fb1dbf322f8.squirrel@mouf.net> To: "Steve Wills" X-Mailer: Apple Mail (2.1508) X-Mirapoint-Received-SPF: 198.82.161.152 auth3.smtp.vt.edu paul@gromit.dlib.vt.edu 5 none X-Junkmail-Status: score=10/50, host=steiner.cc.vt.edu X-Junkmail-Signature-Raw: score=unknown, refid=str=0001.0A02020A.51B7765B.00FD, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0, ip=0.0.0.0, so=2011-07-25 19:15:43, dmn=2013-04-19 10:07:54, mode=single engine X-Junkmail-IWF: false Cc: freebsd-ports@FreeBSD.org X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Jun 2013 19:11:54 -0000 On Jun 11, 2013, at 10:04 AM, "Steve Wills" 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. >>=20 >> 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. >>=20 >> 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? >>=20 >> 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. >=20 > 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_e= nvironment_variables): =3D=3D=3D=3D=3D [[...]] 14.3.5. Phusion Passenger-served apps You can pass environment variables to Phusion Passenger-served apps = through various methods: [[...]] =95 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. [[...]] =3D=3D=3D=3D=3D 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/ApplicationPo= ol2, there appear to be hardcoded references to "bash" in the code. Is = this a creeping Linuxism? Cheers, Paul.