heroku logs works, but heroku run console times out:
Running `console` attached to terminal... up, run.7335
! Heroku client internal error.
! Search for help at: https://help.heroku.com
! Or report a bug at: https://github.com/heroku/heroku/issues/new
Error: Operation timed out - connect(2) (Errno::ETIMEDOUT)
Backtrace: /Users/username/.heroku/client/lib/heroku/client/rendezvous.rb:40:in `initialize'
/Users/username/.heroku/client/lib/heroku/client/rendezvous.rb:40:in `open'
/Users/username/.heroku/client/lib/heroku/client/rendezvous.rb:40:in `block in start'
/usr/local/heroku/ruby/lib/ruby/1.9.1/timeout.rb:68:in `timeout'
/Users/username/.heroku/client/lib/heroku/client/rendezvous.rb:31:in `start'
/Users/username/.heroku/client/lib/heroku/command/run.rb:132:in `rendezvous_session'
/Users/username/.heroku/client/lib/heroku/command/run.rb:119:in `run_attached'
/Users/username/.heroku/client/lib/heroku/command/run.rb:24:in `index'
/Users/username/.heroku/client/lib/heroku/command.rb:206:in `run'
/Users/username/.heroku/client/lib/heroku/cli.rb:28:in `start'
/usr/bin/heroku:24:in `<main>'
Command: heroku run console
Plugins: heroku-accounts
heroku-fucking-console
Version: heroku-toolbelt/2.39.4 (x86_64-darwin10.8.0) ruby/1.9.3
It looks like heroku run:console has been removed:
'heroku run:console' has been removed. Please use: `heroku run` instead.
Perhaps try doing:
heroku run bash
Related
I developed my first app with Napa and now I'm trying to deploy it on my production server.
I probably did something wrong because napa server (or bundle exec napa server) throws an error and I have no idea to what to look for to solve it...
Here my stack trace
releases/current]# napa server
Napa server starting...
/home/partners/.rvm/gems/ruby-2.2.3#my_awesome_app/gems/napa-0.5.0/lib/napa/cli/base/server.rb:14:in spawn: can't get Master/Slave device (RuntimeError)
from /home/partners/.rvm/gems/ruby-2.2.3#my_awesome_app/gems/napa-0.5.0/lib/napa/cli/base/server.rb:14:in `server'
from /home/partners/.rvm/gems/ruby-2.2.3#my_awesome_app/gems/thor-0.19.1/lib/thor/command.rb:27:in `run'
from /home/partners/.rvm/gems/ruby-2.2.3#my_awesome_app/gems/thor-0.19.1/lib/thor/invocation.rb:126:in `invoke_command'
from /home/partners/.rvm/gems/ruby-2.2.3#my_awesome_app/gems/thor-0.19.1/lib/thor.rb:359:in `dispatch'
from /home/partners/.rvm/gems/ruby-2.2.3#my_awesome_app/gems/thor-0.19.1/lib/thor/base.rb:440:in `start'
from /home/partners/.rvm/gems/ruby-2.2.3#my_awesome_app/gems/napa-0.5.0/bin/napa:5:in `<top (required)>'
from /home/partners/.rvm/gems/ruby-2.2.3#my_awesome_app/bin/napa:23:in `load'
from /home/partners/.rvm/gems/ruby-2.2.3#my_awesome_app/bin/napa:23:in main
Indeed, this works! bundle exec rackup config.ru
Why? It seems I have some issues with PTY. Maybe is a matter of permissions?
I am trying to run Openshift's rhc port forward command as following:
rhc port-forward -a ligatures -n dawningstreams
but I get the following error message:
Checking available ports ...
C:/Ruby193/lib/ruby/gems/1.9.1/gems/net-ssh-2.7.0/lib/net/ssh/authentication/agent/socket.rb:81:in `negotiate!': unknown response from agent: 1, "\x00\x00\x00-\x01\x00\x00\x00(SSH-2.0-Ruby/Net::SSH_2.7.0 i386-mingw32" (Net::SSH::Authentication::AgentError)
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/net-ssh-2.7.0/lib/net/ssh/authentication/agent/socket.rb:48:in `connect'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/net-ssh-2.7.0/lib/net/ssh/authentication/key_manager.rb:178:in `agent'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/net-ssh-2.7.0/lib/net/ssh/authentication/key_manager.rb:102:in `each_identity'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/net-ssh-2.7.0/lib/net/ssh/authentication/methods/publickey.rb:19:in `authenticate'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/net-ssh-2.7.0/lib/net/ssh/authentication/session.rb:78:in `block in authenticate'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/net-ssh-2.7.0/lib/net/ssh/authentication/session.rb:65:in `each'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/net-ssh-2.7.0/lib/net/ssh/authentication/session.rb:65:in `authenticate'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/net-ssh-2.7.0/lib/net/ssh.rb:204:in `start'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/rhc-1.27.4/lib/rhc/commands/port_forward.rb:85:in `run'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/rhc-1.27.4/lib/rhc/commands.rb:294:in `execute'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/rhc-1.27.4/lib/rhc/commands.rb:285:in `block (3 levels) in to_commander'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/commander-4.1.2/lib/commander/command.rb:180:in `call'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/commander-4.1.2/lib/commander/command.rb:180:in `call'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/commander-4.1.2/lib/commander/command.rb:155:in `run'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/commander-4.1.2/lib/commander/runner.rb:402:in `run_active_command'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/rhc-1.27.4/lib/rhc/command_runner.rb:72:in `run!'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/commander-4.1.2/lib/commander/delegates.rb:11:in `run!'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/rhc-1.27.4/lib/rhc/cli.rb:37:in `start'
from C:/Ruby193/lib/ruby/gems/1.9.1/gems/rhc-1.27.4/bin/rhc:20:in `<top(required)>'
from C:/Ruby193/bin/rhc:23:in `load'
from C:/Ruby193/bin/rhc:23:in `<main>'
I have already performed gem update rhc, but it did not help.
What is this issue and how can I solve it?
From Openshift IRC chat, we determined that it could be related to a known issue solved on a more recent version of net-ssh.
Since my Ruby installation was old, I removed it completely and re-installed it (and reinstalled rhc too). The issue is now gone.
Just last night, I was executing "heroku pg:psql" on my computer, but this morning I am greeted with the following:
H:\MyName\My Documents\MyOrg\Heroku\MyApp>heroku pg:psql
! Heroku client internal error.
! Search for help at: https://help.heroku.com
! Or report a bug at: https://github.com/heroku/heroku/issues/new
Error: undefined method `map' for #<String:0x346eae0> (NoMethodError)
Backtrace: C:/Users/myname/.heroku/client/lib/heroku/helpers/heroku_postgresql.rb:99:in `app_attachments'
C:/Users/myname/.heroku/client/lib/heroku/helpers/heroku_postgresql.rb:104:in `hpg_databases'
C:/Users/myname/.heroku/client/lib/heroku/helpers/heroku_postgresql.rb:159:in `hpg_resolve'
C:/Users/myname/.heroku/client/lib/heroku/helpers/heroku_postgresql.rb:58:in `resolve'
C:/Users/myname/.heroku/client/lib/heroku/command/pg.rb:91:in `psql'
C:/Users/myname/.heroku/client/lib/heroku/command.rb:218:in `run'
C:/Users/myname/.heroku/client/lib/heroku/cli.rb:37:in `start'
C:/Program Files (x86)/Heroku/bin/heroku:29:in `<main>'
Command: heroku pg:psql
Version: heroku/toolbelt/3.9.5 (i386-mingw32) ruby/1.9.3
Why would this error suddenly arise while I slept, and, moreover, how can I fix it?
Someone broke Heroku Toolbelt, but a fix is in now:
https://status.heroku.com/incidents/650
https://github.com/heroku/heroku/commit/784b1d1439bbd044afd892403a2e63b9114546fb
I'm trying to deploy my Ruby on Rails app to Heroku with Unicorn. I followed the tutorial on Heroku website. But it shows:
Precompiling assets failed.
Here is the running result:
-----> Preparing app for Rails asset pipeline
Running: rake assets:precompile
fatal: Not a git repository (or any of the parent directories): .git
fatal: Not a git repository (or any of the parent directories): .git
[deprecated] I18n.enforce_available_locales will default to true in the future. If you really want to skip validation of your locale you can set I18n.enforce_available_locales = false to avoid this message.
rake aborted!
uninitialized constant Rack::Timeout
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/config/initializers/timeout.rb:1:in `<top (required)>'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/railties-4.1.0.rc1/lib/rails/engine.rb:649:in `block in load_config_initializer'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/activesupport-4.1.0.rc1/lib/active_support/notifications.rb:161:in `instrument'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/railties-4.1.0.rc1/lib/rails/engine.rb:648:in `load_config_initializer'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/railties-4.1.0.rc1/lib/rails/engine.rb:613:in `block (2 levels) in <class:Engine>'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/railties-4.1.0.rc1/lib/rails/engine.rb:612:in `each'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/railties-4.1.0.rc1/lib/rails/engine.rb:612:in `block in <class:Engine>'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/railties-4.1.0.rc1/lib/rails/initializable.rb:30:in `instance_exec'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/railties-4.1.0.rc1/lib/rails/initializable.rb:30:in `run'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/railties-4.1.0.rc1/lib/rails/initializable.rb:55:in `block in run_initializers'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/railties-4.1.0.rc1/lib/rails/initializable.rb:44:in `each'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/railties-4.1.0.rc1/lib/rails/initializable.rb:44:in `tsort_each_child'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/railties-4.1.0.rc1/lib/rails/initializable.rb:54:in `run_initializers'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/railties-4.1.0.rc1/lib/rails/application.rb:286:in `initialize!'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/config/environment.rb:5:in `<top (required)>'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/railties-4.1.0.rc1/lib/rails/application.rb:262:in `require_environment!'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/railties-4.1.0.rc1/lib/rails/application.rb:346:in `block in run_tasks_blocks'
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/vendor/bundle/ruby/2.0.0/gems/sprockets-rails-2.0.1/lib/sprockets/rails/task.rb:54:in `block (2 levels) in define'
Tasks: TOP => environment
(See full trace by running task with --trace)
Precompiling assets failed.
Push rejected, failed to compile Ruby app
I use Ruby2.0, Ruby on Rails 4.1.0.rc1.
It looks like your problem is actually related to Rack::Timeout and not asset compilation.
uninitialized constant Rack::Timeout
/tmp/build_d3989303-c1d8-4020-9b98-eb9e1834f0d0/config/initializers/timeout.rb:1:in `<top (required)>'
Have you included the rack-timeout gem in your gemfile? And ran bundle install after that?
gem "rack-timeout"
Remove the timeout setting:
rm config/initializers/timeout.rb
Heroku times-out all requests at 30 seconds but the process will continue running in the background.
If you want to avoid that, re-add the line above but put rack-timeout in your Gemfile.
I would suggest trying the following:
heroku labs:enable user-env-compile
If this fails, you could always precompile your production assets, add them to your codebase and push them to heroku yourself.
RAILS_ENV=production rake assets:precompile
git add .
git commit -m 'serving up my precompiled assets'
git push origin master
git push origin heroku
I'm trying to just get into bash on Heroku Cedar stack and I'm getting the following:
$ heroku run bash
Running `bash` attached to terminal... up, run.1
/usr/local/heroku/lib/heroku/client/rendezvous.rb:87:in `fixup': undefined method `force_encoding' for "\e[01;34m~\e[00m \e[01;32m$ \e[00m":String (NoMethodError)
from /usr/local/heroku/lib/heroku/client/rendezvous.rb:63:in `start'
from /usr/local/heroku/lib/heroku/client/rendezvous.rb:46:in `loop'
from /usr/local/heroku/lib/heroku/client/rendezvous.rb:46:in `start'
from /usr/local/heroku/lib/heroku/command/run.rb:118:in `rendezvous_session'
from /usr/local/heroku/lib/heroku/command/run.rb:104:in `run_attached'
from /usr/local/heroku/lib/heroku/command/run.rb:21:in `index'
from /usr/local/heroku/lib/heroku/command.rb:167:in `send'
from /usr/local/heroku/lib/heroku/command.rb:167:in `run'
from /usr/local/heroku/lib/heroku/cli.rb:9:in `start'
from /usr/bin/heroku:28
Any ideas of what is causing this error or how to remedy it?
Thanks in advance!
What's the heroku command line version? Try upgrading it, whether it's the toolbet or the rubygem.