Skip to main content
Mole reading CLI docs

CLI Reference

Complete command-line interface reference for Muti Metroo.

HTTP API

All CLI commands that query agent state use the HTTP API to communicate with agents.

AspectDetails
Local queriesstatus, peers, routes
Remote operationsshell, upload, download
Default addresslocalhost:8080
Configurationhttp.address in config
# Query local agent (default: localhost:8080)
muti-metroo status
muti-metroo peers
muti-metroo routes

# Query different agent
muti-metroo status -a 192.168.1.10:8080
muti-metroo peers -a 192.168.1.10:8080

# Execute command on remote agent
muti-metroo shell <target-agent-id> whoami
muti-metroo shell --tty <target-agent-id> bash

# Transfer files
muti-metroo upload <target-agent-id> ./file.txt /tmp/file.txt
muti-metroo download <target-agent-id> /tmp/file.txt ./file.txt

Global Flags

Available for all commands:

  • -h, --help: Show help for command
  • -v, --version: Show version information

Commands

CommandDescription
runRun agent with configuration file
initInitialize agent identity
setupInteractive setup wizard
certCertificate management (CA, agent, client)
hashGenerate bcrypt password hash
statusShow agent status via HTTP API
peersList connected peers via HTTP API
routesList route table via HTTP API
shellInteractive or streaming remote shell
uploadUpload file to remote agent
downloadDownload file from remote agent
serviceService management (install, uninstall, status)
management-keyGenerate and manage mesh topology encryption keys

Quick Examples

# Start agent
muti-metroo run -c config.yaml

# Interactive setup
muti-metroo setup

# Generate CA
muti-metroo cert ca -n "My CA"

# Generate password hash for config
muti-metroo hash --cost 12

# Check agent status
muti-metroo status

# Check agent on different port
muti-metroo status -a localhost:9090

# List connected peers
muti-metroo peers

# List route table
muti-metroo routes

# Execute remote command
muti-metroo shell agent123 whoami
muti-metroo shell --tty agent123 bash

# Upload file
muti-metroo upload agent123 local.txt /tmp/remote.txt