LoginSignup
1
1

More than 5 years have passed since last update.

Railsのbetter_errorsがVM経由だと動かない場合

Last updated at Posted at 2015-06-21

そもそもgitに書いてあった
https://github.com/charliesome/better_errors#security

が、制限を外すIPを探そうとifconfigや、ipconfigとかしてたが
結局以下で簡単にできた。

railsのビューのどこかに

<%= request.remote_ip %>

と書いて、作ったアプリにアクセス。出てきたIPをapp/config/environments/development.rbに追加

BetterErrors::Middleware.allow_ip! "上で出たIP"
1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1