2011-11-14 11 views
1

RedmineをCentosサーバにインストールしようとしています。サーバでredmineを実行する際の問題

すでにPHPとMySQLがインストールされています。私がredmineをインストールしようとしているホストのドメイン名はhttp://iteny.com/devです。

レールが正しく機能するように開始できないようです。ここで

は、サーバー上の私のルビーのセットアップです:

  • Rubyのバージョン1.8.7
  • Railsのバージョン2.3.11
  • Rubyの宝石バージョン1.6.2
  • ラックバージョン1.1.1
  • MySQLバージョン5.1.56ここ

は私dispatch.cgiファイル(iはN public/フォルダ):

#!/usr/local/bin/ruby 
require "/usr/local/lib/ruby/gems/1.8/gems/rails-2.3.11/lib/dispatcher" 

#require File.dirname(__FILE__) + "/../config/environment" unless defined?(RAILS_ROOT) 
# If you're using RubyGems and mod_ruby, this require should be changed to an absolute path one, like: 
# "/usr/local/lib/ruby/gems/1.8/gems/rails-0.8.0/lib/dispatcher" -- otherwise performance is severely impaired 
require "dispatcher" 
ADDITIONAL_LOAD_PATHS.reverse.each { |dir| $:.unshift(dir) if File.directory?(dir) } if defined?(Apache::RubyRun) 
Dispatcher.dispatch 

ここenvironment.rbファイルがconfig/フォルダに(ある):あなたは私の環境についての詳細情報が必要な場合は

# you don't control web/app server and can't set it the proper way 
ENV['RAILS_ENV'] ||= 'production' 

# Specifies gem version of Rails to use when vendor/rails is not present 
RAILS_GEM_VERSION = '2.3.11' 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| 
    # Settings in config/environments/* take precedence those specified here 

    # Skip frameworks you're not going to use 
    # config.frameworks -= [ :action_web_service, :action_mailer ] 

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

    # Force all environments to use the same logger level 
    # (by default production uses :info, the others :debug) 
    # config.log_level = :debug 

    # Enable page/fragment caching by setting a file-based store 
    # (remember to create the caching directory and make it readable to the application) 
    # config.action_controller.cache_store = :file_store, "#{RAILS_ROOT}/tmp/cache" 

    # 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, :document_observer, :wiki_content_observer, :comment_observer 

    # Make Active Record use UTC-base instead of local time 
    # config.active_record.default_timezone = :utc 

    # Use Active Record's schema dumper instead of SQL when creating the test database 
    # (enables use of different database adapters for development and test environments) 
    # config.active_record.schema_format = :ruby 

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

    config.gem 'rubytree', :lib => 'tree' 
    config.gem 'coderay', :version => '~>0.9.7' 

    # 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 

- ちょうど頼みます!

答えて

1

正常に機能するためにレールを起動できないようです。

どのようなエラーが表示されますか?何が起こるのですか?あなたは言わなかった。

いずれにしても、ApacheまたはNginxでRailsアプリケーションをホストする最も簡単な方法は、Passengerを使用することです。それをインストールすると、数分で起動して実行する必要があります!

+0

問題は、レールサーバーwebrickをテストすると、http://0.0.0.0:3000で実行が開始されるため、テストできないということです。そして、ウェブサイトはウェブサイトにコンパイルするのではなく、フォルダを表示します。乗客に関する部分は、私はそれらがインストールされていると思います。 -bash-3.2#find/-name passenger /home/virtfs/iteny/usr/local/lib/ruby/gems/1.8/gems/passenger-3.0.9/bin/passenger /home/virtfs/iteny/usr/local/bin/passenger /usr/local/lib/gems/1.8/gems/passenger-3.0.9/bin/passenger /usr/local/bin/passenger – Andrey

+0

ハァッか。あなたがしたいなら、あなたはlocalhost:3000に行くことができます。しかしWEBrickは開発には最適ですが、生産には不十分です。乗客のウェブサイトの指示に従って、乗客が働くようにしてください。 –

関連する問題