【发布时间】:2011-02-24 12:24:12
【问题描述】:
我在生产服务器上部署了我的应用程序并收到以下错误:
(您的 config/couchdb.yml 文件有问题。检查并确保它存在并且语法正确。)
couchdb.yml 文件如下:
base: &base
database_prefix:
database_suffix: _<%%= RAILS_ENV %>
development:
host: localhost
port: 5984
<<: *base
test:
host: localhost
port: 5984
<<: *base
production:
host: localhost
port: 5984
<<: *base
在 boot.rb 中
require 'rubygems'
# Set up gems listed in the Gemfile.
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__)
require 'bundler/setup' if File.exists?(ENV['BUNDLE_GEMFILE'])
require 'simply_stored/couch'
CouchPotato::Config.database_name = "http://localhost:5984/thedatabase"
数据库已经创建并在本地工作;问题出在生产服务器上,所有 gem 都已安装;不知道为什么我错过了一些我应该为生产指定不同的东西..已经尝试将主机作为 127.0.0.1 。运气不好
couchdb_initializer.rb 上抛出错误;代码是通用的(已经由 gem 生成)。
我可以使用 Rails 服务器运行应用程序并使用 3000 端口打开;但是我在使用 ngingx + 乘客槽 http://
时遇到第一个错误【问题讨论】:
标签: ruby-on-rails couchdb