Results 1 to 5 of 5

Thread: Redmine installation error - invalid Ruby on Rails application root

  1. #1
    Join Date
    Apr 2007
    Beans
    180
    Distro
    Ubuntu 9.04 Jaunty Jackalope

    Redmine installation error - invalid Ruby on Rails application root

    Hello,

    I am trying to install redmine onto 10.04, as detailed here

    I used the passenger method, and all seemed to go very smoothly during setup.

    Unfortunately when I goto the redmine page I get a Passenger page which says:

    Code:
    Cannot start Ruby on Rails application
    The directory "/var/www" does not appear to be a valid Ruby on Rails application root.
    Apache setup isnt my strong point so any help gratefully received.

    Heres my /etc/apache2/sites-available/default:

    Code:
    <VirtualHost *:80>
            ServerAdmin webmaster@localhost
    
            DocumentRoot /var/www
            <Directory />
                    Options FollowSymLinks
                    AllowOverride None
            </Directory>
            <Directory /var/www/>
                    Options Indexes FollowSymLinks MultiViews
                    AllowOverride None
                    Order allow,deny
                    allow from all
            </Directory>
    
            <Directory /var/www/redmine/>
                    RailsBaseURI /redmine
                    PassengerResolveSymlinksInDocumentRoot on
            </Directory>
    
            ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
            <Directory "/usr/lib/cgi-bin">
                    AllowOverride None
                    Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
                    Order allow,deny
                    Allow from all
            </Directory>
    
            ErrorLog /var/log/apache2/error.log
    
            # Possible values include: debug, info, notice, warn, error, crit,
            # alert, emerg.
            LogLevel warn
    
            CustomLog /var/log/apache2/access.log combined
    
        Alias /doc/ "/usr/share/doc/"
        <Directory "/usr/share/doc/">
            Options Indexes MultiViews FollowSymLinks
            AllowOverride None
            Order deny,allow
            Deny from all
            Allow from 127.0.0.0/255.0.0.0 ::1/128
        </Directory>
    
    </VirtualHost>
    Thanks

    Si

    MMO currently in development - We are looking for C++ and Lua programmers

  2. #2
    Join Date
    Apr 2005
    Beans
    24

    Re: Redmine installation error - invalid Ruby on Rails application root

    I'm having the same issues using the same website (among others) as reference. The documentation here doesn't appear to be current/complete. If someone has gotten this to work, can you help a brotha out?

  3. #3
    Join Date
    Nov 2010
    Beans
    6

    Re: Redmine installation error - invalid Ruby on Rails application root

    having the same issue here - receiving exactly the same error.

    To confirm,

    do you change the permissions of passenger.conf to www-data?

    also, is my passenger.conf correct:


    HTML Code:
    <IfModule mod_passenger.c>
    PassengerDefaultUser www-data
     PassengerRoot /usr
      PassengerRuby /usr/bin/ruby
    </IfModule>

  4. #4
    Join Date
    Nov 2009
    Location
    Mdeo, Uy
    Beans
    27
    Distro
    Kubuntu

    Re: Redmine installation error - invalid Ruby on Rails application root

    Hi!
    I'm trying to get this working on Ubuntu 11.04. And I'm also having troubles with passenger. But I'm not having the same error as the other..

    the error
    Code:
    service apache2 restart
    Syntax error on line 6 of /etc/apache2/sites-enabled/redmine:
    Invalid command 'PassengerDefaultUser', perhaps misspelled or defined by a module not included in the server configuration
    Action 'configtest' failed.
    The Apache error log may have more information.
       ...fail!
    the apache log

    Code:
    [Fri Sep 30 10:42:16 2011] [error] *** Passenger could not be initialized because of this error: The Passenger spawn server script, '/usr/lib/ruby/gems/1.8/gems/passenger-3.0.9/lib/phusion_passenger/passenger-spawn-server', does not exist. Please check whether the 'PassengerRoot' option is specified correctly.
    vi /etc/apache2/mods-available/passenger.conf

    Code:
    <IfModule mod_passenger.c>
      PassengerRoot /usr/lib/ruby/gems/1.8/gems/passenger-3.0.9
      PassengerRuby /usr/bin/ruby1.8
      PassengerDefaultUser www-data
    
    </IfModule>

    vi /etc/apache2/apache2.conf (at the bottom of the con file)

    Code:
    Include /etc/apache2/mods-available/passenger.conf

    vi /etc/apache2/sites-available/redmine (instead of default)

    Code:
    <VirtualHost *:80>
        ServerName redmine
    
        DocumentRoot /var/www/redmine/public
    
        PassengerDefaultUser www-data
        RailsEnv production
        RailsBaseURI /redmine
        SetEnv X_DEBIAN_SITEID "default"
    
        <Directory /var/www/redmine/public>
            Order allow,deny
            Allow from all
        </Directory>
    </VirtualHost>
    I used this manual http://www.x2on.de/2011/04/23/tutori...-ubuntu-11-04/ It has details but you can follow it.

    Running the test works.
    you go to cd /var/www/redmine
    and by doing

    Code:
    ruby script/server webrick -e production
    In the browser I put http://redmine:3000 and works
    Hopefully someone can lend us a hand.

  5. #5
    Join Date
    Nov 2009
    Location
    Mdeo, Uy
    Beans
    27
    Distro
    Kubuntu

    Re: Redmine installation error - invalid Ruby on Rails application root

    @sipickles It's looks like your sites-available is wrong.. look at mine or look the example I used to create mine... try that and show us your progress. Let's try help each other ¿ok?
    Last edited by maniat1k; October 6th, 2011 at 02:49 PM. Reason: minor edition

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •