openclaw 网盘下载
OpenClaw

技能详情(站内镜像,无评论)

首页 > 技能库 > Spot Strategy

Design an interruption-resilient EC2 Spot instance strategy with fallback configurations

开发与 DevOps

作者:Anmol Nagpal @anmolnagpal

许可证:MIT-0

MIT-0 ·免费使用、修改和重新分发。无需归因。

版本:v1.0.0

统计:⭐ 0 · 201 · 0 current installs · 0 all-time installs

0

安装量(当前) 0

🛡 VirusTotal :良性 · OpenClaw :良性

Package:anmolnagpal/spot-strategy

安全扫描(ClawHub)

  • VirusTotal :良性
  • OpenClaw :良性

OpenClaw 评估

The skill is an instruction-only helper for designing EC2 Spot strategies and its inputs/requirements are consistent with that purpose.

目的

Name/description ask for Spot strategy design and the SKILL.md only requests EC2 inventory, ASG config, and cost data — all are expected inputs for this purpose. No unrelated credentials, binaries, or installs are requested.

说明范围

The skill asks users to paste AWS CLI/console output (describe-instances, ASG, cost reports). This is appropriate for analysis but may include sensitive metadata (account IDs, instance IDs, private IPs, tags, AMI IDs). The SKILL.md explicitly forbids asking for credentials and asks to confirm no credentials are included before processing — that's good practice.

安装机制

Instruction-only skill with no install spec and no code files; nothing is written to disk or downloaded.

证书

No environment variables, credentials, or config paths are requested. The SKILL.md recommends only read-only CLI outputs and provides a minimal read-only IAM policy for those who want to run the commands themselves.

持久

The skill does not request persistent/always-on presence (always:false) and does not ask to modify other skills or system settings. Model invocation is allowed (default), which is normal for skills and acceptable here.

综合结论

This skill appears coherent and appropriate for designing Spot strategies. Before sharing data: verify any pasted CLI/console output contains no access keys or secrets (the skill requests only read-only outputs), consider redacting tags, account IDs, private IPs, or other identifiers if you are uncomfortable sharing them, and provide the minimum necessary data (a sample of instances or a summary) rather than full dumps when possible. If you pr…

安装(复制给龙虾 AI)

将下方整段复制到龙虾中文库对话中,由龙虾按 SKILL.md 完成安装。

请把本段交给龙虾中文库(龙虾 AI)执行:为本机安装 OpenClaw 技能「Spot Strategy」。简介:Design an interruption-resilient EC2 Spot instance strategy with fallback confi…。
请 fetch 以下地址读取 SKILL.md 并按文档完成安装:https://raw.githubusercontent.com/openclaw/skills/refs/heads/main/skills/anmolnagpal/spot-strategy/SKILL.md
(来源:yingzhi8.cn 技能库)

SKILL.md

打开原始 SKILL.md(GitHub raw)

---
name: aws-spot-strategy
description: Design an interruption-resilient EC2 Spot instance strategy with fallback configurations
tools: claude, bash
version: "1.0.0"
pack: aws-cost
tier: pro
price: 29/mo
permissions: read-only
credentials: none — user provides exported data
---

# AWS Spot Instance Strategy Builder

You are an AWS Spot instance expert. Design a cost-optimal, interruption-resilient Spot strategy.

> **This skill is instruction-only. It does not execute any AWS CLI commands or access your AWS account directly. You provide the data; Claude analyzes it.**

## Required Inputs

Ask the user to provide **one or more** of the following (the more provided, the better the analysis):

1. **EC2 instance inventory** — current instance types, sizes, and AZs
   ```bash
   aws ec2 describe-instances 
     --query 'Reservations[].Instances[].{ID:InstanceId,Type:InstanceType,State:State.Name,AZ:Placement.AvailabilityZone}' 
     --output json
   ```
2. **Auto Scaling Group configuration** — existing ASG and launch template settings
   ```bash
   aws autoscaling describe-auto-scaling-groups --output json
   ```
3. **EC2 spend breakdown by usage type** — to calculate Spot savings potential
   ```bash
   aws ce get-cost-and-usage 
     --time-period Start=2025-02-01,End=2025-04-01 
     --granularity MONTHLY 
     --filter '{"Dimensions":{"Key":"SERVICE","Values":["Amazon EC2"]}}' 
     --group-by '[{"Type":"DIMENSION","Key":"USAGE_TYPE"}]' 
     --metrics BlendedCost
   ```

**Minimum required IAM permissions to run the CLI commands above (read-only):**
```json
{
  "Version": "2012-10-17",
  "Statement": [{
    "Effect": "Allow",
    "Action": ["ec2:DescribeInstances", "ec2:DescribeSpotPriceHistory", "autoscaling:Describe*", "ce:GetCostAndUsage"],
    "Resource": "*"
  }]
}
```

If the user cannot provide any data, ask them to describe: your workloads (stateless/stateful, fault-tolerant?), current EC2 instance types, and approximate monthly EC2 spend.


## Steps
1. Classify workloads: fault-tolerant (Spot-safe) vs stateful (Spot-unsafe)
2. For each Spot-eligible workload, recommend instance family diversification (3+ families)
3. Score interruption risk per instance type using Spot placement score heuristics
4. Design fallback chain: Spot → On-Demand → Savings Plan
5. Generate Auto Scaling Group / Karpenter configuration

## Output Format
- **Workload Eligibility Matrix**: workload, Spot-safe (Y/N), reason
- **Spot Fleet Recommendation**: instance families, AZs, allocation strategy
- **Interruption Risk Table**: instance type, region, estimated interruption frequency
- **Fallback Architecture**: layered purchasing strategy per workload
- **Savings Estimate**: on-demand cost vs Spot cost with % savings
- **Karpenter NodePool YAML** (if EKS context detected)

## Rules
- Always recommend at least 3 instance families for Spot diversification
- Flag stateful workloads (databases, single-replica services) as NOT Spot-safe
- Recommend `capacity-optimized` allocation strategy over `lowest-price`
- Include interruption handling: graceful shutdown hooks, checkpoint patterns
- Never ask for credentials, access keys, or secret keys — only exported data or CLI/console output
- If user pastes raw data, confirm no credentials are included before processing