@daocloud-proto/virtnest 0.10.0-dev2 → 0.10.0-dev3

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/v1alpha1/vm.pb.ts +25 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@daocloud-proto/virtnest",
3
- "version":"0.10.0-dev2",
3
+ "version":"0.10.0-dev3",
4
4
  "description": "",
5
5
  "author": "",
6
6
  "license": "ISC"
package/v1alpha1/vm.pb.ts CHANGED
@@ -91,6 +91,13 @@ export enum EventLevel {
91
91
  Warning = "Warning",
92
92
  }
93
93
 
94
+ export enum NodePhase {
95
+ PhaseUnspecified = "PhaseUnspecified",
96
+ PhaseReady = "PhaseReady",
97
+ PhaseNotReady = "PhaseNotReady",
98
+ PhaseUnknown = "PhaseUnknown",
99
+ }
100
+
94
101
  export type Pagination = {
95
102
  page?: number
96
103
  pageSize?: number
@@ -205,6 +212,7 @@ export type UpdateVMRequest = {
205
212
  cpu?: number
206
213
  memory?: string
207
214
  disks?: VMDisks
215
+ gpus?: GPU[]
208
216
  }
209
217
 
210
218
  export type UpdateVMResponse = {
@@ -514,6 +522,7 @@ export type LiveMigrateVMRequest = {
514
522
  cluster?: string
515
523
  namespace?: string
516
524
  name?: string
525
+ targetNode?: string
517
526
  }
518
527
 
519
528
  export type LiveMigrateVMResponse = {
@@ -603,6 +612,19 @@ export type Object = {
603
612
  kind?: string
604
613
  }
605
614
 
615
+ export type ListClusterNodesRequest = {
616
+ cluster?: string
617
+ }
618
+
619
+ export type ListClusterNodesResponse = {
620
+ items?: Node[]
621
+ }
622
+
623
+ export type Node = {
624
+ name?: string
625
+ phase?: NodePhase
626
+ }
627
+
606
628
  export class VM {
607
629
  static ListClusterVMs(req: ListClusterVMsRequest, initReq?: fm.InitReq): Promise<ListClusterVmsResponse> {
608
630
  return fm.fetchReq<ListClusterVMsRequest, ListClusterVmsResponse>(`/apis/virtnest.io/v1alpha1/clusters/${req["cluster"]}/vms?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
@@ -688,4 +710,7 @@ export class VM {
688
710
  static ListVMEvents(req: ListVMEventsRequest, initReq?: fm.InitReq): Promise<ListVMEventsResponse> {
689
711
  return fm.fetchReq<ListVMEventsRequest, ListVMEventsResponse>(`/apis/virtnest.io/v1alpha1/clusters/${req["cluster"]}/namespaces/${req["namespace"]}/vms/${req["name"]}/events?${fm.renderURLSearchParams(req, ["cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
690
712
  }
713
+ static ListClusterNodes(req: ListClusterNodesRequest, initReq?: fm.InitReq): Promise<ListClusterNodesResponse> {
714
+ return fm.fetchReq<ListClusterNodesRequest, ListClusterNodesResponse>(`/apis/virtnest.io/v1alpha1/clusters/${req["cluster"]}/nodes?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
715
+ }
691
716
  }