Install
openclaw skills install huawei-cloud-cce-ops-report-generatorUse when generating consolidated CCE operations reports that combine daily inspection, capacity trend, availability risk, cost optimization, and on-call context into weekly, monthly, SLA, capacity, or stability reports with Markdown and HTML output. Trigger: user mentions "ops report", "运维报告", "report generation", "报告生成", "cluster report", "集群报告", "weekly report", "月度报告", "SLA report", "capacity report", "stability report", "operations summary", "运营总结", "consolidated report", "综合报告", "CCE reporting", "oncall report", "值班报告"
openclaw skills install huawei-cloud-cce-ops-report-generator⚠️ Execution Method (Must Read): This skill executes queries via the local Python dispatcher script. Using hcloud, openstack, or other CLI tools or direct API calls is prohibited.
- The dispatcher script is located at
scripts/huawei-cloud.pywithin the skill directory- All scripts and environment check scripts are inside the skill package. You must use
skill action=execto execute them. Do not run them directly in a shell.- Do not attempt hcloud, openstack, curl IAM, or any other CLI/API methods. This skill does not depend on those tools.
- All paths are relative to the skill directory, which is the directory where this SKILL.md is located.
This skill generates consolidated operations reports for Huawei Cloud CCE clusters. It aggregates outputs from daily inspection, capacity trend forecasting, availability risk scanning, cost optimization analysis, and optional on-call context into structured reports (weekly, monthly, SLA, capacity, stability). Default behavior is read-only analysis and report generation.
Architecture: Python dispatcher (scripts/huawei-cloud.py) → huawei_generate_ops_report → aggregates from huawei-cloud-cce-daily-cluster-inspector, huawei-cloud-cce-capacity-trend-forecaster, huawei-cloud-cce-availability-risk-scanner, huawei-cloud-cce-cost-optimization-advisor, on-call context → Markdown + HTML + JSON reports
| Skill | Purpose |
|---|---|
huawei-cloud-cce-daily-cluster-inspector | Daily health inspection and risk summarization |
huawei-cloud-cce-capacity-trend-forecaster | Capacity trend analysis, bottleneck forecasting, HPA simulation |
huawei-cloud-cce-availability-risk-scanner | Availability risk scanning (single replicas, PDB, AZ distribution) |
huawei-cloud-cce-cost-optimization-advisor | Cost optimization analysis (idle resources, oversized requests) |
huawei-cloud-cce-auto-remediation-runner | Execute remediation actions when user authorizes |
huawei_generate_ops_report)weekly, monthly, sla, capacity, stabilityinclude_raw=true)The dispatcher script requires Python >= 3.6 and the following packages:
huaweicloudsdkcorehuaweicloudsdkccehuaweicloudsdkaomhuaweicloudsdkhsshuaweicloudsdkvpchuaweicloudsdkecshuaweicloudsdkceshuaweicloudsdkevshuaweicloudsdkeiphuaweicloudsdkelbhuaweicloudsdkiamkubernetesmatplotlibnumpyInstall: pip3 install huaweicloudsdkcore huaweicloudsdkcce huaweicloudsdkaom huaweicloudsdkhss huaweicloudsdkvpc huaweicloudsdkecs huaweicloudsdkces huaweicloudsdkevs huaweicloudsdkeip huaweicloudsdkelb huaweicloudsdkiam kubernetes matplotlib numpy
| Variable | Required | Description |
|---|---|---|
HUAWEI_AK | Yes | Huawei Cloud Access Key |
HUAWEI_SK | Yes | Huawei Cloud Secret Key |
HUAWEI_REGION | No | Default region (overrides region param if set) |
HUAWEI_PROJECT_ID | No | Project ID (auto-obtained via IAM API when not set) |
HUAWEI_SECURITY_TOKEN | No | Required when using temporary AK/SK |
🚫 Never expose or log AK/SK values. Credentials exist only in the current request call stack and are released after each invocation. Do not write credentials to files, logs, or responses.
✅ Use environment variables HUAWEI_AK / HUAWEI_SK for authentication. The dispatcher reads them automatically.
This skill aggregates data from multiple sub-skills. It requires all permissions needed by:
| Sub-Skill | Required Permissions |
|---|---|
huawei-cloud-cce-daily-cluster-inspector | CCE cluster/node/workload/event read, AOM alarm read |
huawei-cloud-cce-capacity-trend-forecaster | CCE cluster/node/nodepool/Deployment/HPA read, AOM metrics read |
huawei-cloud-cce-availability-risk-scanner | CCE cluster/node/workload/PDB/Service/Ingress read, AOM metrics read |
huawei-cloud-cce-cost-optimization-advisor | CCE cluster/node/nodepool/Deployment/HPA/Pod read, AOM metrics read |
All actions are invoked via the dispatcher script:
python3 scripts/huawei-cloud.py <action> region=<region> cluster_id=<cluster_id> [key=value ...]
The primary action aggregates all sub-skill outputs into a consolidated report:
python3 scripts/huawei-cloud.py huawei_generate_ops_report \
region=cn-north-4 cluster_id=<cluster_id> \
report_type=weekly \
output_dir=./output
Returns: consolidated summary, cross-source recommendations, data gaps, and output files (Markdown, HTML, JSON, optional SVG charts).
For follow-up deep dives after report generation:
| Action | Source Skill | Description |
|---|---|---|
huawei_cce_auto_inspection | huawei-cloud-cce-daily-cluster-inspector | Full daily health inspection |
huawei_analyze_cce_capacity_trend | huawei-cloud-cce-capacity-trend-forecaster | Capacity trend analysis with simulation |
huawei_scan_cce_availability_risk | huawei-cloud-cce-availability-risk-scanner | Availability risk scan with remediation plan |
huawei_analyze_cce_cost_optimization | huawei-cloud-cce-cost-optimization-advisor | Cost optimization analysis |
huawei_generate_ops_report (Primary Action)| Parameter | Required | Default | Description |
|---|---|---|---|
region | Yes | - | Huawei Cloud region (e.g., cn-north-4) |
cluster_id | Yes | - | CCE cluster ID |
report_type | No | weekly | Report type: weekly, monthly, sla, capacity, stability |
hours | No | Auto (by type) | Analysis window in hours (overrides default for report type) |
short_hours | No | 24 | Short-period lookback for cost analysis |
long_hours | No | 168 | Long-period lookback for cost analysis |
exclude_namespaces | No | kube-system | Comma-separated namespaces excluded from business analysis |
business_namespaces | No | - | Comma-separated namespace allowlist for business Deployments |
gateway_keywords | No | nginx,gateway,ingress,proxy,kong,apisix,traefik | Keywords for identifying gateway-class workloads |
output_dir | No | - | Directory to persist Markdown, HTML, JSON reports and charts |
include_raw | No | false | Include raw source payloads for traceability |
oncall_report_path | No | - | Path to on-call report file for incident context |
oncall_summary | No | - | Inline on-call summary text for incident context |
| Report Type | Default Hours |
|---|---|
weekly | 168 |
monthly | 744 |
sla | 168 |
capacity | 168 |
stability | 168 |
| Region Name | Region ID |
|---|---|
| North China - Beijing 4 | cn-north-4 |
| North China - Beijing 1 | cn-north-1 |
| East China - Shanghai 1 | cn-east-3 |
| East China - Shanghai 2 | cn-east-2 |
| South China - Guangzhou | cn-south-1 |
| South China - Shenzhen | cn-south-4 |
| Southwest China - Guiyang 1 | cn-southwest-2 |
| Asia Pacific - Bangkok | ap-southeast-2 |
| Asia Pacific - Singapore | ap-southeast-1 |
| Asia Pacific - Hong Kong | ap-southeast-3 |
| Europe - Paris | eu-west-0 |
See references/output-schema.md for the complete JSON response schema.
When output_dir is specified, the following files are generated:
| File | Description |
|---|---|
ops-<type>-summary.json | Full structured JSON output with summaries, recommendations, and sources |
ops-<type>-report.md | Markdown report with cross-source analysis and recommendations |
ops-<type>-report.html | HTML report with embedded SVG trend charts |
ops-capacity-trend.svg | Capacity trend curve chart (when capacity data available) |
ops-capacity-simulation.svg | Capacity simulation chart (when simulation data available) |
ops-<type>-raw.json | Raw source payloads (when include_raw=true) |
| Field | Description |
|---|---|
scope | Report scope: region, cluster_id, excluded namespaces, gateway keywords |
report | Report metadata: type, hours, short_hours, long_hours |
summary.daily_cluster_inspector | Health status and anomaly count |
summary.capacity_trend_forecaster | CPU/memory averages, trend direction, simulation status |
summary.availability_risk_scanner | Risk level and issue count |
summary.cost_optimization_advisor | Underutilized nodes and oversized requests count |
summary.oncall_copilot | On-call context status, source, and summary |
recommendations | Prioritized cross-source recommendation list with source and risk level |
data_gaps | List of sources that failed or had missing data |
sources | Per-source success status and file paths |
files | Output file paths for all generated artifacts |
region, cluster_id, report type, time window, namespace scope, and output directory from userhuawei_generate_ops_report — it aggregates from all five sources internallyhuawei-cloud-cce-daily-cluster-inspectorhuawei-cloud-cce-availability-risk-scannerhuawei-cloud-cce-cost-optimization-advisorhuawei-cloud-cce-capacity-trend-forecasterhuawei-cloud-cce-auto-remediation-runnerinclude_raw=true) for auditabilitypython3 scripts/huawei-cloud.py huawei_generate_ops_report \
region=cn-north-4 cluster_id=<cluster-id> \
report_type=weekly output_dir=./output
success=true and all four source summaries are presentrecommendations lists cross-source items with [source][risk_level] prefixesdata_gaps is empty when all sources succeedops-weekly-report.md and ops-weekly-report.html are generated in output_dirinclude_raw=true and verify ops-weekly-raw.json contains source payloadsoncall_summary="Test incident" and verify on-call context appears in summaryhuawei_generate_ops_report as the primary action; it aggregates all sources in one callweekly for weekly reviews, monthly for monthly summaries, sla for SLA tracking, capacity for capacity planning, stability for stability assessmentoutput_dir to persist reports for audit and stakeholder reviewinclude_raw=true to preserve source payloadsoncall_report_path or oncall_summary to enrich the reporthuawei-cloud-cce-auto-remediation-runner| Document | Description |
|---|---|
references/workflow.md | Detailed execution process, scope validation, and data gap handling |
references/output-schema.md | Complete JSON response schema for report output |
huawei-cloud-cce-auto-remediation-runner with user authorizationpython3 scripts/huawei-cloud.py <action>; do not use hcloud CLI or direct API calls| Pitfall | Correct Approach |
|---|---|
| Assuming report fails when one source fails | The report continues with degraded sources; data gaps are explicitly listed |
| Skipping on-call context entirely when unavailable | Mark as a context gap; the report still provides value from other sources |
| Executing remediation directly from report findings | All remediation requires explicit user authorization; hand off to huawei-cloud-cce-auto-remediation-runner |
Not using output_dir for persistent reports | Always specify output_dir for audit traceability and stakeholder access |
| Treating recommendations as action items without risk context | Each recommendation includes [source][risk_level] prefix; prioritize by risk level |
Ignoring include_raw for compliance requirements | Use include_raw=true when audit traceability of source data is required |
Using wrong report_type for the reporting cycle | Match report type to cycle: weekly=168h, monthly=744h, sla/capacity/stability=168h by default |