Project

General

Profile

Images not loading in Redmine

Added by Matthias Haamann over 12 years ago

Hi everyone

At the moment my redmine installation works. But images does not load (editor, buttons, links)

I suspect that the error is in my .htacces so here it is:
Is anyone able to help me?

Thx in advance!

# General Apache options
<IfModule mod_fastcgi.c>
    AddHandler fastcgi-script .fcgi
</IfModule>
<IfModule mod_fcgid.c>
    AddHandler fcgid-script .fcgi
</IfModule>
<IfModule mod_cgi.c>
    AddHandler cgi-script .cgi
</IfModule>
Options +FollowSymLinks +ExecCGI

# If you don't want Rails to look in certain directories,
# use the following rewrite rules so that Apache won't rewrite certain requests
# 
# Example:
#   RewriteCond %{REQUEST_URI} ^/notrails.*
#   RewriteRule .* - [L]

# Redirect all requests not available on the filesystem to Rails
# By default the cgi dispatcher is used which is very slow
# 
# For better performance replace the dispatcher with the fastcgi one
#
# Example:
#   RewriteRule ^(.*)$ dispatch.fcgi [QSA,L]
RewriteEngine On

# If your Rails application is accessed via an Alias directive,
# then you MUST also set the RewriteBase in this htaccess file.
#
# Example:
#   Alias /myrailsapp /path/to/myrailsapp/public
#   RewriteBase /myrailsapp

RewriteRule ^$ index.html [QSA]
RewriteRule ^([^.]+)$ $1.html [QSA]
RewriteCond %{REQUEST_FILENAME} !-f
<IfModule mod_fastcgi.c>
    RewriteRule ^(.*)$ dispatch.fcgi [QSA,L]
</IfModule>
<IfModule mod_fcgid.c>
    RewriteRule ^(.*)$ dispatch.fcgi [QSA,L]
</IfModule>
<IfModule mod_cgi.c>
    RewriteRule ^(.*)$ dispatch.cgi [QSA,L]
</IfModule>

# In case Rails experiences terminal errors
# Instead of displaying this message you can supply a file here which will be rendered instead
# 
# Example:
#   ErrorDocument 500 /500.html

ErrorDocument 500 "<h2>Application error</h2>Rails application failed to start properly" 

Replies (8)

RE: Images not loading in Redmine - Added by Mischa The Evil over 12 years ago

What kind of deployment are you talking about? Sub-URI or dedicated root of virtual host? What's in your logs? See also Submissions...

RE: Images not loading in Redmine - Added by Matthias Haamann over 12 years ago

Thx for the response.
I guess it is a dedicated root of virtual.

Found the logs. They were 800 mb!!! Could not open them in ssh so i downloaded them and had to open them with wordpad that kept crashing. Only managed to get a screenshot of part of the log. But seemed to me like it was the same error happening all the time.

See attached image for the logs

Rails: 2.3.8
Ruby: 1.8.6
Redmine: 1.0.0

RE: Images not loading in Redmine - Added by Mischa The Evil over 12 years ago

What's the configuration of your deployment? Passenger? Mongrel? Apache Proxy? fcgid? FastCGI?

Note: I hope this instance isn't publicly reachable since 1.0.0 is heavily outdated and unsupported...

RE: Images not loading in Redmine - Added by Matthias Haamann over 12 years ago

I am not sure how to check this. If i load a phpinfo page on a php isntallation that is installed on the same virtual server. I can find Passenger written different places. But not sure if this is used by Redmine?

RE: Images not loading in Redmine - Added by Mischa The Evil over 12 years ago

Matthias Haamann wrote:

[...] If i load a phpinfo page on a php isntallation that is installed on the same virtual server. I can find Passenger written different places. But not sure if this is used by Redmine?

phpinfo is a PHP function which returns "a large amount of information about the current state of PHP. This includes information about PHP compilation options and extensions, the PHP version, server information and environment (if compiled as a module), the PHP environment, OS version information, paths, master and local values of configuration options, HTTP headers, and the PHP License".
As you can see it doesn't tell anything about the Ruby on Rails/Ruby stack you are running.

Let's start with the beginning: how did you install that Redmine instance? According to which instructions?

RE: Images not loading in Redmine - Added by Matthias Haamann over 12 years ago

I am quite sure that i it is using Passenger. I remember installing this, when i installed redmine.
And i am running Redmine 0.9.4.stable (MySQL). Should properly update this soon.

Used different tutorials, since none of them really worked :(

redmine.org/projects/redmine/wiki/HowTo_Install_Redmine_on_Debian_with_Ruby-on-Rails_and_Apache2-Passenger
and this one
redmine.org/projects/redmine/wiki/HowTo_install_Redmine_on_CentOS_5

Thx in advance!

RE: Images not loading in Redmine - Added by Matthias Haamann over 12 years ago

Tried to use fcgi/cgi from the second tutorial but that did not work. So used passenger from the other tutorial.

RE: Images not loading in Redmine - Added by Mischa The Evil over 12 years ago

Can you post your webserver configuration?

    (1-8/8)