huaweicloud-devkit 1.1.1-next.3 → 1.1.1-next.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +6 -1
- package/plugins/huaweicloud-core/.claude-plugin/plugin.json +1 -1
- package/plugins/huaweicloud-core/.codex-plugin/plugin.json +1 -1
- package/plugins/huaweicloud-core/.cursor-plugin/plugin.json +1 -1
- package/plugins/huaweicloud-core/.hermes-plugin/plugin.json +1 -1
- package/plugins/huaweicloud-core/.workbuddy-plugin/plugin.json +1 -1
- package/plugins/huaweicloud-core/openclaw.plugin.json +1 -1
- package/plugins/huaweicloud-core/skills/huawei-ecs/SKILL.md +8 -8
- package/plugins/huaweicloud-core/src/hcloud-cli.mjs +11 -6
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "huaweicloud-devkit",
|
|
3
|
-
"version": "1.1.1-next.
|
|
3
|
+
"version": "1.1.1-next.5",
|
|
4
4
|
"description": "Agent toolkit that helps coding agents use Huawei Cloud Skills, KooCLI, APIs, SDKs, and future MCP capabilities safely and accurately.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"files": [
|
|
@@ -17,6 +17,11 @@
|
|
|
17
17
|
"type": "git",
|
|
18
18
|
"url": "https://github.com/huaweicloud/huaweicloud-devkit.git"
|
|
19
19
|
},
|
|
20
|
+
"dsh": {
|
|
21
|
+
"bundle": {
|
|
22
|
+
"patch": "./cordis.patch.yml"
|
|
23
|
+
}
|
|
24
|
+
},
|
|
20
25
|
"scripts": {
|
|
21
26
|
"test": "node --test",
|
|
22
27
|
"format": "prettier --write .",
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"mcpServers": "./.mcp.json",
|
|
18
18
|
"description": "Guide coding agents to use Huawei Cloud Skills, KooCLI, APIs, SDKs, and future MCP capabilities with safer execution and less context.",
|
|
19
19
|
"skills": "./skills/",
|
|
20
|
-
"version": "1.1.1-next.
|
|
20
|
+
"version": "1.1.1-next.5",
|
|
21
21
|
"author": {
|
|
22
22
|
"name": "HuaweiCloud Mate",
|
|
23
23
|
"url": "https://github.com/huaweicloud"
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"mcpServers": "./.mcp.json",
|
|
21
21
|
"description": "Agent toolkit that helps coding agents use Huawei Cloud Skills, KooCLI, APIs, SDKs, and future MCP capabilities safely and accurately.",
|
|
22
22
|
"skills": "./skills/",
|
|
23
|
-
"version": "1.1.1-next.
|
|
23
|
+
"version": "1.1.1-next.5",
|
|
24
24
|
"author": {
|
|
25
25
|
"name": "HuaweiCloud Mate",
|
|
26
26
|
"url": "https://github.com/huaweicloud"
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"mcpServers": "./.mcp.json",
|
|
18
18
|
"description": "Guide coding agents to use Huawei Cloud Skills, KooCLI, APIs, SDKs, and future MCP capabilities with safer execution and less context.",
|
|
19
19
|
"skills": "./skills/",
|
|
20
|
-
"version": "1.1.1-next.
|
|
20
|
+
"version": "1.1.1-next.5",
|
|
21
21
|
"author": {
|
|
22
22
|
"name": "HuaweiCloud Mate",
|
|
23
23
|
"url": "https://github.com/huaweicloud"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "huaweicloud-devkit",
|
|
3
|
-
"version": "1.1.1-next.
|
|
3
|
+
"version": "1.1.1-next.5",
|
|
4
4
|
"description": "Guide coding agents to use Huawei Cloud Skills, KooCLI, APIs, SDKs, and future MCP capabilities with safer execution and less context.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "HuaweiCloud Mate",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "huaweicloud-devkit",
|
|
3
|
-
"version": "1.1.1-next.
|
|
3
|
+
"version": "1.1.1-next.5",
|
|
4
4
|
"description": "Guide coding agents to use Huawei Cloud Skills, KooCLI, APIs, SDKs, and future MCP capabilities with safer execution and less context.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "HuaweiCloud Mate",
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "huaweicloud-devkit",
|
|
3
3
|
"id": "huaweicloud-devkit",
|
|
4
4
|
"displayName": "HuaweiCloud DevKit",
|
|
5
|
-
"version": "1.1.1-next.
|
|
5
|
+
"version": "1.1.1-next.5",
|
|
6
6
|
"family": "bundle-plugin",
|
|
7
7
|
"bundleFormat": "codex",
|
|
8
8
|
"description": "Guide coding agents to use Huawei Cloud safely — KooCLI, APIs, SDKs, 28 MCP tools, skills, and safety guardrails.",
|
|
@@ -28,14 +28,14 @@ If these do not exist, load the `huawei-vpc` skill first and create them before
|
|
|
28
28
|
|
|
29
29
|
## Critical Warnings
|
|
30
30
|
|
|
31
|
-
| Trap | Why
|
|
32
|
-
| ------------------------------- |
|
|
33
|
-
| Flavor not in region | Not all flavors available everywhere. Check with ECS ListFlavors first
|
|
34
|
-
| Security group denies all | New SGs deny ALL inbound. Must explicitly add rules
|
|
35
|
-
| Reusing existing security group | Existing SGs may have 0.0.0.0/0 rules. Before referencing, run hcloud VPC ListSecurityGroupRules --security_group_id=<id> to audit inbound rules |
|
|
36
|
-
| EIP bills when idle | Unattached EIP still incurs charges
|
|
37
|
-
| Stopped instance still bills | Pay-per-use instances bill when stopped (unless shutdown-no-billing flavor)
|
|
38
|
-
| Disk survives instance delete | Deleting instance does NOT delete system disk by default
|
|
31
|
+
| Trap | Why |
|
|
32
|
+
| ------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
33
|
+
| Flavor not in region | Not all flavors available everywhere. Check with ECS ListFlavors first |
|
|
34
|
+
| Security group denies all | New SGs deny ALL inbound. Must explicitly add rules |
|
|
35
|
+
| Reusing existing security group | Existing SGs may have 0.0.0.0/0 rules. Before referencing, run hcloud VPC ListSecurityGroupRules --security_group_id.1=<id> to audit inbound rules |
|
|
36
|
+
| EIP bills when idle | Unattached EIP still incurs charges |
|
|
37
|
+
| Stopped instance still bills | Pay-per-use instances bill when stopped (unless shutdown-no-billing flavor) |
|
|
38
|
+
| Disk survives instance delete | Deleting instance does NOT delete system disk by default |
|
|
39
39
|
|
|
40
40
|
## Flavor Selection Guide
|
|
41
41
|
|
|
@@ -58,16 +58,19 @@ function preflightSecurityGroupCheck(normalizedArgs) {
|
|
|
58
58
|
|
|
59
59
|
const sgIds = [];
|
|
60
60
|
for (const arg of normalizedArgs) {
|
|
61
|
-
const m = arg.match(
|
|
62
|
-
if (m) sgIds.push(m[
|
|
61
|
+
const m = arg.match(/^(?:--security_group_id(?:\.\d+)?|--server\.security_groups(?:\.\d+)?\.id)=(.+)/);
|
|
62
|
+
if (m) sgIds.push(m[1]);
|
|
63
63
|
}
|
|
64
64
|
if (sgIds.length === 0) return [];
|
|
65
65
|
|
|
66
|
+
const regionArg = normalizedArgs.find((a) => a.startsWith('--cli-region='));
|
|
66
67
|
const findings = [];
|
|
67
68
|
for (const sgId of sgIds) {
|
|
68
69
|
try {
|
|
69
70
|
const hcloudBin = process.env.HCLOUD_BIN || 'hcloud';
|
|
70
|
-
const
|
|
71
|
+
const spawnArgs = ['VPC', 'ListSecurityGroupRules', `--security_group_id.1=${sgId}`];
|
|
72
|
+
if (regionArg) spawnArgs.push(regionArg);
|
|
73
|
+
const r = spawnSync(hcloudBin, spawnArgs, {
|
|
71
74
|
shell: false,
|
|
72
75
|
windowsHide: true,
|
|
73
76
|
stdio: 'pipe',
|
|
@@ -120,9 +123,10 @@ function applyPreflightFindings(classification, sgFindings) {
|
|
|
120
123
|
if (hasDeny) {
|
|
121
124
|
return {
|
|
122
125
|
...classification,
|
|
123
|
-
decision: '
|
|
126
|
+
decision: 'warn',
|
|
124
127
|
risk: 'public_exposure',
|
|
125
128
|
reason: sgFindings[0].message,
|
|
129
|
+
requireUserConfirmation: true,
|
|
126
130
|
};
|
|
127
131
|
}
|
|
128
132
|
return classification;
|
|
@@ -137,6 +141,7 @@ export function planHcloudCommand(args, options = {}) {
|
|
|
137
141
|
if (sgFindings.length > 0) {
|
|
138
142
|
for (const f of sgFindings) warnings.push(f);
|
|
139
143
|
}
|
|
144
|
+
const finalClassification = applyPreflightFindings(classification, sgFindings);
|
|
140
145
|
const paramValidation = validateRequiredParams(normalizedArgs);
|
|
141
146
|
if (paramValidation.missing.length > 0) {
|
|
142
147
|
warnings.push('Missing required parameters: ' + paramValidation.missing.join(', '));
|
|
@@ -150,10 +155,10 @@ export function planHcloudCommand(args, options = {}) {
|
|
|
150
155
|
command: redactOutput(command),
|
|
151
156
|
executableBlock: redactOutput(command),
|
|
152
157
|
warnings,
|
|
153
|
-
classification:
|
|
158
|
+
classification: finalClassification,
|
|
154
159
|
sgFindings,
|
|
155
160
|
approvalToken: createApprovalToken(normalizedArgs),
|
|
156
|
-
safeToRun:
|
|
161
|
+
safeToRun: finalClassification.decision === 'allow',
|
|
157
162
|
};
|
|
158
163
|
}
|
|
159
164
|
|