8

I set up Sentry for a rails app, but it also logs errors on localhost, which is undesirable.

How can I configure Sentry to only log the production and staging environments? (not development nor test environments)

I looked at the ruby sentry docs, and the heroku sentry addon docs but couldn't see how to do this.

stevec
  • 41,291
  • 27
  • 223
  • 311

1 Answers1

22
# config/initializers/sentry.rb

...
config.enabled_environments = %w[production staging]
...
togi
  • 814
  • 5
  • 13