/amtui

Alertmanager TUI - Your Terminal Companion for Alertmanager

Primary LanguageGoMIT LicenseMIT

AMTUI - Alertmanager Terminal User Interface

Go version Release Go Report Card License Discord


 █████╗ ███╗   ███╗████████╗██╗   ██╗██╗
██╔══██╗████╗ ████║╚══██╔══╝██║   ██║██║
███████║██╔████╔██║   ██║   ██║   ██║██║
██╔══██║██║╚██╔╝██║   ██║   ██║   ██║██║
██║  ██║██║ ╚═╝ ██║   ██║   ╚██████╔╝██║
╚═╝  ╚═╝╚═╝     ╚═╝   ╚═╝    ╚═════╝ ╚═╝
                             

AMTUI is a terminal-based user interface (TUI) application that allows you to interact with Prometheus Alertmanager using your terminal. It provides a convenient way to monitor alerts, view silences, and check the status of Alertmanager instances right from your command line.

AMTUI Demo

Features

  • View active alerts with details such as severity, alert name, and description.
  • Browse and review existing silences in Alertmanager.
  • Filter alerts and silences using matchers.
  • Check the general status of your Alertmanager instance.

Installation

Using Homebrew

You can install AMTUI using the Homebrew package manager:

brew tap pehlicd/tap
brew install amtui

Using go install

You can install AMTUI using the go install command:

go install github.com/pehlicd/amtui@latest

From Releases

You can download the latest release of AMTUI from the GitHub releases page.

From Source

To use AMTUI, you'll need to have Go installed on your system. Then, you can install AMTUI using the following steps:

  1. Clone the repository:
git clone https://github.com/pehlicd/amtui.git
  1. Navigate to the project directory:
cd amtui
  1. Build the application:
go build
  1. Run the application:
./amtui

Usage

Once you've launched AMTUI, you can navigate through different sections using the following keyboard shortcuts:

  • Press 1 to view and interact with active alerts.
  • Press 2 to see existing silences.
  • Press 3 to check the general status of your Alertmanager instance.

Keyboard Shortcuts

  • q: Quit the application.
  • l: Focus on the preview list.
  • h: Focus on the sidebar list.
  • j: Move focus to the preview.
  • k: Move focus to the preview list.
  • CTRL + F: Focus on the filter input.
  • ESC: Return focus to the sidebar list.

Configuration

AMTUI uses a configuration file to connect to your Alertmanager instance. By default, the application will look for a configuration file at ~/.amtui.yaml. If the configuration file doesn't exist, AMTUI will guide you through creating it with the necessary connection details.

You can also specify connection details using command-line flags:

amtui --host 127.0.0.1 --port 9093 --scheme http

AMTUI also supports basic authentication. You can specify the username and password using the --username and --password flags:

amtui --host 127.0.0.1 --port 9093 --scheme http --username admin --password admin

Dependencies

AMTUI uses the following dependencies:

  • github.com/gdamore/tcell/v2: Terminal handling and screen painting.
  • github.com/prometheus/alertmanager/api/v2/client: Alertmanager API client.
  • github.com/rivo/tview: Terminal-based interactive viewer.
  • github.com/spf13/pflag: Flag parsing.
  • github.com/spf13/viper: Configuration management.

Contributing

If you'd like to contribute to AMTUI, feel free to submit pull requests or open issues on the GitHub repository. Your feedback and contributions are highly appreciated!

License

This project is licensed under the MIT License - see the LICENSE file for details.

Stargazers over time

Stargazers over time


Developed by Furkan Pehlivan - Project Repository