How do I connect to a remote debugging instance of Byebug (for use with Pow, etc)?
相关问题
- Question marks after images and js/css files in ra
- Using :remote => true with hover event
- Strong parameter override for DeviseTokenAuth cont
- Mechanize getting “Errno::ECONNRESET: Connection r
- Eager-loading association count with Arel (Rails 3
相关文章
- Right way to deploy Rails + Puma + Postgres app to
- AWS S3 in rails - how to set the s3_signature_vers
- how to call a active record named scope with a str
- How to add a JSON column in MySQL with Rails 5 Mig
- “No explicit conversion of Symbol into String” for
- form_for wrong number of arguments in rails 4
- Rspec controller error expecting <“index”> but
- Factory_girl has_one relation with validates_prese
I had to piece together information from several different sources to accomplish the above, so I thought I'd include a consolidated guide here for convenience:
Here are the steps:
In config/environments/development.rb, add:
Restart Pow and visit yourapp.dev
Run the following:
You should see a successful connection to the remote instance.
Joseph's answer was good but confusing in some small ways. He places the starting of the byebug server in
config/environments/development.rb
, when it would be better in an initializer. Additionally the exporting of the environment variable go in.powenv
or.powrc
. This is how I got it to work.In your gemfile:
On the command line:
If you are using Pow, add the following to
.powenv
:If you are using other frameworks (e.g. just
foreman
), you may have to modify.env
instead.In
config/initializers/byebug.rb
And finally on the command line:
Once you go to your pow site, the byebug server should be started. On the command line you can now do: