Skip to content
This repository has been archived by the owner on Oct 16, 2019. It is now read-only.

Latest commit

 

History

History
93 lines (73 loc) · 4.38 KB

notifications.md

File metadata and controls

93 lines (73 loc) · 4.38 KB

Chat Notifications

Heaven looks for information in the environments and tries to give feedback to chat rooms to everyone knows that code has been deployed. Right now it supports three networks.

All notifications run inside of resque jobs and need to define a deliver method.

Example Provider

module Heaven
  module Notifier
    class MyChat < Default
      def deliver(message)
      end
    end
  end
end

SlackHQ

Configuration

Environmental Variables
SLACK_WEBHOOK_URL A Slack Webhook URL from incoming-webhook section of Slack
SLACK_BOT_NAME The name to post to Slack as. Defaults to hubot
SLACK_BOT_ICON The icon to use for the notification. Defaults to https://octodex.github.com/images/labtocat.png

Campfire

Configuration

Environmental Variables
CAMPFIRE_TOKEN A campfire API token from the 'my info' section of campfire.
CAMPFIRE_SUBDOMAIN This subdomain for the campfire. For example https://atmos.campfirenow.com would be 'atmos'

HipChat

Configuration

Environmental Variables
HIPCHAT_TOKEN The notification token to send messages to hipchat.
HIPCHAT_ROOM The room to post deployment messages to.

Flowdock

Configuration

Environmental Variables
FLOWDOCK_USER_API_TOKEN A user's api token from Flowdock account page. This is used to access the api and post some messages.
FLOWDOCK_FLOW_TOKENS A JSON string that has flow ids and flow source tokens as key-value pairs. You need to generate the source tokens using OAuth api. Note that these are part of the new Flowdock threads api and thus the old flow tokens will not work.
FLOWDOCK_USER_NAME (Optional) A name that is displayed as the author for deployment activities. Defaults to Heaven
FLOWDOCK_USER_EMAIL (Optional) An email address for the above user. Defaults to dummy [email protected].
FLOWDOCK_USER_AVATAR (Optional) A url to an image that is shown for the above user as an avatar. By default a success and failure icon are used depending on the build status.

Commit Change Notifications

Successful deployments to any environment are always compared with the last successful deployment to the production environment.

Environmental Variables
HEAVEN_NOTIFIER_DISPLAY_COMMITS Add to send a list of commit changes after a succesful deployment.
HEAVEN_NOTIFIER_DISPLAY_COMMITS_LIMIT Limit the number of commits listed in the notification.