Giter VIP home page Giter VIP logo

concourse-pagerduty-notification-resource's Introduction

Concourse Pagerduty Notification Resource

Sends alerts to Pagerduty. This resource can now send log output of failing Concourse task(s) to Pagerduty, as well as the standard description and incident_key fields.

Resource Type Configuration

resource_types:
- name: pagerduty-notification-resource
  type: docker-image
  source:
    repository: fidelityinternational/pagerduty-notification-resource
    tag: latest

Source Configuration

  • service_key: Required. The GUID of one of your "Generic API" services. This is the "Integration Key" listed on a Generic API's service detail page.

The following fields are required if you want to see erroring Concourse task output in the Pagerduty notification:

  • atc_external_url: Optional The ATC external URL (if username and password is supplied but not the ATC URL, it will attempt to use the standard in-built ATC_EXTERNAL_URL instead)
  • atc_username: Optional ATC username is required if atc_external_url is supplied.
  • atc_password: Optional ATC password is required if atc_external_url is supplied.

Example resource config:

resources:
- name: pagerduty-notify
  type: pagerduty-notification-resource
  source:
    atc_external_url: ...
    atc_username: ...
    atc_password: ...
    service_key: ...

Behaviour

out: Sends alert to pagerduty.

Send alert to pagerduty with the configured parameters.

Parameters

Required:

  • description: Static text of alert to send

Optional:

  • incident_key: Provides an incident key that can be used to dedupe alerts. Defaults to `/<job-name
  • action: Specifies whether to trigger, resolve, or acknowledge an insident. Defaults to trigger

Example

See our sample pipeline.yml for a working example.

Testing

To test this resource, install a test Concourse with Docker following the guide here.

Push the sample pipeline to it (remember to update the Pagerduty resource configuration options first, as appropriate):

fly login -t local -c http://localhost:8080 -u concourse -p changeme
fly -t local set-pipeline -p test -c pipeline.yml

Browse http://localhost:8080 and run the monitoring-test job. One of the tasks in that job is supposed to succeed, and one is supposed to fail. Note the Pagerduty put: on the failing job. This should now trigger, so check your Pagerduty account for an incoming alert.

Inside the alert message you should find pipeline, job_name, concourse_build_url and output fields which contain useful error messages.

concourse-pagerduty-notification-resource's People

Contributors

geofffranks avatar grenzr avatar scoobed avatar srbry avatar thelangley avatar thewonn 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.