⚠️ 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
SkillPurposehuawei-cloud-cce-daily-cluster-inspectorDaily health inspection and risk summarizationhuawei-cloud-cce-capacity-trend-forecasterCapacity trend analysis, bottleneck forecasting, HPA simulationhuawei-cloud-cce-availability-risk-scannerAvailability risk scanning (single replicas, PDB, AZ distribution)huawei-cloud-cce-cost-optimization-advisorCost optimization analysis (idle resources, oversized requests)huawei-cloud-cce-auto-remediation-runnerExecute 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
VariableRequiredDescriptionHUAWEI_AKYesHuawei Cloud Access KeyHUAWEI_SKYesHuawei Cloud Secret KeyHUAWEI_REGIONNoDefault region (overrides region param if set)HUAWEI_PROJECT_IDNoProject ID (auto-obtained via IAM API when not set)HUAWEI_SECURITY_TOKENNoRequired 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-SkillRequired Permissionshuawei-cloud-cce-daily-cluster-inspectorCCE cluster/node/workload/event read, AOM alarm readhuawei-cloud-cce-capacity-trend-forecasterCCE cluster/node/nodepool/Deployment/HPA read, AOM metrics readhuawei-cloud-cce-availability-risk-scannerCCE cluster/node/workload/PDB/Service/Ingress read, AOM metrics readhuawei-cloud-cce-cost-optimization-advisorCCE cluster/node/nodepool/Deployment/HPA/Pod read, AOM metrics read
All actions are invoked via the dispatcher script:
bash
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:
bash
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:
ActionSource SkillDescriptionhuawei_cce_auto_inspection``huawei-cloud-cce-daily-cluster-inspectorFull daily health inspectionhuawei_analyze_cce_capacity_trend``huawei-cloud-cce-capacity-trend-forecasterCapacity trend analysis with simulationhuawei_scan_cce_availability_risk``huawei-cloud-cce-availability-risk-scannerAvailability risk scan with remediation planhuawei_analyze_cce_cost_optimization``huawei-cloud-cce-cost-optimization-advisorCost optimization analysis
huawei_generate_ops_report (Primary Action)#ParameterRequiredDefaultDescriptionregionYes-Huawei Cloud region (e.g., cn-north-4)cluster_idYes-CCE cluster IDreport_typeNoweeklyReport type: weekly, monthly, sla, capacity, stability``hoursNoAuto (by type)Analysis window in hours (overrides default for report type)short_hoursNo24Short-period lookback for cost analysislong_hoursNo168Long-period lookback for cost analysisexclude_namespacesNokube-systemComma-separated namespaces excluded from business analysisbusiness_namespacesNo-Comma-separated namespace allowlist for business Deploymentsgateway_keywordsNonginx,gateway,ingress,proxy,kong,apisix,traefikKeywords for identifying gateway-class workloadsoutput_dirNo-Directory to persist Markdown, HTML, JSON reports and chartsinclude_rawNofalseInclude raw source payloads for traceabilityoncall_report_pathNo-Path to on-call report file for incident contextoncall_summaryNo-Inline on-call summary text for incident context
Report TypeDefault Hoursweekly168monthly744sla168capacity168stability168
Region NameRegion IDNorth China - Beijing 4cn-north-4North China - Beijing 1cn-north-1East China - Shanghai 1cn-east-3East China - Shanghai 2cn-east-2South China - Guangzhoucn-south-1South China - Shenzhencn-south-4Southwest China - Guiyang 1cn-southwest-2Asia Pacific - Bangkokap-southeast-2Asia Pacific - Singaporeap-southeast-1Asia Pacific - Hong Kongap-southeast-3Europe - Pariseu-west-0
See references/output-schema.md for the complete JSON response schema.
When output_dir is specified, the following files are generated:
FileDescriptionops-<type>-summary.jsonFull structured JSON output with summaries, recommendations, and sourcesops-<type>-report.mdMarkdown report with cross-source analysis and recommendationsops-<type>-report.htmlHTML report with embedded SVG trend chartsops-capacity-trend.svgCapacity trend curve chart (when capacity data available)ops-capacity-simulation.svgCapacity simulation chart (when simulation data available)ops-<type>-raw.jsonRaw source payloads (when include_raw=true)
FieldDescriptionscopeReport scope: region, cluster_id, excluded namespaces, gateway keywordsreportReport metadata: type, hours, short_hours, long_hourssummary.daily_cluster_inspectorHealth status and anomaly countsummary.capacity_trend_forecasterCPU/memory averages, trend direction, simulation statussummary.availability_risk_scannerRisk level and issue countsummary.cost_optimization_advisorUnderutilized nodes and oversized requests countsummary.oncall_copilotOn-call context status, source, and summaryrecommendationsPrioritized cross-source recommendation list with source and risk leveldata_gapsList of sources that failed or had missing datasourcesPer-source success status and file pathsfilesOutput 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 auditabilityRun a weekly report with a known cluster: bash
python3 scripts/huawei-cloud.py huawei_generate_ops_report \
region=cn-north-4 cluster_id=<cluster-id> \
report_type=weekly output_dir=./output
Verify success=true and all four source summaries are present
Check that recommendations lists cross-source items with [source][risk_level] prefixes
Verify data_gaps is empty when all sources succeed
Confirm ops-weekly-report.md and ops-weekly-report.html are generated in output_dir
Test with include_raw=true and verify ops-weekly-raw.json contains source payloads
Test with oncall_summary="Test incident" and verify on-call context appears in summary
huawei_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-runnerDocumentDescriptionreferences/workflow.mdDetailed execution process, scope validation, and data gap handlingreferences/output-schema.mdComplete 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 callsPitfallCorrect ApproachAssuming report fails when one source failsThe report continues with degraded sources; data gaps are explicitly listedSkipping on-call context entirely when unavailableMark as a context gap; the report still provides value from other sourcesExecuting remediation directly from report findingsAll remediation requires explicit user authorization; hand off to huawei-cloud-cce-auto-remediation-runnerNot using output_dir for persistent reportsAlways specify output_dir for audit traceability and stakeholder accessTreating recommendations as action items without risk contextEach recommendation includes [source][risk_level] prefix; prioritize by risk levelIgnoring include_raw for compliance requirementsUse include_raw=true when audit traceability of source data is requiredUsing wrong report_type for the reporting cycleMatch report type to cycle: weekly=168h, monthly=744h, sla/capacity/stability=168h by default