Skip to content

catalyst-cloud/RT-Extension-PagerDuty

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

46 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NAME
    RT-Action-NotifyPagerDuty - Create or update an incident in PagerDuty

DESCRIPTION
    This action allows you to create or update incidents in PagerDuty when a
    ticket is created or updated in Request Tracker.

RT VERSION
    Works with RT 4.4.x and above.

INSTALLATION
    "perl Makefile.PL"
    "make"
    "make install"
        May need root permissions

    "rt-setup-database --action insert --datafile db/initialdata"
        May need root permissions

    Edit your /opt/rt4/etc/RT_SiteConfig.pm
        Add this line:

            Plugin('RT::Action::NotifyPagerDuty');

        In PagerDuty.com add a new service, selection "Use our API directly"
        and select "Events API v2" and whatever other settings you need.
        Take the routing key they generate and add a line like this:

            Set ($PagerDutyRoutingKey, 'key_goes_here');

        Other settings you may want to add, with their defaults:

            Set ($PagerDutyQueueCFService, 'Incident Service');

    Restart your webserver
    In RT, you need to create a new Scrip
        Create for example a scrip with:

            Description: Create or Update PagerDuty Incident
            Condition:   On Transaction
            Action:      Notify PagerDuty
            Template:    Blank
            Stage:       Normal
            Enabled:     Yes

        Then assign that scrip to the queues which you want to notify
        PagerDuty.

CONFIGURATION
    There are only a few settings that can be configured.

    Currently you can set the PagerDuty priority and services to be used via
    Queue CustomFields.

    AcknowledgeOnTake
        Should the incident in PagerDuty be acknowledged if the ticket in RT
        is Taken? Allow values: 0 or 1.

        Defaults to 1.

        To disable:

            Set ($PagerDutyAcknowledgeOnTake, 0);

    QueueCFAcknowledgeOnTake
        Allow the global AcknowledgeOnTake setting to be overridden by
        queue.

        By default the Queue CustomField is named "Incident Acknowledge On
        Take", but you can this with:

            Set ($PagerDutyQueueCFAcknowledgeOnTake, 'Incident Acknowledge On Take');

        The allow values are: 1 or 0.

    QueueCFPriority
        The PagerDuty incident priority which this incident will be created
        using.

        By default the Queue CustomField is named "Incident Priority", but
        you can change that with:

            Set ($PagerDutyQueueCFPriority, 'Incident Priority');

        The allowed values are: critical, warning, error, or info.

        If no priority is set, or an invalid value is used, critical will be
        used.

    QueueCFService
        The PagerDuty service which this incident will be created using.

        By default the Queue CustomField is named "Incident Service", but
        you can change that with:

            Set ($PagerDutyQueueCFService, 'Incident Service');

        If no service is defined, then RT is used.

    Spool
        A directory to spool submissions if PagerDuty have sent us a
        response deferring our submission. This directory will need to be
        writable by the process that is running Request Tracker (for example
        www-data).

        By default it is unset, so if a submission is deferred it will be
        deleted.

        To set:

            Set ($PagerDutySpoolDir, '/opt/rt4/spool/pagerduty');

        If you spool submissions then you should run rt-flush-pagerduty
        regularly, for example from cron. No arguments are required for
        rt-flush-pagerduty.

    Include SubjectTag
        Prefix the summary if the incident submitted to PagerDuty with the
        Request Tracker SubjectTag for the queue the ticket is in. This is
        to allow an email address for RT (either correspond or comment) in
        the notification set within PagerDuty to allow updates from
        PagerDuty to be added to RT.

        By default this is disabled.

        To enable:

            Set ($PagerDutyIncludeSubjectTag, 1);

AUTHOR
    Andrew Ruthven, Catalyst Cloud Ltd <[email protected]>


        All bugs should be reported via email to
            [email protected]
        or via the web at
            http://rt.cpan.org/Public/Dist/Display.html?Name=RT-Extension-PagerDuty

LICENSE AND COPYRIGHT
    This software is Copyright (c) 2019-2020 by Catalyst Cloud Ltd

    This is free software, licensed under:

      The GNU General Public License, Version 2, June 1991

About

Create events in PagerDuty when a ticket is created in RT

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages