# Send aws-ecs-monitor to your agent
Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.
## Fast path
- Download the package from Yavira.
- Extract it into a folder your agent can access.
- Paste one of the prompts below and point your agent at the extracted folder.
## Suggested prompts
### New install

```text
I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete.
```
### Upgrade existing

```text
I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run.
```
## Machine-readable fields
```json
{
  "schemaVersion": "1.0",
  "item": {
    "slug": "aws-ecs-monitor",
    "name": "aws-ecs-monitor",
    "source": "tencent",
    "type": "skill",
    "category": "其他",
    "sourceUrl": "https://clawhub.ai/briancolinger/aws-ecs-monitor",
    "canonicalUrl": "https://clawhub.ai/briancolinger/aws-ecs-monitor",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadUrl": "/downloads/aws-ecs-monitor",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=aws-ecs-monitor",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "packageFormat": "ZIP package",
    "primaryDoc": "SKILL.md",
    "includedAssets": [
      "SKILL.md",
      "scripts/cloudwatch-logs.sh",
      "scripts/ecs-health.sh"
    ],
    "downloadMode": "redirect",
    "sourceHealth": {
      "source": "tencent",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-04-23T16:43:11.935Z",
      "expiresAt": "2026-04-30T16:43:11.935Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=4claw-imageboard",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=4claw-imageboard",
        "contentDisposition": "attachment; filename=\"4claw-imageboard-1.0.1.zip\"",
        "redirectLocation": null,
        "bodySnippet": null
      },
      "scope": "source",
      "summary": "Source download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this source.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/aws-ecs-monitor"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    }
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/aws-ecs-monitor",
    "downloadUrl": "https://openagent3.xyz/downloads/aws-ecs-monitor",
    "agentUrl": "https://openagent3.xyz/skills/aws-ecs-monitor/agent",
    "manifestUrl": "https://openagent3.xyz/skills/aws-ecs-monitor/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/aws-ecs-monitor/agent.md"
  }
}
```
## Documentation

### AWS ECS Monitor

Production health monitoring and log analysis for AWS ECS services.

### What It Does

Health Checks: HTTP probes against your domain, ECS service status (desired vs running), ALB target group health, SSL certificate expiry
Log Analysis: Pulls CloudWatch logs, categorizes errors (panics, fatals, OOM, timeouts, 5xx), detects container restarts, filters health check noise
Auto-Diagnosis: Reads health status and automatically investigates failing services via log analysis

### Prerequisites

aws CLI configured with appropriate IAM permissions:

ecs:ListServices, ecs:DescribeServices
elasticloadbalancing:DescribeTargetGroups, elasticloadbalancing:DescribeTargetHealth
logs:FilterLogEvents, logs:DescribeLogGroups


curl for HTTP health checks
python3 for JSON processing and log analysis
openssl for SSL certificate checks (optional)

### Configuration

All configuration is via environment variables:

VariableRequiredDefaultDescriptionECS_CLUSTERYes—ECS cluster nameECS_REGIONNous-east-1AWS regionECS_DOMAINNo—Domain for HTTP/SSL checks (skip if unset)ECS_SERVICESNoauto-detectComma-separated service names to monitorECS_HEALTH_STATENo./data/ecs-health.jsonPath to write health state JSONECS_HEALTH_OUTDIRNo./data/Output directory for logs and alertsECS_LOG_PATTERNNo/ecs/{service}CloudWatch log group pattern ({service} is replaced)ECS_HTTP_ENDPOINTSNo—Comma-separated name=url pairs for HTTP probes

### Directories Written

ECS_HEALTH_STATE (default: ./data/ecs-health.json) — Health state JSON file
ECS_HEALTH_OUTDIR (default: ./data/) — Output directory for logs, alerts, and analysis reports

### scripts/ecs-health.sh — Health Monitor

# Full check
ECS_CLUSTER=my-cluster ECS_DOMAIN=example.com ./scripts/ecs-health.sh

# JSON output only
ECS_CLUSTER=my-cluster ./scripts/ecs-health.sh --json

# Quiet mode (no alerts, just status file)
ECS_CLUSTER=my-cluster ./scripts/ecs-health.sh --quiet

Exit codes: 0 = healthy, 1 = unhealthy/degraded, 2 = script error

### scripts/cloudwatch-logs.sh — Log Analyzer

# Pull raw logs from a service
ECS_CLUSTER=my-cluster ./scripts/cloudwatch-logs.sh pull my-api --minutes 30

# Show errors across all services
ECS_CLUSTER=my-cluster ./scripts/cloudwatch-logs.sh errors all --minutes 120

# Deep analysis with error categorization
ECS_CLUSTER=my-cluster ./scripts/cloudwatch-logs.sh diagnose --minutes 60

# Detect container restarts
ECS_CLUSTER=my-cluster ./scripts/cloudwatch-logs.sh restarts my-api

# Auto-diagnose from health state file
ECS_CLUSTER=my-cluster ./scripts/cloudwatch-logs.sh auto-diagnose

# Summary across all services
ECS_CLUSTER=my-cluster ./scripts/cloudwatch-logs.sh summary --minutes 120

Options: --minutes N (default: 60), --json, --limit N (default: 200), --verbose

### Auto-Detection

When ECS_SERVICES is not set, both scripts auto-detect services from the cluster:

aws ecs list-services --cluster $ECS_CLUSTER

Log groups are resolved by pattern (default /ecs/{service}). Override with ECS_LOG_PATTERN:

# If your log groups are /ecs/prod/my-api, /ecs/prod/my-frontend, etc.
ECS_LOG_PATTERN="/ecs/prod/{service}" ECS_CLUSTER=my-cluster ./scripts/cloudwatch-logs.sh diagnose

### Integration

The health monitor can trigger the log analyzer for auto-diagnosis when issues are detected. Set ECS_HEALTH_OUTDIR to a shared directory and run both scripts together:

export ECS_CLUSTER=my-cluster
export ECS_DOMAIN=example.com
export ECS_HEALTH_OUTDIR=./data

# Run health check (auto-triggers log analysis on failure)
./scripts/ecs-health.sh

# Or run log analysis independently
./scripts/cloudwatch-logs.sh auto-diagnose --minutes 30

### Error Categories

The log analyzer classifies errors into:

panic — Go panics
fatal — Fatal errors
oom — Out of memory
timeout — Connection/request timeouts
connection_error — Connection refused/reset
http_5xx — HTTP 500-level responses
python_traceback — Python tracebacks
exception — Generic exceptions
auth_error — Permission/authorization failures
structured_error — JSON-structured error logs
error — Generic ERROR-level messages

Health check noise (GET/HEAD /health from ALB) is automatically filtered from error counts and HTTP status distribution.
## Trust
- Source: tencent
- Verification: Indexed source record
- Publisher: briancolinger
- Version: 1.0.1
## Source health
- Status: healthy
- Source download looks usable.
- Yavira can redirect you to the upstream package for this source.
- Health scope: source
- Reason: direct_download_ok
- Checked at: 2026-04-23T16:43:11.935Z
- Expires at: 2026-04-30T16:43:11.935Z
- Recommended action: Download for OpenClaw
## Links
- [Detail page](https://openagent3.xyz/skills/aws-ecs-monitor)
- [Send to Agent page](https://openagent3.xyz/skills/aws-ecs-monitor/agent)
- [JSON manifest](https://openagent3.xyz/skills/aws-ecs-monitor/agent.json)
- [Markdown brief](https://openagent3.xyz/skills/aws-ecs-monitor/agent.md)
- [Download page](https://openagent3.xyz/downloads/aws-ecs-monitor)