0

I recently installed Redmine on an Ubuntu 12.04 + Apache server, and it is working fine.

However, my phpmyadmin site is giving me a bizarre error when I go to https://phpmyadmin.example.com:

cannot start ruby on rails application

Here is the VirtualHost configuration bit for phpmyadmin:

<VirtualHost *:443>
    ServerName phpmyadmin.example.com
    DocumentRoot /usr/share/phpmyadmin

    SSLEngine on
    SSLCertificateFile    /etc/ssl/certs/ssl-cert-snakeoil.pem
    SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key

    <Directory /usr/share/phpmyadmin>
            Options FollowSymLinks
            DirectoryIndex index.php

            <IfModule mod_php5.c>
                    AddType application/x-httpd-php .php

                    php_flag magic_quotes_gpc Off
                    php_flag track_vars On
                    php_flag register_globals Off
                    php_admin_flag allow_url_fopen Off
                    php_value include_path .
                    php_admin_value upload_tmp_dir /var/lib/phpmyadmin/tmp
                    php_admin_value open_basedir /usr/share/phpmyadmin/:/etc/phpmyadmin/:/var/lib/phpmyadmin/
            </IfModule>


    </Directory>
</VirtualHost>

I think it may have something to do with my recent installation of Redmine (a ruby on rails application), but I have been unable to find anything preventing phpmyadmin to load like a regular website.

I find it particularly odd that my default apache "It works!" site is still working at https://example.com.

Why is phpmyadmin being treated like a ruby on rails app?


UPDATE I think I figured out why phpmyadmin is being treated like a ruby on rails app, but I still have not figured out how to fix it.

I have in /etc/apache2/mods-enabled a passenger.conf file which contains:

<IfModule mod_passenger.c>
    PassengerRoot /usr
    PassengerRuby /usr/bin/ruby
</IfModule>

I tried, modifying the value for PassengerRoot to my Redmine application, /usr/share/redmine/public. That fixes phpmyadmin, but unfortunately, when I try to access my Redmine app, I get a 403 Forbidden error.

Any suggestions on how to fix this?

1 Answer 1

1

You'll need to disable Passenger for the VirtualHosts that don't use it.

Inside the phpmyadmin.example.com block add:

PassengerEnabled off

to prevent it from trying to take over all of the requests.

1
  • Geez, I'm pulling my hair out for an hour moving directories around and modifying Apache configurations, and this one line is all I needed. Thanks a million Nov 13, 2012 at 1:00

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .