huawei-cloud-terraform-generator
БесплатноБез исполняемых скриптовНе проверенGenerate Huawei Cloud Terraform configurations and execute deployment with user-guided approval. Use this skill when users want to create Huawei Cloud…
от huaweicloud★ 59 звёзд на GitHubОб этом скилле
Huawei Cloud Terraform Generator
1. Overview
This skill turns user infrastructure goals into Terraform configurations for Huawei Cloud. The primary workflow is to:
- understand the user's actual deployment intent
- determine which resources should be created
- determine whether existing resources should be reused
- confirm key specifications and dependencies
- verify every resource specification against the target region's available resources — query first, write later
- ensure Terraform is installed
- generate Terraform configuration files
- run validation steps and fix generation issues until
terraform plansucceeds - ask user for confirmation and execute
terraform applyif approved
This skill provides an interactive workflow where the agent guides the user through credential configuration, validates the plan, and executes apply upon explicit user confirmation.
2. Prerequisites
Before using this skill, ensure the following are available:
- Terraform — installed in PATH or auto-installable (see validation-workflow.md)
- Provider download source — the Huawei Cloud mirror should be reachable (see validation-workflow.md)
- Target region — the deployment region (e.g. cn-north-4, cn-south-1) must be identified
- Windows long-path support (Windows only) — this skill ships a deep
reference/**+assets/**tree, andgit cloneon Windows can abort withFilename too longand leave an incomplete work tree. Before cloning on Windows:- prefer a short clone root (e.g.
D:\hw-skills) instead of a deeply nested project directory; - or enable long paths for that single command:
git clone -c core.longpaths=true https://gitcode.com/developer-skill/huaweicloud-skills.git; - if an existing clone already has an incomplete work tree, repair it in place:
git config core.longpaths true && git checkout -f. Linux/macOS need no special handling for these paths.
- prefer a short clone root (e.g.
3. Parameter Confirmation
Before generating Terraform, propose a concrete resource plan for the user to confirm. The plan should include:
- recommended resource specifications
- available candidate options when applicable
- whether to create new resources or reuse existing ones
- pricing information only when obtained from a reliable source
See reference/guardrails.md for rules about not fabricating specifications and prices.
Do not ask the user to provide every parameter manually. Instead:
- infer the likely architecture from the user's goal
- propose a concrete plan with recommended defaults
- confirm only the small number of decisions that materially affect correctness, cost, or architecture
Users should mainly confirm a proposed solution, not build the full parameter set themselves.
4. Workflow
This skill works in nine phases:
4.0 Credential handling (MUST READ)
AK/SK credentials are read from environment variables HW_ACCESS_KEY and HW_SECRET_KEY (plus HW_SECURITY_TOKEN or HUAWEICLOUD_SECURITY_TOKEN for temporary/STS). They authenticate the Terraform provider only — they are NOT written into the FunctionGraph function user_data, which holds only a pre-created DevBridge API Key (see reference/ecs-devbridge-option.md).
Because the provider does not reliably resolve security_token from env vars, the agent must write it to terraform.tfvars as security_token when using temporary/STS credentials. AK/SK themselves may be passed via TF_VAR_access_key / TF_VAR_secret_key.
DevBridge API Key handling: the key MUST be pre-created in the sandbox before apply — reuse the sandbox key if valid, otherwise create one via DevStage API using the sandbox's user-level AK/SK (which DevStage accepts). Pass it as devbridge_api_key. The FunctionGraph function only forwards this key and never creates keys, so it carries no AK/SK.
Before any step that depends on credentials (resource queries, terraform plan, etc.), read the complete rules in reference/guardrails.md.
If an API or Terraform call fails with an authentication error: tell the user the specific error, ask them to confirm when the issue is resolved, then retry. Do not guide the user on how to configure credentials.
4.1 Understand the user's real goal
The user may describe a resource directly, such as creating an ECS instance, or describe a business goal, such as deploying a website or launching an application.
You must first infer the intended Huawei Cloud architecture from the user's objective, not just from explicit resource names.
4.2 Determine the resource set
Based on the user's goal, identify:
- which resources need to be created
- which existing resources may be reused
- what dependencies exist between the resources
For example:
- a simple
Установить huawei-cloud-terraform-generator в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл huawei-cloud-terraform-generator?
Generate Huawei Cloud Terraform configurations and execute deployment with user-guided approval. Use this skill when users want to create Huawei Cloud infrastructure as Terraform, whether they ask explicitly for Terraform or describe goals such as deploying a website, launching an application, or creating network, compute, database, load balancing, or storage resources. Trigger when users mention 创建/create、生成/generate、部署/deploy、配置/configure、使用/use、管理/manage、华为云/Huawei Cloud、Terraform、ECS、VPC、资源/resource、云服务器/ECS、虚拟机/VM、实例/instance、网络/network、负载均衡/ELB、数据库/database、RDS、存储/storage、OBS、桶/bucket、域名/domain、DNS、证书/certificate、SSL、监控/monitoring、日志/log、备份/backup、容器/container、CCE、函数工作流/FunctionGraph
Как установить скилл huawei-cloud-terraform-generator?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл huawei-cloud-terraform-generator запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
ci-review
The scan that the plugin's GitHub Action runs.
от Anthropicazure-static-web-apps
Helps create, configure, and deploy Azure Static Web Apps using the SWA CLI. Use when deploying static sites to Azure, setting up SWA local development…
от GitHubai-ready
Make any repo AI-ready — analyzes your codebase and generates AGENTS.md, copilot-instructions.md, CI workflows, issue templates, and more. Mines your PR…
от GitHubaws-cdk-python-setup
Setup and initialization guide for developing AWS CDK (Cloud Development Kit) applications in Python. This skill enables users to configure environment…
от GitHub