Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
hkuds avatar

Cli Anything Pm2

  • 359 installs
  • 46.6k repo stars
  • Updated August 3, 2026
  • hkuds/cli-anything

cli-anything-pm2 is a Python CLI skill that operates Node and Python services with PM2 for developers who need to start clusters, reload zero-downtime, tail logs, and recover crashed workers.

About

cli-anything-pm2 is an hkuds/cli-anything stateless Python CLI skill for PM2 process management that communicates via the PM2 CLI subprocess with no local session state. Installation uses pip install -e . with Python 3.10+ and a globally installed PM2 from npm install -g pm2. Developers run cli-anything-pm2 --help, start an interactive REPL with bare cli-anything-pm2, or pass flags for JSON output tailored to agent consumption. The skill supports listing, starting, stopping, and restarting processes, viewing logs, and managing system configuration for Node and Python services on servers or containers. cli-anything-pm2 fits platform engineers who want agents to operate PM2 fleets with structured JSON responses instead of ad hoc shell parsing. Use it when recovering crashed workers, applying zero-downtime reloads, setting memory limits, or tailing production logs during incident response while keeping PM2 as the underlying process supervisor.

  • PM2 start and cluster modes
  • Zero-downtime reload
  • Log tailing and rotation
  • Memory and restart policies
  • Crash recovery workflows

Cli Anything Pm2 by the numbers

  • 359 all-time installs (skills.sh)
  • +14 installs in the week ending Aug 2, 2026 (Skillselion tracking)
  • Ranked #158 of 550 CLI & Terminal skills by installs in the Skillselion catalog
  • Data as of Aug 5, 2026 (Skillselion catalog sync)
npx skills add https://github.com/hkuds/cli-anything --skill cli-anything-pm2

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs359
repo stars46.6k
Last updatedAugust 3, 2026
Repositoryhkuds/cli-anything

How do you manage PM2 processes from a Python CLI?

Operate Node and Python services with PM2 via CLI—start clusters, reload zero-downtime, tail logs, set memory limits, and recover crashed workers on servers or containers.

Who is it for?

Platform developers who run PM2 on servers or containers and want a Python 3.10+ CLI with JSON output for agent-driven process management.

Skip if: Teams using systemd, Kubernetes, or Docker Compose exclusively without PM2 installed globally on the target host.

When should I use this skill?

A developer or agent needs to start, stop, reload, or tail logs for PM2-managed Node or Python services with JSON-friendly CLI output.

What you get

PM2 process list, start/stop/reload results, log tail output, memory limit config, and JSON agent-readable command responses.

  • PM2 process status JSON
  • Reload and restart command results
  • Log tail output

By the numbers

  • Requires Python 3.10+ and globally installed PM2 from npm

Files

SKILL.mdMarkdownGitHub ↗

cli-anything-pm2

A stateless command-line interface for PM2 process management. Communicates via the PM2 CLI subprocess. No local state or session.

Installation

pip install -e .

Prerequisites:

  • Python 3.10+
  • PM2 installed globally (npm install -g pm2)

Usage

Basic Commands

# Show help
cli-anything-pm2 --help

# Start interactive REPL mode
cli-anything-pm2

# Run with JSON output (for agent consumption)
cli-anything-pm2 --json process list
cli-anything-pm2 --json system version

REPL Mode

When invoked without a subcommand, the CLI enters an interactive REPL session:

cli-anything-pm2
# Enter commands interactively with tab-completion and history

Command Groups

process

Process inspection commands.

CommandDescription
listList all PM2 processes
describe <name>Get detailed info for a process
metricsGet metrics for all processes

lifecycle

Process lifecycle commands.

CommandDescription
start <script> --name <name>Start a new process
stop <name>Stop a process
restart <name>Restart a process
delete <name>Delete a process

logs

Log management commands.

CommandDescription
view <name> --lines 50View recent logs
flush [name]Flush logs

system

System-level commands.

CommandDescription
saveSave current process list
startupGenerate startup script
versionGet PM2 version

Output Formats

All commands support dual output modes:

  • Human-readable (default): Tables, colors, formatted text
  • Machine-readable (--json flag): Structured JSON for agent consumption
# Human output
cli-anything-pm2 process list

# JSON output for agents
cli-anything-pm2 --json process list

For AI Agents

When using this CLI programmatically:

1. Always use `--json` flag for parseable output 2. Check return codes - 0 for success, non-zero for errors 3. Parse stderr for error messages on failure

Version

1.0.0

Related skills

How it compares

Use cli-anything-pm2 for PM2-specific agent operations; use generic shell skills when process supervision is handled by systemd or Kubernetes instead.

FAQ

What must be installed before cli-anything-pm2 works?

cli-anything-pm2 requires Python 3.10+, pip install -e . from the package, and PM2 installed globally via npm install -g pm2. The CLI invokes PM2 as a subprocess and remains stateless with no local session files.

Does cli-anything-pm2 support agent-friendly output?

cli-anything-pm2 supports JSON output flags for agent consumption alongside an interactive REPL when run without subcommands. Developers use JSON mode to list processes, restart workers, and read logs without fragile shell parsing.

CLI & Terminaldeployinframonitoring

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.