Pulse on Heroku ================== Send your application errors to our hosted service and reclaim your inbox. 1. Installing the Heroku add-on ---------------------------- To use Pulse on Heroku, install the Pulse add-on: $ heroku addons:add pulse:basic # This adds the the basic plan. # If you'd like another plan, specify that instead. 2. Including the Pulse notifier in your application -------------------------------------------------- After adding the Pulse add-on, you will need to install and configure the Pulse notifier. Your application connects to Pulse with an API key. On Heroku, this is automatically provided to your application in `ENV['PULSE_API_KEY']`, so installation should be a snap! (Hoptoad is Pulse's old name.) ### Rails 3.x Add the Pulse and heroku gems to your Gemfile. In Gemfile: gem 'projectlocker-pulse' gem 'heroku' Then from your project's RAILS_ROOT, run: $ bundle install $ script/rails generate pulse --heroku ### Rails 2.x Install the heroku gem if you haven't already: gem install heroku Add the Pulse gem to your app. In config/environment.rb: config.gem 'projectlocker-pulse' Then from your project's RAILS_ROOT, run: $ rake gems:install $ rake gems:unpack GEM=projectlocker-pulse $ script/generate pulse --heroku As always, if you choose not to vendor the projectlocker-pulse gem, make sure every server you deploy to has the gem installed or your application won't start. ### Rack applications In order to use Pulse in a non-Rails rack app, just load the library, configure your API key, and use the Pulse::Rack middleware: require 'rubygems' require 'rack' require 'projectlocker_pulse' Pulse.configure do |config| config.api_key = `ENV['PULSE_API_KEY']` end app = Rack::Builder.app do use Pulse::Rack run lambda { |env| raise "Rack down" } end 3. Configure your notification settings (important!) --------------------------------------------------- Once you have included and configured the notifier in your application, you will want to configure your notification settings. This is important - without setting your email address, you won't receive notification emails. Pulse can deliver exception notifications to your email inbox. To configure these delivery settings: 1. Visit your applications resources page, like [ http://api.heroku.com/myapps/my-great-app/resources ](http://api.heroku.com/myapps/my-great-app/resources). 2. Click the name of your Pulse addon. 3. Click "Settings" to configure the Pulse Add-on. 4. Optionally: Set up deploy notification ----------------------------------------- If your Pulse plan supports deploy notification, set it up for your Heroku application like this: rake pulse:heroku:add_deploy_notification This will install a Heroku [HTTP Deploy Hook](http://docs.heroku.com/deploy-hooks) to notify Pulse of the deploy.