Foreman在Windows下启动失败,遵循Heroku教程 [英] Foreman start fails on Windows following Heroku tutorial
问题描述
我正在关注Heroku / Facebook整合的英雄教程(但我怀疑这个问题与Facebook整合无关),我被困在我应该开始工头的舞台上(我已经安装了Heroku installbelt for windows,其中包括工头):
>工头开始
给出:
C:/RailsInstaller/Ruby1.8.7/lib/ruby/site_ruby/1.8/rubygems/dependency.rb:247:在`to_specs'中:在[POpen4]中找不到工头(> = 0) -0.1.4,Platform-0.4.0,ZenTest-4.6.2,abstract-1.0.0,actionm
ailer-3.0.11,actionmailer-3.0.9,actionpack-3.0.11,actionpack-3.0。 9,activemodel-3.0.11,activemodel-3.0.9,activerecord-3.0.11,activerecord-3.0.9,activerecord-sqlserver-adapter-3.0.15,activereso
urce-3.0.11,activeresource-3.0 .9,activesupport-3.0.11,activesupport-3.0.9,addressable-2.2.6,annotation-2.4.0,arel-2.0.10,autotest-4.4.6,autotest-growl-0.2.16,autotest-rails -pure-4.1.2,autotest
-standalone-4.5.8,builder-2.1.2,bundler-1.0.15,diff-lcs-1.1.3,erubis-2.6.6,factory_girl-1.3.3 ,factory_girl_rails-1.0,faker-0.3.1,gravatar_image_tag-1.0.0.pre2,heroku-2.14.0,i18n-0.5.0,json-
1.6.1,launchy-2.0.5,mail-2.2 .19,mime-type-1.17.2,mime-type-1.16,nokogiri-1.5.0-x86 -mingw32,open4-1.1.0,pg-0.11.0-x86-mingw32,polyglot-0.3.3,polyglot-0.3.1,rack-1.2.4,rack-1.2.3,rack-moun
t-0.6.14,机架测试-0.5.7,rails-3.0.11,rails-3.0.9,railties-3.0.11,railties-3.0.9,rake-0.9.2.2,rake-0.8.7, rb-readline-0.4.0,rdoc-3.11,rdoc-3.8,rest-client-1.6.7,rspec-2.6.0,rspec-core-2.6。
4,rspec-expectations-2.6.0,rspec-mocks-2.6.0,rspec-rails-2.6.1,rubygems-update-1.8.11,rubyzip-0.9.4,rubyzip2-2.0.1, spork-0.9.0.rc8-x86-mingw32,sqlite3-1.3.3-x86-mingw32,sqlite3-ruby-1.3.3,te
rm-ansicolor-1.0.7,thor-0.14.6,tiny_tds -0.4.5-x86-mingw32,treetop-1.4.10,treetop-1.4.9,tzinfo-0.3.31,tzinfo-0.3.29,webrat-0.7.1,will_paginate-3.0.pre2,win32-api-1.4 .8-x86-mingw32,win32-open3
-0.3.2-x86-mingw32,win32-process-0.6.5,windows-api-0.4.0,windows-pr-1.2.1,zip-2.0 .2](Gem :: LoadError)
来自C:/RailsInstaller/Ruby1.8.7/lib/ruby/site_ruby/1.8/rubygems/dependency.rb:256:在`to_spec'
from C: /RailsInstaller/Ruby1.8.7/lib/ruby/site_ruby/1.8/rubygems.rb:1210:in`gem'
from C:/ Program Files(x86)/ruby-1.9.3/bin/foreman:18
由于我是一个完整的noob在这我不知道我的问题在这里是重复的对于遵循Python / Flask Heroku教程(因为它不是完全相同的错误),工头开始错误。如果是这样,有没有人有一种在Windows上部署开发环境的方法(对于Heruko,Python,Facebook应用程序)?还是应该使用Ubuntu?
谢谢
尽管这个问题似乎没有任何人在这里(5个意见在〜2小时,0答案,0评论...),我找到了解决方案,并准备与任何人会遇到它分享: p>
- 安装最新的红宝石, a>(1.9.3-p194) - 有时会出现相同版本的碰撞安装,在我的情况下,我刚刚卸载了所有版本的ruby,但如果您已经有其他应用程序需要旧版本,那么您必须更仔细
-
检查您的系统是否默认使用此版本,通过调用命令中的
ruby -v
行提示:获取ruby 1.9.3p194(2012-04-20)[i386-mingw32]
(您可能需要关闭并重新打开cmd
,以包含新的环境变量) -
仍然在cmd,调用:
gem install foreman
/ pre>
gem install taps
-
现在转到您的
Procfile
应用程序您的教程中的英雄示例应用程序)并执行foreman start
,您应该会看到如下所示:18:23:52 web.1 |开始于pid 7212
18:23:54 web.1 | *运行于http://0.0.0.0:5000/
18:23:54 web.1 | *重新启动重新加载程序
I'm following the heroku tutorial for Heroku/Facebook integration (but I suspect this issue has nothing to do with facebook integration) and I got stuck on the stage where I was supposed to start foreman (I've installed the Heroku installbelt for windows, which includes foreman):
> foreman start
gives:
C:/RailsInstaller/Ruby1.8.7/lib/ruby/site_ruby/1.8/rubygems/dependency.rb:247:in `to_specs': Could not find foreman (>= 0) amongst [POpen4-0.1.4, Platform-0.4.0, ZenTest-4.6.2, abstract-1.0.0, actionm
ailer-3.0.11, actionmailer-3.0.9, actionpack-3.0.11, actionpack-3.0.9, activemodel-3.0.11, activemodel-3.0.9, activerecord-3.0.11, activerecord-3.0.9, activerecord-sqlserver-adapter-3.0.15, activereso
urce-3.0.11, activeresource-3.0.9, activesupport-3.0.11, activesupport-3.0.9, addressable-2.2.6, annotate-2.4.0, arel-2.0.10, autotest-4.4.6, autotest-growl-0.2.16, autotest-rails-pure-4.1.2, autotest
-standalone-4.5.8, builder-2.1.2, bundler-1.0.15, diff-lcs-1.1.3, erubis-2.6.6, factory_girl-1.3.3, factory_girl_rails-1.0, faker-0.3.1, gravatar_image_tag-1.0.0.pre2, heroku-2.14.0, i18n-0.5.0, json-
1.6.1, launchy-2.0.5, mail-2.2.19, mime-types-1.17.2, mime-types-1.16, nokogiri-1.5.0-x86-mingw32, open4-1.1.0, pg-0.11.0-x86-mingw32, polyglot-0.3.3, polyglot-0.3.1, rack-1.2.4, rack-1.2.3, rack-moun
t-0.6.14, rack-test-0.5.7, rails-3.0.11, rails-3.0.9, railties-3.0.11, railties-3.0.9, rake-0.9.2.2, rake-0.8.7, rb-readline-0.4.0, rdoc-3.11, rdoc-3.8, rest-client-1.6.7, rspec-2.6.0, rspec-core-2.6.
4, rspec-expectations-2.6.0, rspec-mocks-2.6.0, rspec-rails-2.6.1, rubygems-update-1.8.11, rubyzip-0.9.4, rubyzip2-2.0.1, spork-0.9.0.rc8-x86-mingw32, sqlite3-1.3.3-x86-mingw32, sqlite3-ruby-1.3.3, te
rm-ansicolor-1.0.7, thor-0.14.6, tiny_tds-0.4.5-x86-mingw32, treetop-1.4.10, treetop-1.4.9, tzinfo-0.3.31, tzinfo-0.3.29, webrat-0.7.1, will_paginate-3.0.pre2, win32-api-1.4.8-x86-mingw32, win32-open3
-0.3.2-x86-mingw32, win32-process-0.6.5, windows-api-0.4.0, windows-pr-1.2.1, zip-2.0.2] (Gem::LoadError)
from C:/RailsInstaller/Ruby1.8.7/lib/ruby/site_ruby/1.8/rubygems/dependency.rb:256:in `to_spec'
from C:/RailsInstaller/Ruby1.8.7/lib/ruby/site_ruby/1.8/rubygems.rb:1210:in `gem'
from C:/Program Files (x86)/ruby-1.9.3/bin/foreman:18
Since I'm a complete noob in this I'm not sure if my question here is a duplicate for Error on 'foreman start' while following the Python/Flask Heroku tutorial (because it's not quite the same error). If so, does anyone have a method for deploying a development environment on windows (for Heruko, Python, Facebook app)? Or should I use Ubuntu for this?
Thanks
Although this question doesn't seem to be of interest to anyone here (5 views in ~2 hours, 0 answers, 0 comments...), I have found the solution and ready to share it with anyone that will encounter it:
Install the latest ruby from rubyinstaller.org (1.9.3-p194) - Sometimes there is a collision installs of the same version, in my case I've just uninstalled all versions of ruby, but if you already have other application that needs older version then you have to be more careful
Check that your system is default to use this version by invoking
ruby -v
in command line prompt: and gettingruby 1.9.3p194 (2012-04-20) [i386-mingw32]
(you may have to close and re-opencmd
, to include the new environment variables)Still in cmd, invoke:
gem install foreman gem install taps
now go to your
Procfile
app (e.g. your heroku example app from the tutorial) and executeforeman start
, you should see something like this:18:23:52 web.1 | started with pid 7212 18:23:54 web.1 | * Running on http://0.0.0.0:5000/ 18:23:54 web.1 | * Restarting with reloader
这篇关于Foreman在Windows下启动失败,遵循Heroku教程的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!