Giter Site home page Giter Site logo

rundeck-slack-notification's Introduction

Rundeck SlackNotification Plugin

Use this notification plugin to post messages to Slack via incoming webhook using the Slack attachments format.

Installation

Copy SlackNotification.groovy to the Rundeck plugins directory $RDECK_BASE/libext/.

Configuration

Framework/Project Properties

This following properties can be set at the framework or project level:

  • webhookUrl - (required) the incoming webhook URL configured in Slack custom integrations.
  • iconEmoji - override default bot emoji
  • username - override default bot username
  • proxyHost - (optional) egress proxy host if outbound requests need to be proxied.
  • proxyPort - (required if proxyHost is set) egress proxy port.

Additional Properties

The following properties are optional, and can be set at the framework/project level, as well as the instance-level for each job:

  • channel - channel(s) to post messages to. If not specified, will send to default channel configured for the incoming webhook on slack.com. Accepts a comma-delimited list of multiple channels and/or users (e.g. #general or #room1,#room2,@user1).
  • title - default title for message. Accepts ${job.*} and ${option.*} context variables, in addition to the following custom tokens that will be substituted at runtime:
    • ${job.STATUS} - job status (all caps)
    • ${job.Status} - job status (capitalized)
    • ${job.fullName} - job's full name in group/job format

The default title format is ${job.Status} [${job.project}] ${job.fullName} run by ${job.username} (#${job.execid}).

Configuration Examples

Configure the webhook URL with framework scope by adding an entry in $RDECK_BASE/etc/framework.properties:

framework.plugin.Notification.SlackNotification.webhookUrl=https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX

Configure the webhook URL with project scope by adding an entry to $RDECK_BASE/projects/[ProjectName]/etc/project.properties:

project.plugin.Notification.SlackNotification.webhookUrl=https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX
# and maybe set a project-specific channel
project.plugin.Notification.SlackNotification.channel=\#myproject

rundeck-slack-notification's People

Contributors

bdclark avatar dewingok avatar justindavis avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.