Ruby:deamon返回糟糕的文件描述符

时间:2016-12-12 11:17:19

标签: ruby-on-rails ruby thin

启动Ruby瘦客户端在命令行中运行良好:

RAILS_ENV=production bundle exec thin --ssl-disable-verify -C services/private_pub/private_pub_thin.yml start

但是作为deamon启动它会返回一个错误的文件描述符:

user@app:~/app$ RAILS_ENV=production bundle exec thin -d --ssl-disable-verify -C services/private_pub/private_pub_thin.yml start
user@app:~/app$ /opt/rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/source/git/git_proxy.rb:149:in ``': Bad file descriptor (Errno::EBADF)
    from /opt/rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/source/git/git_proxy.rb:149:in `block in git'
    from /opt/rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/shared_helpers.rb:72:in `call'
    from /opt/rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/shared_helpers.rb:72:in `with_clean_git_env'
    from /opt/rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/source/git/git_proxy.rb:149:in `git'
    from /opt/rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/source/git/git_proxy.rb:83:in `version'
    from /opt/rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/env.rb:78:in `git_version'
    from /opt/rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/env.rb:22:in `report'
    from /opt/rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/friendly_errors.rb:74:in `request_issue_report_for'
    from /opt/rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/friendly_errors.rb:40:in `log_error'
    from /opt/rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/friendly_errors.rb:100:in `rescue in with_friendly_errors'
    from /opt/rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/friendly_errors.rb:98:in `with_friendly_errors'
    from /opt/rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/exe/bundle:19:in `<top (required)>'
    from /opt/rbenv/versions/2.2.1/bin/bundle:23:in `load'
    from /opt/rbenv/versions/2.2.1/bin/bundle:23:in `<main>'

有什么想法吗?这没有任何代码更改。还没有任何东西在运行。

0 个答案:

没有答案