This repo includes a set of tools to eliminate toil related to working with pager duty in large teams.
Those tools were design to help the way we work with pagerduty, and might no be "for everyone"
We instruct our shifters to send an summery email with everything happened during the shift.
The goal for it being:
- knowledge sharing - we wand people to know how incidents were handles and their impact.
- identifying problematic alert schemas - this is a good way for production owners to identify noisy/ sensitive alerts.
In the way we work, we instruct our shifters to fill out the actions taken, impact etc, and this tool generates the incidents templates for them.
Required environment variables:
ESCALATION_POLICY_ID
- the escalation policy for which we want to generate the summery. The id can be found in the url of the pagerduty escalation policy viewpagerduty.com/escalation_policies#<The Key>
SCHEDULE_ID
- the schedule from which we should get the on call responders - the recipients of the summery email are derived from the on calls of the given timeframe. The id can be found in the url of the pagerduty schedule viewpagerduty.com/schedules#<THE Key>
PD_TOKEN
- the integration token generated by pagerduty
Optional environment variables:
EMAIL_TOKEN
- if you wish to use the available Sendgrid emailing, just add your email token and viola.RECIPIENT_EMAIL
- if you wish the email to be sent to a static address (such as [email protected] for example, or the service owner), you can specify the email address hereEMAIL_SUBJECT
- the subject of the generated email, will be Shift summery by default.
The subject will be sufixed by the date timeframe in the following format:DD-DD/MM
(start day-end day / month)
The shift summery should be run using docker:
docker run --env PD_TOKEN=??? \
--env ESCALATION_POLICY_ID=??? \
--env SCHEDULE_ID=??? \
--env EMAIL_TOKEN=??? \
shift-summery:latest
We're generating the report using erb. It is easy to change the template of the generated report by editing the summery_template.html.erb file.
We're using Sendgrid, as our emailing infra, if you wish to use a different one - implement the EmailClient.send_email(recipient, content)
method differently.
A small tool made to fetch all NON resolved incidents within a time frame to be used during a shift hand off.
Still WIP