Files
metalcheck-cli/README.md
2024-12-11 13:59:08 +00:00

1.8 KiB

MetalCheck CLI

MetalCheck CLI is a command-line tool for managing and visualizing Metal Check data, including physical nodes, virtual machines, and Kubernetes clusters.

Installation

Install the tool locally using pip:

pip install -e .

Uninstallation

To remove the tool:

pip uninstall metalcheck-cli

Configuration

You can configure the base URL for the Metal Check API by creating a configuration file at ~/.config/metalcheck.conf:

[DEFAULT]
base_url = http://localhost:8000

If no configuration is provided, the CLI defaults to http://localhost:8000.

Usage

General Command Structure

Usage: metalcheck [OPTIONS] COMMAND [ARGS]...

Options:
--base-url TEXT  Set the base URL for the Metal Check API (default: http://localhost:8000)
--help           Show this message and exit.

Commands:
export  Export Metal Check data in the specified format (yaml or json)
k8s     Commands for managing Kubernetes Nodes
metal   Commands for managing Metal Nodes
visual  Displays the visual dashboard with Metal Nodes, Virtual Machines, and Kubernetes Nodes
vm      Commands for managing Virtual Machines

Examples

  1. List Metal Nodes
metalcheck metal list
  1. Add a new Metal Node
metalcheck metal add
  1. Delete a Metal Node
metalcheck metal delete
  1. List Kubernetes Nodes
metalcheck k8s list
  1. Analyze Kubernetes Cluster
metalcheck k8s think
  1. Export Data
metalcheck export --format yaml exported-data.yaml
  1. Visual Dashboard

Run the interactive dashboard to visualize Metal Nodes, Virtual Machines, and Kubernetes Nodes:

metalcheck visual

Run visual with the AI summary for Kubernetes cluster:

metalcheck visual --summary