推送拒绝未能检测到set buildpack heroku / ruby​​

时间:2016-03-30 17:09:01

标签: ruby heroku slack

我正在尝试将以下项目添加到我的闲聊“https://github.com/PDaily/lita-destiny”我已经在我的闲聊中添加了lita集成。我在heroku网站上创建了一个新的应用程序,我已添加到全局配置变量,我的LITA_TOKEN,GITHUB_URL和BUNGIE_API_KEY。我使用了cmd和heroku工具包并登录到heroku。然后我将目录更改为lita-destiny文件夹所在的位置。我已经完成了

Bundle install
Git add. 
Git add -u
Git commit -m "heroku" 
Git push heroku master.

我已经安装了所有本机宝石,在该文件夹的根目录中也是一个gemfile。 但是我在那里得到了标题中的错误。我也进行了

  

heroku buildpacks:设置heroku / ruby​​

2016-03-31T00:14:25+00:00 app[heroku-redis]: source=REDIS sample#active-connections=1 sample#load-avg-1m=0.33 sample#load-avg-5m=0.24 sample#load-avg-15m=0.215 sample#read-iops=0 sample#write-iops=0 sample#memory-total=15405632.0kB sample#memory-free=13328628.0kB sample#memory-cached=482376kB sample#memory-redis=294048bytes sample#hit-rate=1 sample#evicted-keys=0
2016-03-31T00:15:24+00:00 app[heroku-redis]: source=REDIS sample#active-connections=1 sample#load-avg-1m=0.255 sample#load-avg-5m=0.235 sample#load-avg-15m=0.215 sample#read-iops=0 sample#write-iops=0 sample#memory-total=15405632.0kB sample#memory-free=13328504.0kB sample#memory-cached=482372kB sample#memory-redis=294048bytes sample#hit-rate=1 sample#evicted-keys=0
2016-03-31T00:16:48.562723+00:00 heroku[api]: Release v12 created by munkeyboy14@gmail.com
2016-03-31T00:16:48.562723+00:00 heroku[api]: Deploy 97376bc by munkeyboy14@gmail.com
2016-03-31T00:16:48.723963+00:00 heroku[slug-compiler]: Slug compilation started
2016-03-31T00:16:48.723974+00:00 heroku[slug-compiler]: Slug compilation finished
2016-03-31T00:16:48.698905+00:00 heroku[web.1]: State changed from crashed to starting
2016-03-31T00:16:48+00:00 app[heroku-redis]: source=REDIS sample#active-connections=1 sample#load-avg-1m=0.22 sample#load-avg-5m=0.24 sample#load-avg-15m=0.22 sample#read-iops=0 sample#write-iops=0 sample#memory-total=15405632.0kB sample#memory-free=13328232.0kB sample#memory-cached=482380kB sample#memory-redis=294048bytes sample#hit-rate=1 sample#evicted-keys=0
2016-03-31T00:16:50.125875+00:00 heroku[web.1]: Starting process with command `bundle exec lita`
2016-03-31T00:16:52.409755+00:00 app[web.1]: /app/vendor/bundle/ruby/2.2.0/gems/lita-slack-1.7.2/lib/lita/adapters/slack/api.rb:63:in `call_api': Slack API call to rtm.start returned an error: invalid_auth. (RuntimeError)
2016-03-31T00:16:52.409772+00:00 app[web.1]:    from /app/vendor/bundle/ruby/2.2.0/gems/lita-slack-1.7.2/lib/lita/adapters/slack/api.rb:38:in `rtm_start'
2016-03-31T00:16:52.409773+00:00 app[web.1]:    from /app/vendor/bundle/ruby/2.2.0/gems/lita-slack-1.7.2/lib/lita/adapters/slack/rtm_connection.rb:20:in `build'
2016-03-31T00:16:52.409774+00:00 app[web.1]:    from /app/vendor/bundle/ruby/2.2.0/gems/lita-slack-1.7.2/lib/lita/adapters/slack.rb:22:in `run'
2016-03-31T00:16:52.409774+00:00 app[web.1]:    from /app/vendor/bundle/ruby/2.2.0/gems/lita-4.7.0/lib/lita/robot.rb:80:in `run'
2016-03-31T00:16:52.409775+00:00 app[web.1]:    from /app/vendor/bundle/ruby/2.2.0/gems/lita-4.7.0/lib/lita.rb:80:in `run'
2016-03-31T00:16:52.409776+00:00 app[web.1]:    from /app/vendor/bundle/ruby/2.2.0/gems/lita-4.7.0/lib/lita/cli.rb:77:in `start'
2016-03-31T00:16:52.409778+00:00 app[web.1]:    from /app/vendor/bundle/ruby/2.2.0/gems/thor-0.19.1/lib/thor/command.rb:27:in `run'
2016-03-31T00:16:52.409778+00:00 app[web.1]:    from /app/vendor/bundle/ruby/2.2.0/gems/thor-0.19.1/lib/thor/invocation.rb:126:in `invoke_command'
2016-03-31T00:16:52.409779+00:00 app[web.1]:    from /app/vendor/bundle/ruby/2.2.0/gems/thor-0.19.1/lib/thor.rb:359:in `dispatch'
2016-03-31T00:16:52.409780+00:00 app[web.1]:    from /app/vendor/bundle/ruby/2.2.0/gems/thor-0.19.1/lib/thor/base.rb:440:in `start'
2016-03-31T00:16:52.409800+00:00 app[web.1]:    from /app/vendor/bundle/ruby/2.2.0/bin/lita:23:in `load'
2016-03-31T00:16:52.409782+00:00 app[web.1]:    from /app/vendor/bundle/ruby/2.2.0/gems/lita-4.7.0/bin/lita:6:in `<top (required)>'
2016-03-31T00:16:52.409800+00:00 app[web.1]:    from /app/vendor/bundle/ruby/2.2.0/bin/lita:23:in `<main>'
2016-03-31T00:16:53.126028+00:00 heroku[web.1]: Process exited with status 1
2016-03-31T00:16:53.137278+00:00 heroku[web.1]: State changed from starting to crashed

以上是来自heroku日志的最新错误消息

1 个答案:

答案 0 :(得分:0)

如果我正确理解你的问题,那么对于lita如何运作存在根本的误解。 lita gem有一个可执行文件(lita new),可以为您创建一个新的lita bot。然后,将lita-destiny等插件添加到lita bot的Gemfile中。

所以你得到这个错误是因为你没有推出Heroku认为是Ruby应用程序的代码 - 你正在推动一个宝石。

你应该做的是

cd ../some/place/else
gem install lita
lita new
cd lita
echo 'web: bundle exec lita' >> Procfile
bundle install
git init
git add .
git commit -m 'Initial commit'
heroku apps:create
git push heroku master

然后,您可以将lita-destiny插件添加到lita bot的Gemfile(上面刚刚创建的项目)中,并将config.handlers.destiny_handler.api_key = 'XXXX'添加到同一项目中的lita_config.rb文件中。您还将Slack API密钥添加到lita_config.rb文件。

来源:lita docsheroku docs