LoginSignup
1
0

More than 3 years have passed since last update.

Heroku上のRailsアプリにScoutを導入

Last updated at Posted at 2020-11-25

Herokuの管理画面からアドオンを追加

ダッシュボードから操作する方法と、コマンドラインから操作する方法があります。
アドオンを追加した時点で、環境変数が自動でセットされます。

ダッシュボードから操作する場合

  • Herokuのダッシュボードにアクセス
  • Resourcesタブを開く
  • Add-onsの下の検索窓に'Scout'と入力
  • Provisionをクリック

コマンドラインから操作する場合

Heroku CLIがインストールされている状態で以下のコマンドを叩く

$ heroku addons:create scout

Gemを追加

Gemfile
gem 'scout_apm'
$ bundle install

これだけ。アプリにリクエストが無いとメトリクスは表示されないので注意。導入直後に見ても多分反映されていなくて、本番のアプリを適当に触った上で、数時間後に確認すると反映されてます。

1
0
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
0