用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/krmorehead/vm_builds --skill build-entry-point命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
正在显示 SKILL.md
基于 SOC 职业分类
| name | build-entry-point |
| description | Build.py orchestration patterns. Shell scripts MUST delegate, host probing with fallback, env validation. |
source .venv/bin/activate
set -a; source .env; set +a
python3 build.py "$@"
def resolve_proxmox_host() -> str:
for ip in get_candidate_hosts():
if probe_host(ip):
return ip
raise RuntimeError("No reachable Proxmox host found")
def resolve_playbook(playbook: str) -> Path:
if (p := Path(playbook)).exists():
return p
if (p := Path(f"playbooks/{playbook}")).exists():
return p
if (p := Path(f"playbooks/{playbook}.yml")).exists():
return p
raise FileNotFoundError(f"Playbook not found: {playbook}")
# build.py
REQUIRED_ENV = ['PRIMARY_HOST', 'MESH_KEY']
# Ansible role defaults
wan_mac: "{{ lookup('env', 'WAN_MAC') | default('', true) }}"
def build_command(playbook: Path, extra_vars: dict, tags: list, skip_tags: list) -> list:
cmd = ['ansible-playbook', str(playbook)]
if extra_vars:
cmd.extend(['--extra-vars', format_extra_vars(extra_vars)])
if tags:
cmd.extend(['--tags', ','.join(tags)])
if skip_tags:
cmd.extend(['--skip-tags', ','.join(skip_tags)])
return cmd
.env had PRIMARY_HOST="192.168.1.100" with literal quotes. SSH connected to "192.168.1.100" (with quotes) and hung. Fix: build.py strips surrounding quotes during env parsing.sys.exit() in library function: find_ansible_playbook() called sys.exit(1) on error instead of returning None or raising. This made the function untestable and killed the process in unexpected places.TestBuildCommand.