i have a problem on one of my rails app developpement. I use heroku to deploy my rails app (prod env). And i have a misunderstanding between dev and prod environnemnt.
When i excecute "require 'socket'; TCPSocket.new(nil, 80)" in my rails console in dev env (rails console, on my computer in local) and the same commande in the rails command of heroku (heroku run rails console), i don't have the same result.
In dev env, i get "#TCPSocket:fd 18" then no problem occured but in prod env i get "Errno::ECONNREFUSED: Connection refused - connect(2) for nil port 80
from (irb):1:in initialize'
from (irb):1:in
new'
from (irb):1
from /app/vendor/bundle/ruby/2.3.0/gems/railties 4.2.5/lib/rails/commands/console.rb:110:in `start'
from /app/vendor/bundle/ruby/2.3.0/gems/railties-4.2.5/lib/rails/commands/console.rb:9:in `start'
from /app/vendor/bundle/ruby/2.3.0/gems/railties-4.2.5/lib/rails/commands/commands_tasks.rb:68:in `console'
from /app/vendor/bundle/ruby/2.3.0/gems/railties-4.2.5/lib/rails/commands/commands_tasks.rb:39:in `run_command!'
from /app/vendor/bundle/ruby/2.3.0/gems/railties-4.2.5/lib/rails/commands.rb:17:in `'
from /app/bin/rails:9:in `require'
from /app/bin/rails:9:in main
"
I have the same environnment (same version of ruby, rails, etc...) So, if one of you as already met the problem before or could explain me the behavior of TCPSocket in that case.
Thank you in advance.