@homeflare/distilled-proxmox 0.3.0 → 0.3.2
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/README.md +37 -10
- package/dist/config-not-found.test.d.ts +2 -0
- package/dist/config-not-found.test.d.ts.map +1 -0
- package/dist/config-not-found.test.js +125 -0
- package/dist/config-not-found.test.js.map +1 -0
- package/dist/errors.d.ts +2 -2
- package/dist/errors.d.ts.map +1 -1
- package/dist/errors.js.map +1 -1
- package/dist/lxc-config-errors.test.d.ts +2 -0
- package/dist/lxc-config-errors.test.d.ts.map +1 -0
- package/dist/lxc-config-errors.test.js +48 -0
- package/dist/lxc-config-errors.test.js.map +1 -0
- package/dist/protocol-form.d.ts +18 -0
- package/dist/protocol-form.d.ts.map +1 -0
- package/dist/protocol-form.js +37 -0
- package/dist/protocol-form.js.map +1 -0
- package/dist/protocol-form.test.d.ts +2 -0
- package/dist/protocol-form.test.d.ts.map +1 -0
- package/dist/protocol-form.test.js +68 -0
- package/dist/protocol-form.test.js.map +1 -0
- package/dist/protocol.d.ts.map +1 -1
- package/dist/protocol.js +25 -2
- package/dist/protocol.js.map +1 -1
- package/dist/replication-firewall-errors.test.d.ts +2 -0
- package/dist/replication-firewall-errors.test.d.ts.map +1 -0
- package/dist/replication-firewall-errors.test.js +76 -0
- package/dist/replication-firewall-errors.test.js.map +1 -0
- package/dist/services/cluster.d.ts +50 -10
- package/dist/services/cluster.d.ts.map +1 -1
- package/dist/services/cluster.js +50 -10
- package/dist/services/cluster.js.map +1 -1
- package/dist/services/nodes.d.ts +25 -5
- package/dist/services/nodes.d.ts.map +1 -1
- package/dist/services/nodes.js +24 -5
- package/dist/services/nodes.js.map +1 -1
- package/dist/services/pools.d.ts +16 -6
- package/dist/services/pools.d.ts.map +1 -1
- package/dist/services/pools.js +18 -6
- package/dist/services/pools.js.map +1 -1
- package/package.json +1 -1
- package/src/config-not-found.test.ts +202 -0
- package/src/errors.ts +4 -12
- package/src/lxc-config-errors.test.ts +100 -0
- package/src/protocol-form.test.ts +102 -0
- package/src/protocol-form.ts +49 -0
- package/src/protocol.ts +30 -2
- package/src/replication-firewall-errors.test.ts +126 -0
- package/src/services/cluster.ts +97 -20
- package/src/services/nodes.ts +39 -10
- package/src/services/pools.ts +27 -12
package/dist/services/nodes.js
CHANGED
|
@@ -30,6 +30,25 @@ export class ClusterNodeUnreachable extends /*@__PURE__*/ /*@__PURE__*/ T.applyE
|
|
|
30
30
|
message: S.String,
|
|
31
31
|
}).pipe(C.withServerError), [{ status: 595 }]) {
|
|
32
32
|
}
|
|
33
|
+
/** The requested container config is absent on this node. VM IDs are cluster-wide: callers must still check whether another node or QEMU guest holds the ID before creating. Also raised by PUT (update_vm) and DELETE (destroy_vm), which both call the same load_config first. This GET requires VM.Audit on /vms/{vmid}; retain its credential for any permission-filtered cluster index read. */
|
|
34
|
+
export class LxcConfigNotFound extends /*@__PURE__*/ /*@__PURE__*/ T.applyErrorMatchers(
|
|
35
|
+
/*@__PURE__*/ S.TaggedError()("LxcConfigNotFound", {
|
|
36
|
+
message: S.String,
|
|
37
|
+
}).pipe(C.withBadRequestError), [
|
|
38
|
+
{
|
|
39
|
+
status: 500,
|
|
40
|
+
message: {
|
|
41
|
+
matches: "^Configuration file 'nodes/[^/']+/lxc/[0-9]+\\.conf' does not exist\\n?$",
|
|
42
|
+
},
|
|
43
|
+
},
|
|
44
|
+
]) {
|
|
45
|
+
}
|
|
46
|
+
/** pve-manager 9.2.11, PVE/API2/Network.pm. GET (network_config) and PUT (update_network) both raise HTTP 400 with exactly errors.iface = interface does not exist -- verified against the live n2 source on 2026-09-25. DELETE (delete_network) raises it too but is left untyped: no generated deleteNodeNetwork2 caller exists yet. Only the exact sole-field detail is normalized for operation matching; all other validation errors remain ParameterVerificationFailed. Attached to GET and PUT. */
|
|
47
|
+
export class NetworkInterfaceNotFound extends /*@__PURE__*/ /*@__PURE__*/ T.applyErrorMatchers(
|
|
48
|
+
/*@__PURE__*/ S.TaggedError()("NetworkInterfaceNotFound", {
|
|
49
|
+
message: S.String,
|
|
50
|
+
}).pipe(C.withBadRequestError), [{ status: 400, message: { matches: "^interface does not exist$" } }]) {
|
|
51
|
+
}
|
|
33
52
|
export const CloneNodesLxcRequest = /*@__PURE__*/ S.suspend(() => S.Struct({
|
|
34
53
|
node: S.String.pipe(T.Label()),
|
|
35
54
|
vmid: S.String.pipe(T.Label()),
|
|
@@ -8039,7 +8058,7 @@ export const deleteNodeFirewallRule = /*@__PURE__*/ API.make(() => ({
|
|
|
8039
8058
|
export const deleteNodeLxc = /*@__PURE__*/ API.make(() => ({
|
|
8040
8059
|
input: DeleteNodeLxcRequest,
|
|
8041
8060
|
output: DeleteNodeLxcResponse,
|
|
8042
|
-
errors: [],
|
|
8061
|
+
errors: [LxcConfigNotFound],
|
|
8043
8062
|
protocol: ProxmoxProtocol,
|
|
8044
8063
|
retry: Retry.Retry,
|
|
8045
8064
|
}));
|
|
@@ -8407,7 +8426,7 @@ export const getNodeLxc = /*@__PURE__*/ API.make(() => ({
|
|
|
8407
8426
|
export const getNodeLxcConfig = /*@__PURE__*/ API.make(() => ({
|
|
8408
8427
|
input: GetNodeLxcConfigRequest,
|
|
8409
8428
|
output: GetNodeLxcConfigResponse,
|
|
8410
|
-
errors: [],
|
|
8429
|
+
errors: [LxcConfigNotFound],
|
|
8411
8430
|
protocol: ProxmoxProtocol,
|
|
8412
8431
|
retry: Retry.Retry,
|
|
8413
8432
|
}));
|
|
@@ -8518,7 +8537,7 @@ export const getNodeLxcVncwebsocket = /*@__PURE__*/ API.make(() => ({
|
|
|
8518
8537
|
export const getNodeNetwork = /*@__PURE__*/ API.make(() => ({
|
|
8519
8538
|
input: GetNodeNetworkRequest,
|
|
8520
8539
|
output: GetNodeNetworkResponse,
|
|
8521
|
-
errors: [],
|
|
8540
|
+
errors: [NetworkInterfaceNotFound],
|
|
8522
8541
|
protocol: ProxmoxProtocol,
|
|
8523
8542
|
retry: Retry.Retry,
|
|
8524
8543
|
}));
|
|
@@ -9818,7 +9837,7 @@ export const putNodeFirewallRule = /*@__PURE__*/ API.make(() => ({
|
|
|
9818
9837
|
export const putNodeLxcConfig = /*@__PURE__*/ API.make(() => ({
|
|
9819
9838
|
input: PutNodeLxcConfigRequest,
|
|
9820
9839
|
output: PutNodeLxcConfigResponse,
|
|
9821
|
-
errors: [],
|
|
9840
|
+
errors: [LxcConfigNotFound],
|
|
9822
9841
|
protocol: ProxmoxProtocol,
|
|
9823
9842
|
retry: Retry.Retry,
|
|
9824
9843
|
}));
|
|
@@ -9882,7 +9901,7 @@ export const putNodeNetwork = /*@__PURE__*/ API.make(() => ({
|
|
|
9882
9901
|
export const putNodeNetwork2 = /*@__PURE__*/ API.make(() => ({
|
|
9883
9902
|
input: PutNodeNetwork2Request,
|
|
9884
9903
|
output: PutNodeNetwork2Response,
|
|
9885
|
-
errors: [],
|
|
9904
|
+
errors: [NetworkInterfaceNotFound],
|
|
9886
9905
|
protocol: ProxmoxProtocol,
|
|
9887
9906
|
retry: Retry.Retry,
|
|
9888
9907
|
}));
|