Ruby and Rails

Install gem install sentry-rails

Add the gem, set the DSN, done. Rails, Sidekiq and Rack integrations attach on their own.

1Gemfile

ruby
gem "sentry-ruby"
gem "sentry-rails"

2Initialiser

config/initializers/sentry.rb
Sentry.init do |config|
  config.dsn = "https://<public key>@in.blipit.io/<project id>"
  config.environment = Rails.env
  config.release = ENV["RELEASE"]
  config.traces_sample_rate = 0.2
end

3Check it works

Open Issues in app.blipit.io. The first event appears within a few seconds, grouped into an issue, and the people in charge get an email.

ruby
Sentry.capture_message("Hello from Rails")

Stuck? Email support@blipit.io. Keys and the exact DSN for each project are under API keys in app.blipit.io.