Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/dxw/opsgenie-alert-tagging
https://github.com/dxw/opsgenie-alert-tagging
tech-ops
Last synced: 10 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/dxw/opsgenie-alert-tagging
- Owner: dxw
- Created: 2021-08-27T11:28:28.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-12-09T11:53:15.000Z (13 days ago)
- Last Synced: 2024-12-09T12:38:49.656Z (13 days ago)
- Topics: tech-ops
- Language: Ruby
- Homepage:
- Size: 83 KB
- Stars: 0
- Watchers: 10
- Forks: 0
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Opsgenie Alert Tagging
Opsgenie Alert Tagging updates Opgenies alerts with their relevant tags based on the time and date each alert was created at.
This was a manual process which required a human to type in relevant tags within the UI of each alert.
This has been created to automate this process.
Future iterations of this will ensure that the program will run daily via a Github action.### Getting started
clone the repo:
```
$ git clone [email protected]:dxw/opsgenie-alert-tagging.git
```run
```
$ bundle install
```run tests with
```
$ bundle exec rspec
```### Environment Variables
Ensure the follwoing required environment variables are set in a `.env` file:
- `OPSGENIE_API_KEY`: Osgenie API key. DevOps to generate this for you (needs admin access)
### Documentation
Opsgenie API Documentation is found here https://docs.opsgenie.com/docs/alert-api
GOVUK bank holiday API Documentation is found here https://www.api.gov.uk/gds/bank-holidays/#bank-holidays
### Running
To tag alerts for a specific date, run:
```
$ bundle exec rake opsgenie_alert_tagging:add_tags[]
```Where `` is the date string in the format `2021-10-10`.
By running the command without a date, this will default to yesterday's date
```
$ bundle exec rake opsgenie_alert_tagging:add_tags
```View the updated alert with it's tags in the UI