https://github.com/freckle/pdup
Report outage minutes and calculate uptime based on PagerDuty incidents
https://github.com/freckle/pdup
terraform-managed
Last synced: 3 months ago
JSON representation
Report outage minutes and calculate uptime based on PagerDuty incidents
- Host: GitHub
- URL: https://github.com/freckle/pdup
- Owner: freckle
- License: mit
- Created: 2020-04-15T19:33:49.000Z (about 5 years ago)
- Default Branch: main
- Last Pushed: 2025-01-27T00:29:03.000Z (4 months ago)
- Last Synced: 2025-01-27T01:24:12.360Z (4 months ago)
- Topics: terraform-managed
- Language: Haskell
- Homepage:
- Size: 65.4 KB
- Stars: 0
- Watchers: 21
- Forks: 0
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# PDUp
Report outage minutes and calculate uptime based on PagerDuty incidents.
## Features
- Handles Retry (on 429) and pagination of PagerDuty API
- Accepts days or absolute time range (see usage)
- Combines overlapping Incidents (in other words, you can only be down 1 minute
in any given minute)## Installation
```
git clone https://github.com/freckle/pdup
cd pdup
stack build --fast --pedantic
```Create `.env`:
```
PAGERDUTY_TOKEN={Your PagerDuty API token}
```## Usage
```console
% stack exec pdup -- --help
Usage: pdup [-t|--team ARG] [-S|--ignore-service ARG]
((-d|--days N) | (-s|--since YYYY-MM-DD) [-u|--until YYYY-MM-DD])Available options:
-t,--team ARG Filter by Team Id
-S,--ignore-service ARG Ignore Service Id
-d,--days N Query over previus N days from now
-s,--since YYYY-MM-DD Query since start of date
-u,--until YYYY-MM-DD Query until end of
date (default: 2021-08-17 19:27:26.739311869 UTC)
-h,--help Show this help text
```To show information for the previous 7, 30, and 90 days, run `bin/report`.
---
[LICENSE](./LICENSE) | [CHANGELOG](./CHANGELOG.md)