You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@whimsical.apache.org by Sam Ruby <ru...@intertwingly.net> on 2016/03/18 19:18:54 UTC
Re: [whimsy.git] [1/2] Commit 395987f: Don't insist on Ruby 2.3.0
This doesn't work, as you can see here:
https://whimsy.apache.org/status/passenger
The version of Ruby used must match the one specified in the apache config
(/etc/apache2/mods-enabled/passenger.conf on whimsy-vm2). This is
important in both places: in the call to Open3.capture3, and in the
call go Gem.bin_path.
- Sam Ruby
On Fri, Mar 18, 2016 at 12:53 PM, Sebastian Bazley <se...@apache.org> wrote:
> Commit 395987f1782be77841275deaad5188e5d0925071:
> Don't insist on Ruby 2.3.0
>
> diff --git a/www/status/passenger.cgi b/www/status/passenger.cgi
> index 4ccefea..ecca2b7 100755
> --- a/www/status/passenger.cgi
> +++ b/www/status/passenger.cgi
> @@ -1,4 +1,4 @@
> -#!/usr/local/bin/ruby2.3.0
> +#!/usr/bin/env ruby
>
> require 'bundler/setup'
>
> @@ -15,8 +15,7 @@ unless user
> print "WWW-Authenticate: Basic realm=\"ASF Members and Officers\"\r\n\r\n"
> exit
> end
> -
> -output, error, status = Open3.capture3 '/usr/local/bin/ruby2.3.0',
> +output, error, status = Open3.capture3 'ruby',
> Gem.bin_path('passenger', 'passenger-status')
>
> _html do
Re: [whimsy.git] [1/2] Commit 395987f: Don't insist on Ruby 2.3.0
Posted by sebb <se...@gmail.com>.
On 18 March 2016 at 18:18, Sam Ruby <ru...@intertwingly.net> wrote:
> This doesn't work, as you can see here:
>
> https://whimsy.apache.org/status/passenger
Rats; it worked for me.
> The version of Ruby used must match the one specified in the apache config
> (/etc/apache2/mods-enabled/passenger.conf on whimsy-vm2). This is
> important in both places: in the call to Open3.capture3, and in the
> call go Gem.bin_path.
This is going to make it potentially tricky to run locally.
I fixed my system by linking ruby2.3.0 to ruby, but that's a bit messy.
Also when ruby is updated, the script will have to be changed.
Maybe there needs to be a fixed executable name (e.g. ruby4passenger)
which is used everywhere?
That would only require updating a single link.
> - Sam Ruby
>
> On Fri, Mar 18, 2016 at 12:53 PM, Sebastian Bazley <se...@apache.org> wrote:
>> Commit 395987f1782be77841275deaad5188e5d0925071:
>> Don't insist on Ruby 2.3.0
>>
>> diff --git a/www/status/passenger.cgi b/www/status/passenger.cgi
>> index 4ccefea..ecca2b7 100755
>> --- a/www/status/passenger.cgi
>> +++ b/www/status/passenger.cgi
>> @@ -1,4 +1,4 @@
>> -#!/usr/local/bin/ruby2.3.0
>> +#!/usr/bin/env ruby
>>
>> require 'bundler/setup'
>>
>> @@ -15,8 +15,7 @@ unless user
>> print "WWW-Authenticate: Basic realm=\"ASF Members and Officers\"\r\n\r\n"
>> exit
>> end
>> -
>> -output, error, status = Open3.capture3 '/usr/local/bin/ruby2.3.0',
>> +output, error, status = Open3.capture3 'ruby',
>> Gem.bin_path('passenger', 'passenger-status')
>>
>> _html do