Drone plugins > Slack Blame
slack.svg

Slack Blame

by drone-plugins


Use the Slack Blame plugin to send a message to a Slack channel or through direct message when a build completes. You will need to supply Drone with an access token to the Slack API. You can create a new access token at [https://api.slack.com/web](https://api.slack.com/web).

Example

kind: pipeline
name: default

steps:
- name: notify
image: plugins/slack-blame
settings:
  token: your-secret-token
  channel: dev
  success_template: |
    The build is fixed! Thanks @{{slack.name}}
  success_image_attachments:
    - "http://i.imgur.com/TP4PIxc.jpg"
  failure_template: |
    The build is broken! Blame {{slack.name}}
  failure_image_attachments:
    - "http://cdn.meme.am/instances/51000361.jpg"

Properties

  • token

    stringrequired

    Slack access token.

    Secret recommended

    Default: none

  • channel

    stringrequired

    Slack channel.

    Default: none

  • mapping

    arrayrequired

    Mapping of authors to Slack users.

    Default: none

  • success_username

    stringrequired

    Username for successful builds.

    Default: none

  • success_icon

    stringrequired

    Icon for successful builds.

    Default: none

  • success_template

    stringrequired

    Template for successful builds.

    Default: none

  • success_image_attachments

    arrayrequired

    List of image attachments for successful builds.

    Default: none

  • failure_username

    stringrequired

    Username for failed builds.

    Default: none

  • failure_icon

    stringrequired

    Icon for failed builds.

    Default: none

  • failure_template

    stringrequired

    Template for failed builds.

    Default: none

  • failure_image_attachments

    arrayrequired

    List of image attachments for failed builds.

    Default: none