Project

General

Profile

Redmine on BlueHost HELP!

Added by João Pereira over 13 years ago

Hi, i'm using bluehost for some time, and I need an on-line project management, and redmine seems to be the best!

But I have some problems... After create mySQL database, giving all permissions to my username and set a subdomain to ~/public_html/joaopereira/redmine/public/, I do this:

I install redmine this way:
$ wget http://rubyforge.org/frs/download.php/72627/redmine-1.0.2.tar.gz
$ tar zxvf redmine-1.0.2.tar.gz
$ rm redmine-1.0.2.tar.gz
$ mv redmine-1.0.2/* .
$ rm -rf redmine-1.0.2/

$ echo production: > ~/public_html/joaopereira/redmine/config/database.yml
$ echo ' adapter: mysql' >> ~/public_html/joaopereira/redmine/config/database.yml
$ echo ' database: MY_DB_NAME '>> ~/public_html/joaopereira/redmine/config/database.yml
$ echo ' host: localhost' >> ~/public_html/joaopereira/redmine/config/database.yml
$ echo ' username: MY_DB_USERNAME '>> ~/public_html/joaopereira/redmine/config/database.yml
$ echo ' password: MY_DB_PASSWORD '>> ~/public_html/joaopereira/redmine/config/database.yml
$ echo ' encoding: utf8' >> ~/public_html/joaopereira/redmine/config/database.yml

$ mv ~/public_html/joaopereira/redmine/public/dispatch.fcgi.example ~/public_html/joaopereira/redmine/public/dispatch.fcgi
$ chmod 700 ~/public_html/joaopereira/redmine/public/dispatch.fcgi
$ chmod 700 ~/public_html/joaopereira/redmine/tmp
$ chmod 700 ~/public_html/joaopereira/redmine/log

$ sed 's|# ENV\[|ENV\[|g' config/environment.rb > TMPFILE && mv TMPFILE config/environment.rb
$ sed 's|\:domain => "somenet.foo",|\:domain => "MY_DOMAIN.com",|g' config/environment.rb > TMPFILE && mv TMPFILE config/environment.rb
$ sed 's|\:user_name => "",|\:user_name => "MY_MAIL_USER@MY_DOMAIN.com",|g' config/environment.rb > TMPFILE && mv TMPFILE config/environment.rb
$ sed 's|\:password => "redmine",|\:password => "MY_MAIL_PASSWORD",|g' config/environment.rb > TMPFILE && mv TMPFILE config/environment.rb

$ rake generate_session_store
$ rake db:migrate RAILS_ENV="production"
$ rake redmine:load_default_data RAILS_ENV="production"

And I get all things installed with no errors, but when I go to my browser and try to access redmine it gives me this error:

*Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.
...*

And next I make a refresh, and I get this in this refresh page and all the others I do next:

*Application error

Rails application failed to start properly*

I tried other solutions like this:

$ ruby script/server -e production
=> Booting Mongrel
=> Rails 2.3.5 application starting on http://0.0.0.0:3000
./script/../config/../vendor/rails/railties/lib/rails/gem_dependency.rb:119:Warning: Gem::Dependency#version_requirements is deprecated and will be removed on or after August 2010. Use #requirement
=> Call with -d to detach
=> Ctrl-C to shutdown server

and now I open a new console tab and after typing $ lynx http://localhost:3000/ I can see my redmine page OK

$ gem list --local
  • LOCAL GEMS ***
    ...
    mysql (2.8.1)
    passenger (2.2.15)
    rack (1.2.1, 1.0.1)
    rack-mount (0.6.13)
    rack-test (0.5.6)
    rails (2.3.5)
    railties (3.0.0)
    rake (0.8.7)
    ...

$ rails --version
Rails 2.3.8

$ ruby --version
ruby 1.8.7 (2009-06-12 patchlevel 174) [x86_64-linux]

*$ ./public/dispatch.fcgi *
./public/../config/../vendor/rails/railties/lib/rails/gem_dependency.rb:119:Warning: Gem::Dependency#version_requirements is deprecated and will be removed on or after August 2010. Use #requirement


Replies (8)

RE: Redmine on BlueHost HELP! - Added by Felix Schäfer over 13 years ago

What are you trying to use to serve redmine? I see mention of both passenger and fcgi in your listings, you can't use both. In fact, (f)cgi support is not something that is actively supported in rails, you're probably better of using something else, passenger works really good for example.

You might also want to post the contents of the file you have changed, or explain what changes you have made, as not everyone is proficient in sed, and even those people would probably have a hard time keeping a 60 lines file in mind while applying several sed commands over it.

RE: Redmine on BlueHost HELP! - Added by João Pereira over 13 years ago

hi, I follow the instructions of gttools on how to install redmine on bluehost:
[[http://bugtracker.gttools.com/public/wiki/bluehost/Redmine]]

I dont know how to configure/enable/disable CGI or FCGI or Passenger.

I read that Passenger is better, but I dont know how to do it...

I also tried and installed a earlier version of redmine(0.8.0) with this commands above and it works fine, but with recent versions I have these problems...

RE: Redmine on BlueHost HELP! - Added by Felix Schäfer over 13 years ago

Still not helpful. Please post the contents of config/database.yml and config/environment.rb (minus sensitive data, of course), and have a look at your redmine (log/production.log) and apache logs for errors and post them here too.

Regarding not knowing "how to do" passenger: there's plenty tutorials around, maybe not bluehost specific, but you should be able to work it out.

RE: Redmine on BlueHost HELP! - Added by João Pereira over 13 years ago

$ more config/database.yml

production:
 adapter: mysql
 database: MY_DB_NAME 
 host: localhost
 username: MY_USERNAME 
 password: MY_PASSWORD 
 encoding: utf8

$ more config/environment.rb

ENV['RAILS_ENV'] ||= 'production'

# Specifies gem version of Rails to use when vendor/rails is not present
RAILS_GEM_VERSION = '2.3.5' unless defined? RAILS_GEM_VERSION

# Bootstrap the Rails environment, frameworks, and default configuration
require File.join(File.dirname(__FILE__), 'boot')

# Load Engine plugin if available
begin
  require File.join(File.dirname(__FILE__), '../vendor/plugins/engines/boot')
rescue LoadError
  # Not available
end

Rails::Initializer.run do |config|

  # Add additional load paths for sweepers
  config.load_paths += %W( #{RAILS_ROOT}/app/sweepers )

  # Activate observers that should always be running
  # config.active_record.observers = :cacher, :garbage_collector
  config.active_record.observers = :message_observer, :issue_observer, :journal_observer, :news_observer, :doc
ument_observer, :wiki_content_observer

  # Deliveries are disabled by default. Do NOT modify this section.
  # Define your email configuration in email.yml instead.
  # It will automatically turn deliveries on
  config.action_mailer.perform_deliveries = false

  config.gem 'rubytree', :lib => 'tree'

  # Load any local configuration that is kept out of source control
  # (e.g. gems, patches).
  if File.exists?(File.join(File.dirname(__FILE__), 'additional_environment.rb'))
    instance_eval File.read(File.join(File.dirname(__FILE__), 'additional_environment.rb'))
  end
end

RE: Redmine on BlueHost HELP! - Added by João Pereira over 13 years ago

Sorry about the numbers on post above, they match the comment symbol of my file

RE: Redmine on BlueHost HELP! - Added by Felix Schäfer over 13 years ago

I took the liberty of editing your post to put the file contents in < pre> tags (obviously without the extra spaces).

Other than your paste of database.yml having one space instead of two in front of the indented lines (yaml uses a 2 space indent), I don't see anything bad, and seeing that it works with script/server, you probably have it right in the file. Any errors in the log files?

RE: Redmine on BlueHost HELP! - Added by João Pereira over 13 years ago

Thanks! The production.log file is clean...

It works allright with script/localhost, just dont work in browser...

But I installed redmine 0.8.0 and it works ok!

Just dont know why recent versions like 1.0.2 dont run ok...

I noticie that, all versions of redmine, who dont ask for the rake generate_session_store command run ok(like 0.8.0), but all versions that give me the error about session password, and I need to run rake generate_session_store, they dont work...

Could be coincidence, can anyone help?

RE: Redmine on BlueHost HELP! - Added by Felix Schäfer over 13 years ago

See here under point 4 RedmineInstall for info about the session store, and yes, it has been added in 0.9.

If you expect people to be able to help you out more than this, posting the errors you get instead of just saying "it doesn't work" would help a lot.

    (1-8/8)