Skip to content

Instantly share code, notes, and snippets.

@raecoo
Created December 30, 2014 14:51
Show Gist options
  • Save raecoo/5a5cfd0b2852aecf6650 to your computer and use it in GitHub Desktop.
Save raecoo/5a5cfd0b2852aecf6650 to your computer and use it in GitHub Desktop.
Use Byebug with Pow
# .powenv
export BYEBUGPORT=3001
# config/initializers/byebug.rb
if Rails.env.development? and ENV['BYEBUGPORT']
require 'byebug'
Byebug.start_server 'localhost', ENV['BYEBUGPORT'].to_i
end
# restart Pow process
touch tmp/restart.txt
# connect with Byebug server
bundle exec byebug -R localhost:3001
@dklanac
Copy link

dklanac commented Jun 22, 2015

I'm having a really difficult time getting this to work for me. I'm getting connection refused errors. I'm running Rails 4.2, Ruby 2.1.5 and Byebug 4.05. Did you run into any gotchas like this? Any ideas? Thanks!

@flov
Copy link

flov commented Sep 12, 2017

try opening the website via pow as well, just hitting touch tmp/restart isn't enough to restart the server, you actually have to access it as well

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment