[Taginfo-dev] Trouble running own instance on ubuntu 14.04

Jochen Topf jochen at remote.org
Tue Mar 17 13:55:30 UTC 2015


On Tue, Mar 17, 2015 at 07:55:32PM +0700, Stephan Knauss wrote:
> is anybody running an instance on Ubuntu 14.04 LTS?

Never tried it.

> I managed to install it by following the instructions on the wiki.
> 
> The ruby requirements are a bit unclear. What version of Ruby does it
> expect? Ubuntu comes with 1.9.3. This version is not compatible with the
> "mongrel" gem. Googling suggested to use "thin" instead.

Works with Ruby 1.9 for me. README says "Ruby (must be at least 1.9.1)". There
are often issues with Ruby Gems because you can either install them using the
"gem" tool or using the Debian/Ubuntu packages, which are sometimes outdated
etc. You have to find a combination that works for you.

> I don't know whether this is sort of drop-in replacement, but I found no
> reference in the source to "mongrel". So either it is obsolete or drop-in
> works.

The requirements can be a bit confusing. The details are: Taginfo uses the
"Sinatra" web framework which is built upon the "Rack" framework. You need
some kind of web server that can talk to Ruby projects using this "Rack"
interface. Examples for this are Mongrel and Apache using the mod_passenger
module. To call "taginfo.rb" directly, you don't need any of this,
Ruby/Sinatra will just use a builtin web server. But for production use,
you'll need a real web server.

> the r18n-core also turned out to be incompatible with sinatra. Google search
> results told me that the 1.9 branch of ruby is too old, so I switched to the
> 2.1 branch by adding a ppa.
> 
> with these changes I am now able to run my instance by calling "taginfo.rb"
> in the web folder.
> 
> Running with libapache2-mod-passenger unfortunately fails on me with an
> internal server error.
> 
> In the logfile is this callstack:
> [...]
> The faulty line is this:
>    def query_string;    @env[QUERY_STRING].to_s                  end
> 
> 
> I am quite illiteral with Ruby. Is the given line in the rack library
> correct? I would have expected a quoted string like in the surrounding
> lines.

That looks wrong to me. Should probably be
    @env['QUERY_STRING'].to_s

> But it really does not explain to me why it only fails in Apache.

I guess query strings are handled differently when using Apache. Try the
change above and if it fixes things, report upstream.

Jochen
-- 
Jochen Topf  jochen at remote.org  http://www.jochentopf.com/  +49-173-7019282



More information about the Taginfo-dev mailing list