Skip to content

theist/librato-alerts-cli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

librato-alerts-cli

Small commandline client to enable and disable alerts in librato legacy accounts.

Usage: librato-alerts-cli [help | disable | enable | list | status | recent]

enable and disable requires a list of alerts to disable passed by standard input thru a pipe, the output of list can be used for this purpose like this:

   librato-alerts-cli list | grep <pattern> | librato-alerts-cli disable

INSTALL

As any go program you need at least go 1.16 installed on your system and then

go install github.com/theist/librato-alerts-cli@latest

CONFIGURATION

This requires two environment varables to store the librato credentials, LIBRATO_MAIL with the librato user's mail and LIBRATO_TOKEN with a valid librato API token. API token must have read / write access to allow update alarms state. The environment variables can also be placed in an .env file.

MODES

   list:    List all alerts, telling if they are enabled or disabled.
   status:  Lists the alert names which are in alarm state.
   recent:  Lists the alert names of alert which were resolved recently.
   enable:  Enable alerts passed by stdin. Alerts must be pased one by line,
            and it will be updated only if they are disabled
   disable: Disable alerts passed by stdin. Alerts must be pased one by line,
            and it will be updated only if they are enabled
   help:    This help.

ALMOST KNOWN BUGS or TODO's:

  • This is tested against an old, no tagged metrics librato account may work in the modern ones.

About

librato alerts client to list view status and enable disable alerts

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages