@nebius/js-sdk 0.2.62 → 0.2.64
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/dist/cjs/api/google/protobuf/index.d.ts +34 -20
- package/dist/cjs/api/google/protobuf/index.d.ts.map +1 -1
- package/dist/cjs/api/google/protobuf/index.js +32 -0
- package/dist/cjs/api/google/protobuf/index.js.map +1 -1
- package/dist/cjs/api/nebius/ai/v1/index.d.ts +1353 -1
- package/dist/cjs/api/nebius/ai/v1/index.d.ts.map +1 -1
- package/dist/cjs/api/nebius/ai/v1/index.js +4151 -2
- package/dist/cjs/api/nebius/ai/v1/index.js.map +1 -1
- package/dist/cjs/api/nebius/applications/v1alpha1/index.d.ts +1639 -0
- package/dist/cjs/api/nebius/applications/v1alpha1/index.d.ts.map +1 -1
- package/dist/cjs/api/nebius/applications/v1alpha1/index.js +7660 -1
- package/dist/cjs/api/nebius/applications/v1alpha1/index.js.map +1 -1
- package/dist/cjs/api/nebius/compute/v1/index.d.ts +8 -2
- package/dist/cjs/api/nebius/compute/v1/index.d.ts.map +1 -1
- package/dist/cjs/api/nebius/compute/v1/index.js.map +1 -1
- package/dist/cjs/api/nebius/mk8s/v1/index.d.ts +109 -1
- package/dist/cjs/api/nebius/mk8s/v1/index.d.ts.map +1 -1
- package/dist/cjs/api/nebius/mk8s/v1/index.js +534 -2
- package/dist/cjs/api/nebius/mk8s/v1/index.js.map +1 -1
- package/dist/cjs/api/nebius/msp/mlflow/v1alpha1/index.d.ts +128 -0
- package/dist/cjs/api/nebius/msp/mlflow/v1alpha1/index.d.ts.map +1 -1
- package/dist/cjs/api/nebius/msp/mlflow/v1alpha1/index.js +261 -1
- package/dist/cjs/api/nebius/msp/mlflow/v1alpha1/index.js.map +1 -1
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/api/google/protobuf/index.d.ts +34 -20
- package/dist/esm/api/google/protobuf/index.d.ts.map +1 -1
- package/dist/esm/api/google/protobuf/index.js +32 -0
- package/dist/esm/api/google/protobuf/index.js.map +1 -1
- package/dist/esm/api/nebius/ai/v1/index.d.ts +1353 -1
- package/dist/esm/api/nebius/ai/v1/index.d.ts.map +1 -1
- package/dist/esm/api/nebius/ai/v1/index.js +4149 -1
- package/dist/esm/api/nebius/ai/v1/index.js.map +1 -1
- package/dist/esm/api/nebius/applications/v1alpha1/index.d.ts +1639 -0
- package/dist/esm/api/nebius/applications/v1alpha1/index.d.ts.map +1 -1
- package/dist/esm/api/nebius/applications/v1alpha1/index.js +7658 -1
- package/dist/esm/api/nebius/applications/v1alpha1/index.js.map +1 -1
- package/dist/esm/api/nebius/compute/v1/index.d.ts +8 -2
- package/dist/esm/api/nebius/compute/v1/index.d.ts.map +1 -1
- package/dist/esm/api/nebius/compute/v1/index.js.map +1 -1
- package/dist/esm/api/nebius/mk8s/v1/index.d.ts +109 -1
- package/dist/esm/api/nebius/mk8s/v1/index.d.ts.map +1 -1
- package/dist/esm/api/nebius/mk8s/v1/index.js +533 -1
- package/dist/esm/api/nebius/mk8s/v1/index.js.map +1 -1
- package/dist/esm/api/nebius/msp/mlflow/v1alpha1/index.d.ts +128 -0
- package/dist/esm/api/nebius/msp/mlflow/v1alpha1/index.d.ts.map +1 -1
- package/dist/esm/api/nebius/msp/mlflow/v1alpha1/index.js +260 -0
- package/dist/esm/api/nebius/msp/mlflow/v1alpha1/index.js.map +1 -1
- package/dist/esm/version.d.ts +1 -1
- package/dist/esm/version.js +1 -1
- package/package.json +1 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
/* Generated by Nebius TS generator. DO NOT EDIT! */
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.
|
|
5
|
-
exports.JobInstanceStatus = exports.JobStateDetails = exports.JobStatus = exports.JobSpec_MysteryBoxSecretRef = exports.JobSpec_FileInjection = exports.JobSpec_RegistryCredentials = exports.JobSpec_DiskSpec = exports.JobSpec_VolumeMount_S3Config_MysteryBoxSecretRef = exports.JobSpec_VolumeMount_S3Config_S3Credentials = exports.JobSpec_VolumeMount_S3Config = exports.JobSpec_VolumeMount = exports.JobSpec_Port = exports.JobSpec_EnvironmentVariable = void 0;
|
|
4
|
+
exports.EndpointSpec = exports.Endpoint = exports.EndpointInstanceStatus_State = exports.EndpointStatus_State = exports.EndpointSpec_VolumeMount_Mode = exports.EndpointSpec_Port_Protocol = exports.EndpointService = exports.EndpointServiceBaseClient = exports.EndpointServiceServiceDescription = exports.ListEndpointsResponse = exports.StopEndpointRequest = exports.RestartEndpointRequest = exports.StartEndpointRequest = exports.DeleteEndpointRequest = exports.CreateEndpointRequest = exports.ListEndpointsRequest = exports.GetEndpointByNameRequest = exports.GetEndpointRequest = exports.GetEndpointRequest_View = exports.DevlabInstanceStatus = exports.DevlabStateDetails = exports.DevlabStatus = exports.DevlabSpec_MysteryBoxSecretRef = exports.DevlabSpec_Template = exports.DevlabSpec_FileInjection = exports.DevlabSpec_PrimaryRoute = exports.DevlabSpec_Workspace = exports.DevlabSpec_RegistryCredentials = exports.DevlabSpec_DiskSpec = exports.DevlabSpec_VolumeMount_S3Config = exports.DevlabSpec_VolumeMount = exports.DevlabSpec_Port = exports.DevlabSpec_EnvironmentVariable = exports.DevlabSpec = exports.Devlab = exports.DevlabInstanceStatus_State = exports.DevlabStatus_State = exports.DevlabSpec_VolumeMount_Mode = exports.DevlabSpec_Port_Protocol = exports.DevlabService = exports.DevlabServiceBaseClient = exports.DevlabServiceServiceDescription = exports.ListDevlabsResponse = exports.StopDevlabRequest = exports.RestartDevlabRequest = exports.DeleteDevlabRequest = exports.CreateDevlabRequest = exports.ListDevlabsRequest = exports.GetDevlabRequest = exports.GetDevlabRequest_View = void 0;
|
|
5
|
+
exports.JobInstanceStatus = exports.JobStateDetails = exports.JobStatus = exports.JobSpec_MysteryBoxSecretRef = exports.JobSpec_FileInjection = exports.JobSpec_RegistryCredentials = exports.JobSpec_DiskSpec = exports.JobSpec_VolumeMount_S3Config_MysteryBoxSecretRef = exports.JobSpec_VolumeMount_S3Config_S3Credentials = exports.JobSpec_VolumeMount_S3Config = exports.JobSpec_VolumeMount = exports.JobSpec_Port = exports.JobSpec_EnvironmentVariable = exports.JobSpec = exports.Job = exports.JobInstanceStatus_State = exports.JobStatus_State = exports.JobSpec_VolumeMount_Mode = exports.JobSpec_Port_Protocol = exports.JobService = exports.JobServiceBaseClient = exports.JobServiceServiceDescription = exports.ListJobsResponse = exports.RestartJobRequest = exports.CancelJobRequest = exports.DeleteJobRequest = exports.CreateJobRequest = exports.ListJobsRequest = exports.GetJobByNameRequest = exports.GetJobRequest = exports.GetJobRequest_View = exports.EndpointInstanceStatus = exports.EndpointStateDetails = exports.EndpointStatus = exports.EndpointSpec_MysteryBoxSecretRef = exports.EndpointSpec_FileInjection = exports.EndpointSpec_RegistryCredentials = exports.EndpointSpec_DiskSpec = exports.EndpointSpec_VolumeMount_S3Config_MysteryBoxSecretRef = exports.EndpointSpec_VolumeMount_S3Config_S3Credentials = exports.EndpointSpec_VolumeMount_S3Config = exports.EndpointSpec_VolumeMount = exports.EndpointSpec_Port = exports.EndpointSpec_EnvironmentVariable = void 0;
|
|
6
6
|
const index_js_1 = require("../../../../runtime/protos/index.js");
|
|
7
7
|
const util_1 = require("util");
|
|
8
8
|
const protobuf_js_1 = require("../../../protobuf.js");
|
|
@@ -13,6 +13,4155 @@ const operation_js_1 = require("../../../../runtime/operation.js");
|
|
|
13
13
|
const index_js_2 = require("../../common/v1/index.js");
|
|
14
14
|
const index_js_3 = require("../../compute/v1/index.js");
|
|
15
15
|
const __deprecatedWarned = new Set();
|
|
16
|
+
const GetDevlabRequest_View_VALUE_COMMENTS = {
|
|
17
|
+
VIEW_UNSPECIFIED: " Masks environment-variable values and omits injected-file content.\n",
|
|
18
|
+
SECRET: " Includes unmasked environment-variable values and injected-file content.\n Requires the resource.devlab.getSensitiveData permission.\n",
|
|
19
|
+
};
|
|
20
|
+
/** Converts and creates {@link GetDevlabRequest_View} values. */
|
|
21
|
+
exports.GetDevlabRequest_View = (0, index_js_1.createEnum)("nebius.ai.v1.GetDevlabRequest.View", {
|
|
22
|
+
/**
|
|
23
|
+
* Masks environment-variable values and omits injected-file content.
|
|
24
|
+
*
|
|
25
|
+
*/
|
|
26
|
+
VIEW_UNSPECIFIED: 0,
|
|
27
|
+
/**
|
|
28
|
+
* Includes unmasked environment-variable values and injected-file content.
|
|
29
|
+
* Requires the resource.devlab.getSensitiveData permission.
|
|
30
|
+
*
|
|
31
|
+
*/
|
|
32
|
+
SECRET: 1,
|
|
33
|
+
}, GetDevlabRequest_View_VALUE_COMMENTS);
|
|
34
|
+
protobuf_js_1.protoRegistry.registerEnum(exports.GetDevlabRequest_View);
|
|
35
|
+
const GetDevlabRequest_MESSAGE_DESCRIPTOR = {
|
|
36
|
+
fields: {
|
|
37
|
+
"id": { pbName: "id", scalarType: 9 },
|
|
38
|
+
"view": { pbName: "view", scalarType: 14 },
|
|
39
|
+
},
|
|
40
|
+
};
|
|
41
|
+
/** Encodes, decodes, converts, and creates {@link GetDevlabRequest} messages. */
|
|
42
|
+
exports.GetDevlabRequest = {
|
|
43
|
+
$type: "nebius.ai.v1.GetDevlabRequest",
|
|
44
|
+
$descriptor: GetDevlabRequest_MESSAGE_DESCRIPTOR,
|
|
45
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
46
|
+
if (message.id !== "") {
|
|
47
|
+
writer.uint32(10).string(message.id);
|
|
48
|
+
}
|
|
49
|
+
if ((message.view ?? exports.GetDevlabRequest_View.VIEW_UNSPECIFIED) !== exports.GetDevlabRequest_View.VIEW_UNSPECIFIED) {
|
|
50
|
+
exports.GetDevlabRequest_View.encodeField(writer, 101, message.view);
|
|
51
|
+
}
|
|
52
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
53
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
54
|
+
}
|
|
55
|
+
return writer;
|
|
56
|
+
},
|
|
57
|
+
decode(input, length) {
|
|
58
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
59
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
60
|
+
const message = createBaseGetDevlabRequest();
|
|
61
|
+
let writer = undefined;
|
|
62
|
+
while (reader.pos < end) {
|
|
63
|
+
const tag = reader.uint32();
|
|
64
|
+
switch (tag >>> 3) {
|
|
65
|
+
case 1: {
|
|
66
|
+
if (tag !== 10)
|
|
67
|
+
break;
|
|
68
|
+
message.id = reader.string();
|
|
69
|
+
continue;
|
|
70
|
+
}
|
|
71
|
+
case 101: {
|
|
72
|
+
if (tag !== 808)
|
|
73
|
+
break;
|
|
74
|
+
message.view = exports.GetDevlabRequest_View.fromNumber(reader.int32());
|
|
75
|
+
continue;
|
|
76
|
+
}
|
|
77
|
+
default:
|
|
78
|
+
break;
|
|
79
|
+
}
|
|
80
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
81
|
+
break;
|
|
82
|
+
}
|
|
83
|
+
{
|
|
84
|
+
if (!writer)
|
|
85
|
+
writer = new index_js_1.BinaryWriter();
|
|
86
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
87
|
+
writer.uint32(tag).raw(skipped);
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
if (writer) {
|
|
91
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
92
|
+
}
|
|
93
|
+
return message;
|
|
94
|
+
},
|
|
95
|
+
fromJSON(object) {
|
|
96
|
+
return applyGetDevlabRequestCustom({
|
|
97
|
+
$type: "nebius.ai.v1.GetDevlabRequest",
|
|
98
|
+
id: (0, index_js_1.isSet)(object.id ?? object.id)
|
|
99
|
+
? String(object.id ?? object.id)
|
|
100
|
+
: "",
|
|
101
|
+
view: (0, index_js_1.isSet)(object.view ?? object.view)
|
|
102
|
+
? exports.GetDevlabRequest_View.fromJSON(object.view ?? object.view)
|
|
103
|
+
: exports.GetDevlabRequest_View.VIEW_UNSPECIFIED,
|
|
104
|
+
});
|
|
105
|
+
},
|
|
106
|
+
toJSON(message, use = "json") {
|
|
107
|
+
const obj = {};
|
|
108
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
109
|
+
if (message.id !== "") {
|
|
110
|
+
obj[pick("id", "id")] = message.id;
|
|
111
|
+
}
|
|
112
|
+
if ((message.view ?? exports.GetDevlabRequest_View.VIEW_UNSPECIFIED) !== exports.GetDevlabRequest_View.VIEW_UNSPECIFIED) {
|
|
113
|
+
obj[pick("view", "view")] = exports.GetDevlabRequest_View.toJSON(message.view);
|
|
114
|
+
}
|
|
115
|
+
return obj;
|
|
116
|
+
},
|
|
117
|
+
create(base) {
|
|
118
|
+
return exports.GetDevlabRequest.fromPartial(base ?? {});
|
|
119
|
+
},
|
|
120
|
+
fromPartial(object) {
|
|
121
|
+
const message = createBaseGetDevlabRequest();
|
|
122
|
+
message.id = (object.id !== undefined && object.id !== null)
|
|
123
|
+
? object.id
|
|
124
|
+
: "";
|
|
125
|
+
message.view = (object.view !== undefined && object.view !== null)
|
|
126
|
+
? exports.GetDevlabRequest_View.fromJSON(object.view.name)
|
|
127
|
+
: exports.GetDevlabRequest_View.VIEW_UNSPECIFIED;
|
|
128
|
+
return message;
|
|
129
|
+
},
|
|
130
|
+
};
|
|
131
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.GetDevlabRequest);
|
|
132
|
+
function GetDevlabRequestCustomInspect() {
|
|
133
|
+
const parts = [];
|
|
134
|
+
if (this.id !== "")
|
|
135
|
+
parts.push("id" + "=" + (0, util_1.inspect)(this.id));
|
|
136
|
+
if (this.view !== undefined)
|
|
137
|
+
parts.push("view" + "=" + (0, util_1.inspect)(this.view));
|
|
138
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
139
|
+
}
|
|
140
|
+
function GetDevlabRequestCustomJson() {
|
|
141
|
+
const obj = {
|
|
142
|
+
type: this.$type,
|
|
143
|
+
};
|
|
144
|
+
if (this.id !== "")
|
|
145
|
+
obj.id = (0, logging_js_1.inspectJson)(this.id);
|
|
146
|
+
if (this.view !== undefined)
|
|
147
|
+
obj.view = (0, logging_js_1.inspectJson)(this.view);
|
|
148
|
+
return obj;
|
|
149
|
+
}
|
|
150
|
+
function applyGetDevlabRequestCustom(message) {
|
|
151
|
+
message[logging_js_1.custom] = GetDevlabRequestCustomInspect;
|
|
152
|
+
message[logging_js_1.customJson] = GetDevlabRequestCustomJson;
|
|
153
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.GetDevlabRequest.$descriptor);
|
|
154
|
+
}
|
|
155
|
+
function createBaseGetDevlabRequest() {
|
|
156
|
+
const message = {
|
|
157
|
+
$type: "nebius.ai.v1.GetDevlabRequest",
|
|
158
|
+
id: "",
|
|
159
|
+
view: exports.GetDevlabRequest_View.VIEW_UNSPECIFIED,
|
|
160
|
+
};
|
|
161
|
+
return applyGetDevlabRequestCustom(message);
|
|
162
|
+
}
|
|
163
|
+
const ListDevlabsRequest_MESSAGE_DESCRIPTOR = {
|
|
164
|
+
fields: {
|
|
165
|
+
"parentId": { pbName: "parent_id", scalarType: 9 },
|
|
166
|
+
"pageSize": { pbName: "page_size", scalarType: 3 },
|
|
167
|
+
"pageToken": { pbName: "page_token", scalarType: 9 },
|
|
168
|
+
},
|
|
169
|
+
};
|
|
170
|
+
/** Encodes, decodes, converts, and creates {@link ListDevlabsRequest} messages. */
|
|
171
|
+
exports.ListDevlabsRequest = {
|
|
172
|
+
$type: "nebius.ai.v1.ListDevlabsRequest",
|
|
173
|
+
$descriptor: ListDevlabsRequest_MESSAGE_DESCRIPTOR,
|
|
174
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
175
|
+
if (message.parentId !== "") {
|
|
176
|
+
writer.uint32(10).string(message.parentId);
|
|
177
|
+
}
|
|
178
|
+
if (message.pageSize !== undefined && !message.pageSize.isZero?.()) {
|
|
179
|
+
writer.uint32(16).int64(message.pageSize.toString());
|
|
180
|
+
}
|
|
181
|
+
if (message.pageToken !== "") {
|
|
182
|
+
writer.uint32(26).string(message.pageToken);
|
|
183
|
+
}
|
|
184
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
185
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
186
|
+
}
|
|
187
|
+
return writer;
|
|
188
|
+
},
|
|
189
|
+
decode(input, length) {
|
|
190
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
191
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
192
|
+
const message = createBaseListDevlabsRequest();
|
|
193
|
+
let writer = undefined;
|
|
194
|
+
while (reader.pos < end) {
|
|
195
|
+
const tag = reader.uint32();
|
|
196
|
+
switch (tag >>> 3) {
|
|
197
|
+
case 1: {
|
|
198
|
+
if (tag !== 10)
|
|
199
|
+
break;
|
|
200
|
+
message.parentId = reader.string();
|
|
201
|
+
continue;
|
|
202
|
+
}
|
|
203
|
+
case 2: {
|
|
204
|
+
if (tag !== 16)
|
|
205
|
+
break;
|
|
206
|
+
message.pageSize = index_js_1.Long.fromValue(reader.int64());
|
|
207
|
+
continue;
|
|
208
|
+
}
|
|
209
|
+
case 3: {
|
|
210
|
+
if (tag !== 26)
|
|
211
|
+
break;
|
|
212
|
+
message.pageToken = reader.string();
|
|
213
|
+
continue;
|
|
214
|
+
}
|
|
215
|
+
default:
|
|
216
|
+
break;
|
|
217
|
+
}
|
|
218
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
219
|
+
break;
|
|
220
|
+
}
|
|
221
|
+
{
|
|
222
|
+
if (!writer)
|
|
223
|
+
writer = new index_js_1.BinaryWriter();
|
|
224
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
225
|
+
writer.uint32(tag).raw(skipped);
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
if (writer) {
|
|
229
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
230
|
+
}
|
|
231
|
+
return message;
|
|
232
|
+
},
|
|
233
|
+
fromJSON(object) {
|
|
234
|
+
return applyListDevlabsRequestCustom({
|
|
235
|
+
$type: "nebius.ai.v1.ListDevlabsRequest",
|
|
236
|
+
parentId: (0, index_js_1.isSet)(object.parentId ?? object.parent_id)
|
|
237
|
+
? String(object.parentId ?? object.parent_id)
|
|
238
|
+
: "",
|
|
239
|
+
pageSize: (0, index_js_1.isSet)(object.pageSize ?? object.page_size)
|
|
240
|
+
? index_js_1.Long.fromValue(object.pageSize ?? object.page_size)
|
|
241
|
+
: index_js_1.Long.ZERO,
|
|
242
|
+
pageToken: (0, index_js_1.isSet)(object.pageToken ?? object.page_token)
|
|
243
|
+
? String(object.pageToken ?? object.page_token)
|
|
244
|
+
: "",
|
|
245
|
+
});
|
|
246
|
+
},
|
|
247
|
+
toJSON(message, use = "json") {
|
|
248
|
+
const obj = {};
|
|
249
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
250
|
+
if (message.parentId !== "") {
|
|
251
|
+
obj[pick("parentId", "parent_id")] = message.parentId;
|
|
252
|
+
}
|
|
253
|
+
if (!message.pageSize?.isZero?.()) {
|
|
254
|
+
obj[pick("pageSize", "page_size")] = (message.pageSize || index_js_1.Long.ZERO).toString();
|
|
255
|
+
}
|
|
256
|
+
if (message.pageToken !== "") {
|
|
257
|
+
obj[pick("pageToken", "page_token")] = message.pageToken;
|
|
258
|
+
}
|
|
259
|
+
return obj;
|
|
260
|
+
},
|
|
261
|
+
create(base) {
|
|
262
|
+
return exports.ListDevlabsRequest.fromPartial(base ?? {});
|
|
263
|
+
},
|
|
264
|
+
fromPartial(object) {
|
|
265
|
+
const message = createBaseListDevlabsRequest();
|
|
266
|
+
message.parentId = (object.parentId !== undefined && object.parentId !== null)
|
|
267
|
+
? object.parentId
|
|
268
|
+
: "";
|
|
269
|
+
message.pageSize = (object.pageSize !== undefined && object.pageSize !== null)
|
|
270
|
+
? index_js_1.Long.fromValue(object.pageSize)
|
|
271
|
+
: index_js_1.Long.ZERO;
|
|
272
|
+
message.pageToken = (object.pageToken !== undefined && object.pageToken !== null)
|
|
273
|
+
? object.pageToken
|
|
274
|
+
: "";
|
|
275
|
+
return message;
|
|
276
|
+
},
|
|
277
|
+
};
|
|
278
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.ListDevlabsRequest);
|
|
279
|
+
function ListDevlabsRequestCustomInspect() {
|
|
280
|
+
const parts = [];
|
|
281
|
+
if (this.parentId !== "")
|
|
282
|
+
parts.push("parentId" + "=" + (0, util_1.inspect)(this.parentId));
|
|
283
|
+
if (!this.pageSize?.isZero?.())
|
|
284
|
+
parts.push("pageSize" + "=" + (0, util_1.inspect)(this.pageSize));
|
|
285
|
+
if (this.pageToken !== "")
|
|
286
|
+
parts.push("pageToken" + "=" + (0, util_1.inspect)(this.pageToken));
|
|
287
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
288
|
+
}
|
|
289
|
+
function ListDevlabsRequestCustomJson() {
|
|
290
|
+
const obj = {
|
|
291
|
+
type: this.$type,
|
|
292
|
+
};
|
|
293
|
+
if (this.parentId !== "")
|
|
294
|
+
obj.parentId = (0, logging_js_1.inspectJson)(this.parentId);
|
|
295
|
+
if (!this.pageSize?.isZero?.())
|
|
296
|
+
obj.pageSize = (0, logging_js_1.inspectJson)(this.pageSize);
|
|
297
|
+
if (this.pageToken !== "")
|
|
298
|
+
obj.pageToken = (0, logging_js_1.inspectJson)(this.pageToken);
|
|
299
|
+
return obj;
|
|
300
|
+
}
|
|
301
|
+
function applyListDevlabsRequestCustom(message) {
|
|
302
|
+
message[logging_js_1.custom] = ListDevlabsRequestCustomInspect;
|
|
303
|
+
message[logging_js_1.customJson] = ListDevlabsRequestCustomJson;
|
|
304
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.ListDevlabsRequest.$descriptor);
|
|
305
|
+
}
|
|
306
|
+
function createBaseListDevlabsRequest() {
|
|
307
|
+
const message = {
|
|
308
|
+
$type: "nebius.ai.v1.ListDevlabsRequest",
|
|
309
|
+
parentId: "",
|
|
310
|
+
pageSize: index_js_1.Long.ZERO,
|
|
311
|
+
pageToken: "",
|
|
312
|
+
};
|
|
313
|
+
return applyListDevlabsRequestCustom(message);
|
|
314
|
+
}
|
|
315
|
+
const CreateDevlabRequest_MESSAGE_DESCRIPTOR = {
|
|
316
|
+
fields: {
|
|
317
|
+
"metadata": { pbName: "metadata", message: () => index_js_2.ResourceMetadata.$descriptor },
|
|
318
|
+
"spec": { pbName: "spec", message: () => exports.DevlabSpec.$descriptor },
|
|
319
|
+
"dryRun": { pbName: "dry_run", scalarType: 8 },
|
|
320
|
+
},
|
|
321
|
+
};
|
|
322
|
+
/** Encodes, decodes, converts, and creates {@link CreateDevlabRequest} messages. */
|
|
323
|
+
exports.CreateDevlabRequest = {
|
|
324
|
+
$type: "nebius.ai.v1.CreateDevlabRequest",
|
|
325
|
+
$descriptor: CreateDevlabRequest_MESSAGE_DESCRIPTOR,
|
|
326
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
327
|
+
if (message.metadata !== undefined) {
|
|
328
|
+
const w = writer.uint32(10).fork();
|
|
329
|
+
index_js_2.ResourceMetadata.encode(message.metadata, w);
|
|
330
|
+
w.join();
|
|
331
|
+
}
|
|
332
|
+
if (message.spec !== undefined) {
|
|
333
|
+
const w = writer.uint32(18).fork();
|
|
334
|
+
exports.DevlabSpec.encode(message.spec, w);
|
|
335
|
+
w.join();
|
|
336
|
+
}
|
|
337
|
+
if (message.dryRun === true) {
|
|
338
|
+
writer.uint32(24).bool(message.dryRun);
|
|
339
|
+
}
|
|
340
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
341
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
342
|
+
}
|
|
343
|
+
return writer;
|
|
344
|
+
},
|
|
345
|
+
decode(input, length) {
|
|
346
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
347
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
348
|
+
const message = createBaseCreateDevlabRequest();
|
|
349
|
+
let writer = undefined;
|
|
350
|
+
while (reader.pos < end) {
|
|
351
|
+
const tag = reader.uint32();
|
|
352
|
+
switch (tag >>> 3) {
|
|
353
|
+
case 1: {
|
|
354
|
+
if (tag !== 10)
|
|
355
|
+
break;
|
|
356
|
+
message.metadata = index_js_2.ResourceMetadata.decode(reader, reader.uint32());
|
|
357
|
+
continue;
|
|
358
|
+
}
|
|
359
|
+
case 2: {
|
|
360
|
+
if (tag !== 18)
|
|
361
|
+
break;
|
|
362
|
+
message.spec = exports.DevlabSpec.decode(reader, reader.uint32());
|
|
363
|
+
continue;
|
|
364
|
+
}
|
|
365
|
+
case 3: {
|
|
366
|
+
if (tag !== 24)
|
|
367
|
+
break;
|
|
368
|
+
message.dryRun = reader.bool();
|
|
369
|
+
continue;
|
|
370
|
+
}
|
|
371
|
+
default:
|
|
372
|
+
break;
|
|
373
|
+
}
|
|
374
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
375
|
+
break;
|
|
376
|
+
}
|
|
377
|
+
{
|
|
378
|
+
if (!writer)
|
|
379
|
+
writer = new index_js_1.BinaryWriter();
|
|
380
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
381
|
+
writer.uint32(tag).raw(skipped);
|
|
382
|
+
}
|
|
383
|
+
}
|
|
384
|
+
if (writer) {
|
|
385
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
386
|
+
}
|
|
387
|
+
return message;
|
|
388
|
+
},
|
|
389
|
+
fromJSON(object) {
|
|
390
|
+
return applyCreateDevlabRequestCustom({
|
|
391
|
+
$type: "nebius.ai.v1.CreateDevlabRequest",
|
|
392
|
+
metadata: (0, index_js_1.isSet)(object.metadata ?? object.metadata)
|
|
393
|
+
? index_js_2.ResourceMetadata.fromJSON(object.metadata ?? object.metadata)
|
|
394
|
+
: undefined,
|
|
395
|
+
spec: (0, index_js_1.isSet)(object.spec ?? object.spec)
|
|
396
|
+
? exports.DevlabSpec.fromJSON(object.spec ?? object.spec)
|
|
397
|
+
: undefined,
|
|
398
|
+
dryRun: (0, index_js_1.isSet)(object.dryRun ?? object.dry_run)
|
|
399
|
+
? Boolean(object.dryRun ?? object.dry_run)
|
|
400
|
+
: false,
|
|
401
|
+
});
|
|
402
|
+
},
|
|
403
|
+
toJSON(message, use = "json") {
|
|
404
|
+
const obj = {};
|
|
405
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
406
|
+
if (message.metadata !== undefined) {
|
|
407
|
+
obj[pick("metadata", "metadata")] = message.metadata
|
|
408
|
+
? index_js_2.ResourceMetadata.toJSON(message.metadata, use)
|
|
409
|
+
: undefined;
|
|
410
|
+
}
|
|
411
|
+
if (message.spec !== undefined) {
|
|
412
|
+
obj[pick("spec", "spec")] = message.spec
|
|
413
|
+
? exports.DevlabSpec.toJSON(message.spec, use)
|
|
414
|
+
: undefined;
|
|
415
|
+
}
|
|
416
|
+
if (message.dryRun === true) {
|
|
417
|
+
obj[pick("dryRun", "dry_run")] = message.dryRun;
|
|
418
|
+
}
|
|
419
|
+
return obj;
|
|
420
|
+
},
|
|
421
|
+
create(base) {
|
|
422
|
+
return exports.CreateDevlabRequest.fromPartial(base ?? {});
|
|
423
|
+
},
|
|
424
|
+
fromPartial(object) {
|
|
425
|
+
const message = createBaseCreateDevlabRequest();
|
|
426
|
+
message.metadata = (object.metadata !== undefined && object.metadata !== null)
|
|
427
|
+
? index_js_2.ResourceMetadata.fromPartial(object.metadata)
|
|
428
|
+
: undefined;
|
|
429
|
+
message.spec = (object.spec !== undefined && object.spec !== null)
|
|
430
|
+
? exports.DevlabSpec.fromPartial(object.spec)
|
|
431
|
+
: undefined;
|
|
432
|
+
message.dryRun = (object.dryRun !== undefined && object.dryRun !== null)
|
|
433
|
+
? object.dryRun
|
|
434
|
+
: false;
|
|
435
|
+
return message;
|
|
436
|
+
},
|
|
437
|
+
};
|
|
438
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.CreateDevlabRequest);
|
|
439
|
+
function CreateDevlabRequestCustomInspect() {
|
|
440
|
+
const parts = [];
|
|
441
|
+
if (this.metadata !== undefined)
|
|
442
|
+
parts.push("metadata" + "=" + (0, util_1.inspect)(this.metadata));
|
|
443
|
+
if (this.spec !== undefined)
|
|
444
|
+
parts.push("spec" + "=" + (0, util_1.inspect)(this.spec));
|
|
445
|
+
if (this.dryRun === true)
|
|
446
|
+
parts.push("dryRun" + "=" + (0, util_1.inspect)(this.dryRun));
|
|
447
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
448
|
+
}
|
|
449
|
+
function CreateDevlabRequestCustomJson() {
|
|
450
|
+
const obj = {
|
|
451
|
+
type: this.$type,
|
|
452
|
+
};
|
|
453
|
+
if (this.metadata !== undefined)
|
|
454
|
+
obj.metadata = (0, logging_js_1.inspectJson)(this.metadata);
|
|
455
|
+
if (this.spec !== undefined)
|
|
456
|
+
obj.spec = (0, logging_js_1.inspectJson)(this.spec);
|
|
457
|
+
if (this.dryRun === true)
|
|
458
|
+
obj.dryRun = (0, logging_js_1.inspectJson)(this.dryRun);
|
|
459
|
+
return obj;
|
|
460
|
+
}
|
|
461
|
+
function applyCreateDevlabRequestCustom(message) {
|
|
462
|
+
message[logging_js_1.custom] = CreateDevlabRequestCustomInspect;
|
|
463
|
+
message[logging_js_1.customJson] = CreateDevlabRequestCustomJson;
|
|
464
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.CreateDevlabRequest.$descriptor);
|
|
465
|
+
}
|
|
466
|
+
function createBaseCreateDevlabRequest() {
|
|
467
|
+
const message = {
|
|
468
|
+
$type: "nebius.ai.v1.CreateDevlabRequest",
|
|
469
|
+
metadata: undefined,
|
|
470
|
+
spec: undefined,
|
|
471
|
+
dryRun: false,
|
|
472
|
+
};
|
|
473
|
+
return applyCreateDevlabRequestCustom(message);
|
|
474
|
+
}
|
|
475
|
+
const DeleteDevlabRequest_MESSAGE_DESCRIPTOR = {
|
|
476
|
+
fields: {
|
|
477
|
+
"id": { pbName: "id", scalarType: 9 },
|
|
478
|
+
},
|
|
479
|
+
};
|
|
480
|
+
/** Encodes, decodes, converts, and creates {@link DeleteDevlabRequest} messages. */
|
|
481
|
+
exports.DeleteDevlabRequest = {
|
|
482
|
+
$type: "nebius.ai.v1.DeleteDevlabRequest",
|
|
483
|
+
$descriptor: DeleteDevlabRequest_MESSAGE_DESCRIPTOR,
|
|
484
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
485
|
+
if (message.id !== "") {
|
|
486
|
+
writer.uint32(10).string(message.id);
|
|
487
|
+
}
|
|
488
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
489
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
490
|
+
}
|
|
491
|
+
return writer;
|
|
492
|
+
},
|
|
493
|
+
decode(input, length) {
|
|
494
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
495
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
496
|
+
const message = createBaseDeleteDevlabRequest();
|
|
497
|
+
let writer = undefined;
|
|
498
|
+
while (reader.pos < end) {
|
|
499
|
+
const tag = reader.uint32();
|
|
500
|
+
switch (tag >>> 3) {
|
|
501
|
+
case 1: {
|
|
502
|
+
if (tag !== 10)
|
|
503
|
+
break;
|
|
504
|
+
message.id = reader.string();
|
|
505
|
+
continue;
|
|
506
|
+
}
|
|
507
|
+
default:
|
|
508
|
+
break;
|
|
509
|
+
}
|
|
510
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
511
|
+
break;
|
|
512
|
+
}
|
|
513
|
+
{
|
|
514
|
+
if (!writer)
|
|
515
|
+
writer = new index_js_1.BinaryWriter();
|
|
516
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
517
|
+
writer.uint32(tag).raw(skipped);
|
|
518
|
+
}
|
|
519
|
+
}
|
|
520
|
+
if (writer) {
|
|
521
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
522
|
+
}
|
|
523
|
+
return message;
|
|
524
|
+
},
|
|
525
|
+
fromJSON(object) {
|
|
526
|
+
return applyDeleteDevlabRequestCustom({
|
|
527
|
+
$type: "nebius.ai.v1.DeleteDevlabRequest",
|
|
528
|
+
id: (0, index_js_1.isSet)(object.id ?? object.id)
|
|
529
|
+
? String(object.id ?? object.id)
|
|
530
|
+
: "",
|
|
531
|
+
});
|
|
532
|
+
},
|
|
533
|
+
toJSON(message, use = "json") {
|
|
534
|
+
const obj = {};
|
|
535
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
536
|
+
if (message.id !== "") {
|
|
537
|
+
obj[pick("id", "id")] = message.id;
|
|
538
|
+
}
|
|
539
|
+
return obj;
|
|
540
|
+
},
|
|
541
|
+
create(base) {
|
|
542
|
+
return exports.DeleteDevlabRequest.fromPartial(base ?? {});
|
|
543
|
+
},
|
|
544
|
+
fromPartial(object) {
|
|
545
|
+
const message = createBaseDeleteDevlabRequest();
|
|
546
|
+
message.id = (object.id !== undefined && object.id !== null)
|
|
547
|
+
? object.id
|
|
548
|
+
: "";
|
|
549
|
+
return message;
|
|
550
|
+
},
|
|
551
|
+
};
|
|
552
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DeleteDevlabRequest);
|
|
553
|
+
function DeleteDevlabRequestCustomInspect() {
|
|
554
|
+
const parts = [];
|
|
555
|
+
if (this.id !== "")
|
|
556
|
+
parts.push("id" + "=" + (0, util_1.inspect)(this.id));
|
|
557
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
558
|
+
}
|
|
559
|
+
function DeleteDevlabRequestCustomJson() {
|
|
560
|
+
const obj = {
|
|
561
|
+
type: this.$type,
|
|
562
|
+
};
|
|
563
|
+
if (this.id !== "")
|
|
564
|
+
obj.id = (0, logging_js_1.inspectJson)(this.id);
|
|
565
|
+
return obj;
|
|
566
|
+
}
|
|
567
|
+
function applyDeleteDevlabRequestCustom(message) {
|
|
568
|
+
message[logging_js_1.custom] = DeleteDevlabRequestCustomInspect;
|
|
569
|
+
message[logging_js_1.customJson] = DeleteDevlabRequestCustomJson;
|
|
570
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DeleteDevlabRequest.$descriptor);
|
|
571
|
+
}
|
|
572
|
+
function createBaseDeleteDevlabRequest() {
|
|
573
|
+
const message = {
|
|
574
|
+
$type: "nebius.ai.v1.DeleteDevlabRequest",
|
|
575
|
+
id: "",
|
|
576
|
+
};
|
|
577
|
+
return applyDeleteDevlabRequestCustom(message);
|
|
578
|
+
}
|
|
579
|
+
const RestartDevlabRequest_MESSAGE_DESCRIPTOR = {
|
|
580
|
+
fields: {
|
|
581
|
+
"id": { pbName: "id", scalarType: 9 },
|
|
582
|
+
},
|
|
583
|
+
};
|
|
584
|
+
/** Encodes, decodes, converts, and creates {@link RestartDevlabRequest} messages. */
|
|
585
|
+
exports.RestartDevlabRequest = {
|
|
586
|
+
$type: "nebius.ai.v1.RestartDevlabRequest",
|
|
587
|
+
$descriptor: RestartDevlabRequest_MESSAGE_DESCRIPTOR,
|
|
588
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
589
|
+
if (message.id !== "") {
|
|
590
|
+
writer.uint32(10).string(message.id);
|
|
591
|
+
}
|
|
592
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
593
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
594
|
+
}
|
|
595
|
+
return writer;
|
|
596
|
+
},
|
|
597
|
+
decode(input, length) {
|
|
598
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
599
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
600
|
+
const message = createBaseRestartDevlabRequest();
|
|
601
|
+
let writer = undefined;
|
|
602
|
+
while (reader.pos < end) {
|
|
603
|
+
const tag = reader.uint32();
|
|
604
|
+
switch (tag >>> 3) {
|
|
605
|
+
case 1: {
|
|
606
|
+
if (tag !== 10)
|
|
607
|
+
break;
|
|
608
|
+
message.id = reader.string();
|
|
609
|
+
continue;
|
|
610
|
+
}
|
|
611
|
+
default:
|
|
612
|
+
break;
|
|
613
|
+
}
|
|
614
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
615
|
+
break;
|
|
616
|
+
}
|
|
617
|
+
{
|
|
618
|
+
if (!writer)
|
|
619
|
+
writer = new index_js_1.BinaryWriter();
|
|
620
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
621
|
+
writer.uint32(tag).raw(skipped);
|
|
622
|
+
}
|
|
623
|
+
}
|
|
624
|
+
if (writer) {
|
|
625
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
626
|
+
}
|
|
627
|
+
return message;
|
|
628
|
+
},
|
|
629
|
+
fromJSON(object) {
|
|
630
|
+
return applyRestartDevlabRequestCustom({
|
|
631
|
+
$type: "nebius.ai.v1.RestartDevlabRequest",
|
|
632
|
+
id: (0, index_js_1.isSet)(object.id ?? object.id)
|
|
633
|
+
? String(object.id ?? object.id)
|
|
634
|
+
: "",
|
|
635
|
+
});
|
|
636
|
+
},
|
|
637
|
+
toJSON(message, use = "json") {
|
|
638
|
+
const obj = {};
|
|
639
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
640
|
+
if (message.id !== "") {
|
|
641
|
+
obj[pick("id", "id")] = message.id;
|
|
642
|
+
}
|
|
643
|
+
return obj;
|
|
644
|
+
},
|
|
645
|
+
create(base) {
|
|
646
|
+
return exports.RestartDevlabRequest.fromPartial(base ?? {});
|
|
647
|
+
},
|
|
648
|
+
fromPartial(object) {
|
|
649
|
+
const message = createBaseRestartDevlabRequest();
|
|
650
|
+
message.id = (object.id !== undefined && object.id !== null)
|
|
651
|
+
? object.id
|
|
652
|
+
: "";
|
|
653
|
+
return message;
|
|
654
|
+
},
|
|
655
|
+
};
|
|
656
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.RestartDevlabRequest);
|
|
657
|
+
function RestartDevlabRequestCustomInspect() {
|
|
658
|
+
const parts = [];
|
|
659
|
+
if (this.id !== "")
|
|
660
|
+
parts.push("id" + "=" + (0, util_1.inspect)(this.id));
|
|
661
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
662
|
+
}
|
|
663
|
+
function RestartDevlabRequestCustomJson() {
|
|
664
|
+
const obj = {
|
|
665
|
+
type: this.$type,
|
|
666
|
+
};
|
|
667
|
+
if (this.id !== "")
|
|
668
|
+
obj.id = (0, logging_js_1.inspectJson)(this.id);
|
|
669
|
+
return obj;
|
|
670
|
+
}
|
|
671
|
+
function applyRestartDevlabRequestCustom(message) {
|
|
672
|
+
message[logging_js_1.custom] = RestartDevlabRequestCustomInspect;
|
|
673
|
+
message[logging_js_1.customJson] = RestartDevlabRequestCustomJson;
|
|
674
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.RestartDevlabRequest.$descriptor);
|
|
675
|
+
}
|
|
676
|
+
function createBaseRestartDevlabRequest() {
|
|
677
|
+
const message = {
|
|
678
|
+
$type: "nebius.ai.v1.RestartDevlabRequest",
|
|
679
|
+
id: "",
|
|
680
|
+
};
|
|
681
|
+
return applyRestartDevlabRequestCustom(message);
|
|
682
|
+
}
|
|
683
|
+
const StopDevlabRequest_MESSAGE_DESCRIPTOR = {
|
|
684
|
+
fields: {
|
|
685
|
+
"id": { pbName: "id", scalarType: 9 },
|
|
686
|
+
},
|
|
687
|
+
};
|
|
688
|
+
/** Encodes, decodes, converts, and creates {@link StopDevlabRequest} messages. */
|
|
689
|
+
exports.StopDevlabRequest = {
|
|
690
|
+
$type: "nebius.ai.v1.StopDevlabRequest",
|
|
691
|
+
$descriptor: StopDevlabRequest_MESSAGE_DESCRIPTOR,
|
|
692
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
693
|
+
if (message.id !== "") {
|
|
694
|
+
writer.uint32(10).string(message.id);
|
|
695
|
+
}
|
|
696
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
697
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
698
|
+
}
|
|
699
|
+
return writer;
|
|
700
|
+
},
|
|
701
|
+
decode(input, length) {
|
|
702
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
703
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
704
|
+
const message = createBaseStopDevlabRequest();
|
|
705
|
+
let writer = undefined;
|
|
706
|
+
while (reader.pos < end) {
|
|
707
|
+
const tag = reader.uint32();
|
|
708
|
+
switch (tag >>> 3) {
|
|
709
|
+
case 1: {
|
|
710
|
+
if (tag !== 10)
|
|
711
|
+
break;
|
|
712
|
+
message.id = reader.string();
|
|
713
|
+
continue;
|
|
714
|
+
}
|
|
715
|
+
default:
|
|
716
|
+
break;
|
|
717
|
+
}
|
|
718
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
719
|
+
break;
|
|
720
|
+
}
|
|
721
|
+
{
|
|
722
|
+
if (!writer)
|
|
723
|
+
writer = new index_js_1.BinaryWriter();
|
|
724
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
725
|
+
writer.uint32(tag).raw(skipped);
|
|
726
|
+
}
|
|
727
|
+
}
|
|
728
|
+
if (writer) {
|
|
729
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
730
|
+
}
|
|
731
|
+
return message;
|
|
732
|
+
},
|
|
733
|
+
fromJSON(object) {
|
|
734
|
+
return applyStopDevlabRequestCustom({
|
|
735
|
+
$type: "nebius.ai.v1.StopDevlabRequest",
|
|
736
|
+
id: (0, index_js_1.isSet)(object.id ?? object.id)
|
|
737
|
+
? String(object.id ?? object.id)
|
|
738
|
+
: "",
|
|
739
|
+
});
|
|
740
|
+
},
|
|
741
|
+
toJSON(message, use = "json") {
|
|
742
|
+
const obj = {};
|
|
743
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
744
|
+
if (message.id !== "") {
|
|
745
|
+
obj[pick("id", "id")] = message.id;
|
|
746
|
+
}
|
|
747
|
+
return obj;
|
|
748
|
+
},
|
|
749
|
+
create(base) {
|
|
750
|
+
return exports.StopDevlabRequest.fromPartial(base ?? {});
|
|
751
|
+
},
|
|
752
|
+
fromPartial(object) {
|
|
753
|
+
const message = createBaseStopDevlabRequest();
|
|
754
|
+
message.id = (object.id !== undefined && object.id !== null)
|
|
755
|
+
? object.id
|
|
756
|
+
: "";
|
|
757
|
+
return message;
|
|
758
|
+
},
|
|
759
|
+
};
|
|
760
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.StopDevlabRequest);
|
|
761
|
+
function StopDevlabRequestCustomInspect() {
|
|
762
|
+
const parts = [];
|
|
763
|
+
if (this.id !== "")
|
|
764
|
+
parts.push("id" + "=" + (0, util_1.inspect)(this.id));
|
|
765
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
766
|
+
}
|
|
767
|
+
function StopDevlabRequestCustomJson() {
|
|
768
|
+
const obj = {
|
|
769
|
+
type: this.$type,
|
|
770
|
+
};
|
|
771
|
+
if (this.id !== "")
|
|
772
|
+
obj.id = (0, logging_js_1.inspectJson)(this.id);
|
|
773
|
+
return obj;
|
|
774
|
+
}
|
|
775
|
+
function applyStopDevlabRequestCustom(message) {
|
|
776
|
+
message[logging_js_1.custom] = StopDevlabRequestCustomInspect;
|
|
777
|
+
message[logging_js_1.customJson] = StopDevlabRequestCustomJson;
|
|
778
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.StopDevlabRequest.$descriptor);
|
|
779
|
+
}
|
|
780
|
+
function createBaseStopDevlabRequest() {
|
|
781
|
+
const message = {
|
|
782
|
+
$type: "nebius.ai.v1.StopDevlabRequest",
|
|
783
|
+
id: "",
|
|
784
|
+
};
|
|
785
|
+
return applyStopDevlabRequestCustom(message);
|
|
786
|
+
}
|
|
787
|
+
const ListDevlabsResponse_MESSAGE_DESCRIPTOR = {
|
|
788
|
+
fields: {
|
|
789
|
+
"items": { pbName: "items", repeated: true, message: () => exports.Devlab.$descriptor },
|
|
790
|
+
"nextPageToken": { pbName: "next_page_token", scalarType: 9 },
|
|
791
|
+
},
|
|
792
|
+
};
|
|
793
|
+
/** Encodes, decodes, converts, and creates {@link ListDevlabsResponse} messages. */
|
|
794
|
+
exports.ListDevlabsResponse = {
|
|
795
|
+
$type: "nebius.ai.v1.ListDevlabsResponse",
|
|
796
|
+
$descriptor: ListDevlabsResponse_MESSAGE_DESCRIPTOR,
|
|
797
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
798
|
+
for (const v of (message.items ?? [])) {
|
|
799
|
+
const w = writer.uint32(10).fork();
|
|
800
|
+
exports.Devlab.encode(v, w);
|
|
801
|
+
w.join();
|
|
802
|
+
}
|
|
803
|
+
if (message.nextPageToken !== "") {
|
|
804
|
+
writer.uint32(18).string(message.nextPageToken);
|
|
805
|
+
}
|
|
806
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
807
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
808
|
+
}
|
|
809
|
+
return writer;
|
|
810
|
+
},
|
|
811
|
+
decode(input, length) {
|
|
812
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
813
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
814
|
+
const message = createBaseListDevlabsResponse();
|
|
815
|
+
let writer = undefined;
|
|
816
|
+
while (reader.pos < end) {
|
|
817
|
+
const tag = reader.uint32();
|
|
818
|
+
switch (tag >>> 3) {
|
|
819
|
+
case 1: {
|
|
820
|
+
if (tag !== 10)
|
|
821
|
+
break;
|
|
822
|
+
message.items.push(exports.Devlab.decode(reader, reader.uint32()));
|
|
823
|
+
continue;
|
|
824
|
+
}
|
|
825
|
+
case 2: {
|
|
826
|
+
if (tag !== 18)
|
|
827
|
+
break;
|
|
828
|
+
message.nextPageToken = reader.string();
|
|
829
|
+
continue;
|
|
830
|
+
}
|
|
831
|
+
default:
|
|
832
|
+
break;
|
|
833
|
+
}
|
|
834
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
835
|
+
break;
|
|
836
|
+
}
|
|
837
|
+
{
|
|
838
|
+
if (!writer)
|
|
839
|
+
writer = new index_js_1.BinaryWriter();
|
|
840
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
841
|
+
writer.uint32(tag).raw(skipped);
|
|
842
|
+
}
|
|
843
|
+
}
|
|
844
|
+
if (writer) {
|
|
845
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
846
|
+
}
|
|
847
|
+
return message;
|
|
848
|
+
},
|
|
849
|
+
fromJSON(object) {
|
|
850
|
+
return applyListDevlabsResponseCustom({
|
|
851
|
+
$type: "nebius.ai.v1.ListDevlabsResponse",
|
|
852
|
+
items: globalThis.Array.isArray(object?.items ?? object?.items)
|
|
853
|
+
? (object.items ?? object.items).map((e) => exports.Devlab.fromJSON(e))
|
|
854
|
+
: [],
|
|
855
|
+
nextPageToken: (0, index_js_1.isSet)(object.nextPageToken ?? object.next_page_token)
|
|
856
|
+
? String(object.nextPageToken ?? object.next_page_token)
|
|
857
|
+
: "",
|
|
858
|
+
});
|
|
859
|
+
},
|
|
860
|
+
toJSON(message, use = "json") {
|
|
861
|
+
const obj = {};
|
|
862
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
863
|
+
if (message.items?.length) {
|
|
864
|
+
obj[pick("items", "items")] = message.items.map((e) => e ? exports.Devlab.toJSON(e, use) : undefined);
|
|
865
|
+
}
|
|
866
|
+
if (message.nextPageToken !== "") {
|
|
867
|
+
obj[pick("nextPageToken", "next_page_token")] = message.nextPageToken;
|
|
868
|
+
}
|
|
869
|
+
return obj;
|
|
870
|
+
},
|
|
871
|
+
create(base) {
|
|
872
|
+
return exports.ListDevlabsResponse.fromPartial(base ?? {});
|
|
873
|
+
},
|
|
874
|
+
fromPartial(object) {
|
|
875
|
+
const message = createBaseListDevlabsResponse();
|
|
876
|
+
message.items = object.items?.map((e) => exports.Devlab.fromPartial(e)) || [];
|
|
877
|
+
message.nextPageToken = (object.nextPageToken !== undefined && object.nextPageToken !== null)
|
|
878
|
+
? object.nextPageToken
|
|
879
|
+
: "";
|
|
880
|
+
return message;
|
|
881
|
+
},
|
|
882
|
+
};
|
|
883
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.ListDevlabsResponse);
|
|
884
|
+
function ListDevlabsResponseCustomInspect() {
|
|
885
|
+
const parts = [];
|
|
886
|
+
if ((this.items?.length ?? 0) !== 0)
|
|
887
|
+
parts.push("items" + "=" + (0, util_1.inspect)(this.items));
|
|
888
|
+
if (this.nextPageToken !== "")
|
|
889
|
+
parts.push("nextPageToken" + "=" + (0, util_1.inspect)(this.nextPageToken));
|
|
890
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
891
|
+
}
|
|
892
|
+
function ListDevlabsResponseCustomJson() {
|
|
893
|
+
const obj = {
|
|
894
|
+
type: this.$type,
|
|
895
|
+
};
|
|
896
|
+
if ((this.items?.length ?? 0) !== 0)
|
|
897
|
+
obj.items = (0, logging_js_1.inspectJson)(this.items);
|
|
898
|
+
if (this.nextPageToken !== "")
|
|
899
|
+
obj.nextPageToken = (0, logging_js_1.inspectJson)(this.nextPageToken);
|
|
900
|
+
return obj;
|
|
901
|
+
}
|
|
902
|
+
function applyListDevlabsResponseCustom(message) {
|
|
903
|
+
message[logging_js_1.custom] = ListDevlabsResponseCustomInspect;
|
|
904
|
+
message[logging_js_1.customJson] = ListDevlabsResponseCustomJson;
|
|
905
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.ListDevlabsResponse.$descriptor);
|
|
906
|
+
}
|
|
907
|
+
function createBaseListDevlabsResponse() {
|
|
908
|
+
const message = {
|
|
909
|
+
$type: "nebius.ai.v1.ListDevlabsResponse",
|
|
910
|
+
items: [],
|
|
911
|
+
nextPageToken: "",
|
|
912
|
+
};
|
|
913
|
+
return applyListDevlabsResponseCustom(message);
|
|
914
|
+
}
|
|
915
|
+
/**
|
|
916
|
+
* Describes the gRPC methods for the `nebius.ai.v1.DevlabService` service.
|
|
917
|
+
*/
|
|
918
|
+
exports.DevlabServiceServiceDescription = {
|
|
919
|
+
get: {
|
|
920
|
+
path: "/nebius.ai.v1.DevlabService/Get",
|
|
921
|
+
requestStream: false,
|
|
922
|
+
responseStream: false,
|
|
923
|
+
requestSerialize: (value) => Buffer.from(exports.GetDevlabRequest.encode(value).finish()),
|
|
924
|
+
requestDescriptor: () => exports.GetDevlabRequest.$descriptor,
|
|
925
|
+
sendResetMask: false,
|
|
926
|
+
requestDeserialize: (value) => exports.GetDevlabRequest.decode(value),
|
|
927
|
+
responseSerialize: (value) => Buffer.from(exports.Devlab.encode(value).finish()),
|
|
928
|
+
responseDeserialize: (value) => exports.Devlab.decode(value),
|
|
929
|
+
},
|
|
930
|
+
getByName: {
|
|
931
|
+
path: "/nebius.ai.v1.DevlabService/GetByName",
|
|
932
|
+
requestStream: false,
|
|
933
|
+
responseStream: false,
|
|
934
|
+
requestSerialize: (value) => Buffer.from(index_js_2.GetByNameRequest.encode(value).finish()),
|
|
935
|
+
requestDescriptor: () => index_js_2.GetByNameRequest.$descriptor,
|
|
936
|
+
sendResetMask: false,
|
|
937
|
+
requestDeserialize: (value) => index_js_2.GetByNameRequest.decode(value),
|
|
938
|
+
responseSerialize: (value) => Buffer.from(exports.Devlab.encode(value).finish()),
|
|
939
|
+
responseDeserialize: (value) => exports.Devlab.decode(value),
|
|
940
|
+
},
|
|
941
|
+
list: {
|
|
942
|
+
path: "/nebius.ai.v1.DevlabService/List",
|
|
943
|
+
requestStream: false,
|
|
944
|
+
responseStream: false,
|
|
945
|
+
requestSerialize: (value) => Buffer.from(exports.ListDevlabsRequest.encode(value).finish()),
|
|
946
|
+
requestDescriptor: () => exports.ListDevlabsRequest.$descriptor,
|
|
947
|
+
sendResetMask: false,
|
|
948
|
+
requestDeserialize: (value) => exports.ListDevlabsRequest.decode(value),
|
|
949
|
+
responseSerialize: (value) => Buffer.from(exports.ListDevlabsResponse.encode(value).finish()),
|
|
950
|
+
responseDeserialize: (value) => exports.ListDevlabsResponse.decode(value),
|
|
951
|
+
},
|
|
952
|
+
create: {
|
|
953
|
+
path: "/nebius.ai.v1.DevlabService/Create",
|
|
954
|
+
requestStream: false,
|
|
955
|
+
responseStream: false,
|
|
956
|
+
requestSerialize: (value) => Buffer.from(exports.CreateDevlabRequest.encode(value).finish()),
|
|
957
|
+
requestDescriptor: () => exports.CreateDevlabRequest.$descriptor,
|
|
958
|
+
sendResetMask: false,
|
|
959
|
+
requestDeserialize: (value) => exports.CreateDevlabRequest.decode(value),
|
|
960
|
+
responseSerialize: (value) => Buffer.from(index_js_2.Operation.encode(value).finish()),
|
|
961
|
+
responseDeserialize: (value) => index_js_2.Operation.decode(value),
|
|
962
|
+
},
|
|
963
|
+
delete: {
|
|
964
|
+
path: "/nebius.ai.v1.DevlabService/Delete",
|
|
965
|
+
requestStream: false,
|
|
966
|
+
responseStream: false,
|
|
967
|
+
requestSerialize: (value) => Buffer.from(exports.DeleteDevlabRequest.encode(value).finish()),
|
|
968
|
+
requestDescriptor: () => exports.DeleteDevlabRequest.$descriptor,
|
|
969
|
+
sendResetMask: false,
|
|
970
|
+
requestDeserialize: (value) => exports.DeleteDevlabRequest.decode(value),
|
|
971
|
+
responseSerialize: (value) => Buffer.from(index_js_2.Operation.encode(value).finish()),
|
|
972
|
+
responseDeserialize: (value) => index_js_2.Operation.decode(value),
|
|
973
|
+
},
|
|
974
|
+
restart: {
|
|
975
|
+
path: "/nebius.ai.v1.DevlabService/Restart",
|
|
976
|
+
requestStream: false,
|
|
977
|
+
responseStream: false,
|
|
978
|
+
requestSerialize: (value) => Buffer.from(exports.RestartDevlabRequest.encode(value).finish()),
|
|
979
|
+
requestDescriptor: () => exports.RestartDevlabRequest.$descriptor,
|
|
980
|
+
sendResetMask: false,
|
|
981
|
+
requestDeserialize: (value) => exports.RestartDevlabRequest.decode(value),
|
|
982
|
+
responseSerialize: (value) => Buffer.from(index_js_2.Operation.encode(value).finish()),
|
|
983
|
+
responseDeserialize: (value) => index_js_2.Operation.decode(value),
|
|
984
|
+
},
|
|
985
|
+
stop: {
|
|
986
|
+
path: "/nebius.ai.v1.DevlabService/Stop",
|
|
987
|
+
requestStream: false,
|
|
988
|
+
responseStream: false,
|
|
989
|
+
requestSerialize: (value) => Buffer.from(exports.StopDevlabRequest.encode(value).finish()),
|
|
990
|
+
requestDescriptor: () => exports.StopDevlabRequest.$descriptor,
|
|
991
|
+
sendResetMask: false,
|
|
992
|
+
requestDeserialize: (value) => exports.StopDevlabRequest.decode(value),
|
|
993
|
+
responseSerialize: (value) => Buffer.from(index_js_2.Operation.encode(value).finish()),
|
|
994
|
+
responseDeserialize: (value) => index_js_2.Operation.decode(value),
|
|
995
|
+
},
|
|
996
|
+
};
|
|
997
|
+
/**
|
|
998
|
+
* Creates low-level gRPC clients for the `nebius.ai.v1.DevlabService` service.
|
|
999
|
+
*/
|
|
1000
|
+
exports.DevlabServiceBaseClient = (0, grpc_js_1.makeGenericClientConstructor)(exports.DevlabServiceServiceDescription, "nebius.ai.v1.DevlabService");
|
|
1001
|
+
/**
|
|
1002
|
+
* Calls the `nebius.ai.v1.DevlabService` service through the Nebius SDK.
|
|
1003
|
+
*/
|
|
1004
|
+
class DevlabService {
|
|
1005
|
+
sdk;
|
|
1006
|
+
$type = "nebius.ai.v1.DevlabService";
|
|
1007
|
+
addr;
|
|
1008
|
+
spec;
|
|
1009
|
+
apiServiceName = "apps.msp";
|
|
1010
|
+
/** Creates a client that uses the SDK service address. */
|
|
1011
|
+
constructor(sdk) {
|
|
1012
|
+
this.sdk = sdk;
|
|
1013
|
+
const addr = sdk.getAddressFromServiceName(this.$type, this.apiServiceName);
|
|
1014
|
+
this.addr = addr;
|
|
1015
|
+
this.spec = exports.DevlabServiceServiceDescription;
|
|
1016
|
+
}
|
|
1017
|
+
/** Returns the operation service for this service address. */
|
|
1018
|
+
getOperationService() {
|
|
1019
|
+
return new index_js_2.OperationService(this.sdk, this.addr);
|
|
1020
|
+
}
|
|
1021
|
+
/**
|
|
1022
|
+
* Returns the specified Devlab.
|
|
1023
|
+
*
|
|
1024
|
+
*/
|
|
1025
|
+
get(...args) {
|
|
1026
|
+
const spec = this.spec.get;
|
|
1027
|
+
const request = args[0];
|
|
1028
|
+
const metadata = (args.length > 1 ? args[1] : undefined);
|
|
1029
|
+
const options = (args.length > 2 ? args[2] : undefined);
|
|
1030
|
+
const deserialize = spec.responseDeserialize;
|
|
1031
|
+
return new request_js_1.Request(this.sdk, spec, this.addr, deserialize, request, metadata, options);
|
|
1032
|
+
}
|
|
1033
|
+
/**
|
|
1034
|
+
* Returns the specified Devlab by name.
|
|
1035
|
+
*
|
|
1036
|
+
*/
|
|
1037
|
+
getByName(...args) {
|
|
1038
|
+
const spec = this.spec.getByName;
|
|
1039
|
+
const request = args[0];
|
|
1040
|
+
const metadata = (args.length > 1 ? args[1] : undefined);
|
|
1041
|
+
const options = (args.length > 2 ? args[2] : undefined);
|
|
1042
|
+
const deserialize = spec.responseDeserialize;
|
|
1043
|
+
return new request_js_1.Request(this.sdk, spec, this.addr, deserialize, request, metadata, options);
|
|
1044
|
+
}
|
|
1045
|
+
/**
|
|
1046
|
+
* Retrieves a list of Devlabs.
|
|
1047
|
+
*
|
|
1048
|
+
*/
|
|
1049
|
+
list(...args) {
|
|
1050
|
+
const spec = this.spec.list;
|
|
1051
|
+
const request = args[0];
|
|
1052
|
+
const metadata = (args.length > 1 ? args[1] : undefined);
|
|
1053
|
+
const options = (args.length > 2 ? args[2] : undefined);
|
|
1054
|
+
const deserialize = spec.responseDeserialize;
|
|
1055
|
+
return new request_js_1.Request(this.sdk, spec, this.addr, deserialize, request, metadata, options);
|
|
1056
|
+
}
|
|
1057
|
+
/**
|
|
1058
|
+
* Creates a Devlab.
|
|
1059
|
+
*
|
|
1060
|
+
*/
|
|
1061
|
+
create(...args) {
|
|
1062
|
+
const spec = this.spec.create;
|
|
1063
|
+
const request = args[0];
|
|
1064
|
+
const metadata = (args.length > 1 ? args[1] : undefined);
|
|
1065
|
+
const options = (args.length > 2 ? args[2] : undefined);
|
|
1066
|
+
const deserialize = (value) => {
|
|
1067
|
+
const resp = spec.responseDeserialize(value);
|
|
1068
|
+
return new operation_js_1.Operation(resp, this.getOperationService(), this.sdk.logger.child("operation"));
|
|
1069
|
+
};
|
|
1070
|
+
return new request_js_1.Request(this.sdk, spec, this.addr, deserialize, request, metadata, options);
|
|
1071
|
+
}
|
|
1072
|
+
/**
|
|
1073
|
+
* Deletes a Devlab.
|
|
1074
|
+
*
|
|
1075
|
+
*/
|
|
1076
|
+
delete(...args) {
|
|
1077
|
+
const spec = this.spec.delete;
|
|
1078
|
+
const request = args[0];
|
|
1079
|
+
const metadata = (args.length > 1 ? args[1] : undefined);
|
|
1080
|
+
const options = (args.length > 2 ? args[2] : undefined);
|
|
1081
|
+
const deserialize = (value) => {
|
|
1082
|
+
const resp = spec.responseDeserialize(value);
|
|
1083
|
+
return new operation_js_1.Operation(resp, this.getOperationService(), this.sdk.logger.child("operation"));
|
|
1084
|
+
};
|
|
1085
|
+
return new request_js_1.Request(this.sdk, spec, this.addr, deserialize, request, metadata, options);
|
|
1086
|
+
}
|
|
1087
|
+
/**
|
|
1088
|
+
* Restarts a Devlab.
|
|
1089
|
+
*
|
|
1090
|
+
*/
|
|
1091
|
+
restart(...args) {
|
|
1092
|
+
const spec = this.spec.restart;
|
|
1093
|
+
const request = args[0];
|
|
1094
|
+
const metadata = (args.length > 1 ? args[1] : undefined);
|
|
1095
|
+
const options = (args.length > 2 ? args[2] : undefined);
|
|
1096
|
+
const deserialize = (value) => {
|
|
1097
|
+
const resp = spec.responseDeserialize(value);
|
|
1098
|
+
return new operation_js_1.Operation(resp, this.getOperationService(), this.sdk.logger.child("operation"));
|
|
1099
|
+
};
|
|
1100
|
+
return new request_js_1.Request(this.sdk, spec, this.addr, deserialize, request, metadata, options);
|
|
1101
|
+
}
|
|
1102
|
+
/**
|
|
1103
|
+
* Stops a Devlab.
|
|
1104
|
+
*
|
|
1105
|
+
*/
|
|
1106
|
+
stop(...args) {
|
|
1107
|
+
const spec = this.spec.stop;
|
|
1108
|
+
const request = args[0];
|
|
1109
|
+
const metadata = (args.length > 1 ? args[1] : undefined);
|
|
1110
|
+
const options = (args.length > 2 ? args[2] : undefined);
|
|
1111
|
+
const deserialize = (value) => {
|
|
1112
|
+
const resp = spec.responseDeserialize(value);
|
|
1113
|
+
return new operation_js_1.Operation(resp, this.getOperationService(), this.sdk.logger.child("operation"));
|
|
1114
|
+
};
|
|
1115
|
+
return new request_js_1.Request(this.sdk, spec, this.addr, deserialize, request, metadata, options);
|
|
1116
|
+
}
|
|
1117
|
+
}
|
|
1118
|
+
exports.DevlabService = DevlabService;
|
|
1119
|
+
const DevlabSpec_Port_Protocol_VALUE_COMMENTS = {
|
|
1120
|
+
PROTOCOL_UNSPECIFIED: " No protocol selected. Specify HTTP, TCP, or UDP.\n",
|
|
1121
|
+
HTTP: " HTTP protocol.\n",
|
|
1122
|
+
TCP: " TCP protocol.\n",
|
|
1123
|
+
UDP: " UDP protocol.\n",
|
|
1124
|
+
};
|
|
1125
|
+
/** Converts and creates {@link DevlabSpec_Port_Protocol} values. */
|
|
1126
|
+
exports.DevlabSpec_Port_Protocol = (0, index_js_1.createEnum)("nebius.ai.v1.DevlabSpec.Port.Protocol", {
|
|
1127
|
+
/**
|
|
1128
|
+
* No protocol selected. Specify HTTP, TCP, or UDP.
|
|
1129
|
+
*
|
|
1130
|
+
*/
|
|
1131
|
+
PROTOCOL_UNSPECIFIED: 0,
|
|
1132
|
+
/**
|
|
1133
|
+
* HTTP protocol.
|
|
1134
|
+
*
|
|
1135
|
+
*/
|
|
1136
|
+
HTTP: 1,
|
|
1137
|
+
/**
|
|
1138
|
+
* TCP protocol.
|
|
1139
|
+
*
|
|
1140
|
+
*/
|
|
1141
|
+
TCP: 2,
|
|
1142
|
+
/**
|
|
1143
|
+
* UDP protocol.
|
|
1144
|
+
*
|
|
1145
|
+
*/
|
|
1146
|
+
UDP: 3,
|
|
1147
|
+
}, DevlabSpec_Port_Protocol_VALUE_COMMENTS);
|
|
1148
|
+
protobuf_js_1.protoRegistry.registerEnum(exports.DevlabSpec_Port_Protocol);
|
|
1149
|
+
const DevlabSpec_VolumeMount_Mode_VALUE_COMMENTS = {
|
|
1150
|
+
MODE_UNSPECIFIED: " No mount mode selected. Specify READ_WRITE or READ_ONLY.\n",
|
|
1151
|
+
READ_WRITE: " Read-write mode.\n",
|
|
1152
|
+
READ_ONLY: " Read-only mode.\n",
|
|
1153
|
+
};
|
|
1154
|
+
/** Converts and creates {@link DevlabSpec_VolumeMount_Mode} values. */
|
|
1155
|
+
exports.DevlabSpec_VolumeMount_Mode = (0, index_js_1.createEnum)("nebius.ai.v1.DevlabSpec.VolumeMount.Mode", {
|
|
1156
|
+
/**
|
|
1157
|
+
* No mount mode selected. Specify READ_WRITE or READ_ONLY.
|
|
1158
|
+
*
|
|
1159
|
+
*/
|
|
1160
|
+
MODE_UNSPECIFIED: 0,
|
|
1161
|
+
/**
|
|
1162
|
+
* Read-write mode.
|
|
1163
|
+
*
|
|
1164
|
+
*/
|
|
1165
|
+
READ_WRITE: 1,
|
|
1166
|
+
/**
|
|
1167
|
+
* Read-only mode.
|
|
1168
|
+
*
|
|
1169
|
+
*/
|
|
1170
|
+
READ_ONLY: 2,
|
|
1171
|
+
}, DevlabSpec_VolumeMount_Mode_VALUE_COMMENTS);
|
|
1172
|
+
protobuf_js_1.protoRegistry.registerEnum(exports.DevlabSpec_VolumeMount_Mode);
|
|
1173
|
+
const DevlabStatus_State_VALUE_COMMENTS = {
|
|
1174
|
+
STATE_UNSPECIFIED: " The service did not report the Devlab's state.\n",
|
|
1175
|
+
PROVISIONING: " The Devlab is creating resources.\n",
|
|
1176
|
+
STARTING: " The Devlab is being started.\n",
|
|
1177
|
+
RUNNING: " The Devlab is running.\n",
|
|
1178
|
+
STOPPING: " The Devlab is being stopped.\n",
|
|
1179
|
+
DELETING: " The Devlab is being deleted.\n",
|
|
1180
|
+
STOPPED: " The Devlab has been stopped.\n",
|
|
1181
|
+
FAILED: " The Devlab has failed.\n",
|
|
1182
|
+
ERROR: " The Devlab encountered an error.\n",
|
|
1183
|
+
IMAGE_PULLING: " The Devlab is pulling an image (STARTING -> IMAGE_PULLING -> RUNNING).\n",
|
|
1184
|
+
};
|
|
1185
|
+
/** Converts and creates {@link DevlabStatus_State} values. */
|
|
1186
|
+
exports.DevlabStatus_State = (0, index_js_1.createEnum)("nebius.ai.v1.DevlabStatus.State", {
|
|
1187
|
+
/**
|
|
1188
|
+
* The service did not report the Devlab's state.
|
|
1189
|
+
*
|
|
1190
|
+
*/
|
|
1191
|
+
STATE_UNSPECIFIED: 0,
|
|
1192
|
+
/**
|
|
1193
|
+
* The Devlab is creating resources.
|
|
1194
|
+
*
|
|
1195
|
+
*/
|
|
1196
|
+
PROVISIONING: 1,
|
|
1197
|
+
/**
|
|
1198
|
+
* The Devlab is being started.
|
|
1199
|
+
*
|
|
1200
|
+
*/
|
|
1201
|
+
STARTING: 2,
|
|
1202
|
+
/**
|
|
1203
|
+
* The Devlab is running.
|
|
1204
|
+
*
|
|
1205
|
+
*/
|
|
1206
|
+
RUNNING: 3,
|
|
1207
|
+
/**
|
|
1208
|
+
* The Devlab is being stopped.
|
|
1209
|
+
*
|
|
1210
|
+
*/
|
|
1211
|
+
STOPPING: 4,
|
|
1212
|
+
/**
|
|
1213
|
+
* The Devlab is being deleted.
|
|
1214
|
+
*
|
|
1215
|
+
*/
|
|
1216
|
+
DELETING: 5,
|
|
1217
|
+
/**
|
|
1218
|
+
* The Devlab has been stopped.
|
|
1219
|
+
*
|
|
1220
|
+
*/
|
|
1221
|
+
STOPPED: 6,
|
|
1222
|
+
/**
|
|
1223
|
+
* The Devlab has failed.
|
|
1224
|
+
*
|
|
1225
|
+
*/
|
|
1226
|
+
FAILED: 7,
|
|
1227
|
+
/**
|
|
1228
|
+
* The Devlab encountered an error.
|
|
1229
|
+
*
|
|
1230
|
+
*/
|
|
1231
|
+
ERROR: 8,
|
|
1232
|
+
/**
|
|
1233
|
+
* The Devlab is pulling an image (STARTING -> IMAGE_PULLING -> RUNNING).
|
|
1234
|
+
*
|
|
1235
|
+
*/
|
|
1236
|
+
IMAGE_PULLING: 9,
|
|
1237
|
+
}, DevlabStatus_State_VALUE_COMMENTS);
|
|
1238
|
+
protobuf_js_1.protoRegistry.registerEnum(exports.DevlabStatus_State);
|
|
1239
|
+
const DevlabInstanceStatus_State_VALUE_COMMENTS = {
|
|
1240
|
+
STATE_UNSPECIFIED: " The service did not report the instance's state.\n",
|
|
1241
|
+
PROVISIONING: " The Devlab is creating resources.\n",
|
|
1242
|
+
STARTING: " The Devlab is being started.\n",
|
|
1243
|
+
RUNNING: " The Devlab is running.\n",
|
|
1244
|
+
STOPPING: " The Devlab is being stopped.\n",
|
|
1245
|
+
DELETING: " The Devlab is being deleted.\n",
|
|
1246
|
+
STOPPED: " The Devlab has been stopped.\n",
|
|
1247
|
+
FAILED: " The Devlab has failed.\n",
|
|
1248
|
+
ERROR: " The Devlab encountered an error.\n",
|
|
1249
|
+
IMAGE_PULLING: " The Devlab is pulling an image (STARTING -> IMAGE_PULLING -> RUNNING).\n",
|
|
1250
|
+
};
|
|
1251
|
+
/** Converts and creates {@link DevlabInstanceStatus_State} values. */
|
|
1252
|
+
exports.DevlabInstanceStatus_State = (0, index_js_1.createEnum)("nebius.ai.v1.DevlabInstanceStatus.State", {
|
|
1253
|
+
/**
|
|
1254
|
+
* The service did not report the instance's state.
|
|
1255
|
+
*
|
|
1256
|
+
*/
|
|
1257
|
+
STATE_UNSPECIFIED: 0,
|
|
1258
|
+
/**
|
|
1259
|
+
* The Devlab is creating resources.
|
|
1260
|
+
*
|
|
1261
|
+
*/
|
|
1262
|
+
PROVISIONING: 1,
|
|
1263
|
+
/**
|
|
1264
|
+
* The Devlab is being started.
|
|
1265
|
+
*
|
|
1266
|
+
*/
|
|
1267
|
+
STARTING: 2,
|
|
1268
|
+
/**
|
|
1269
|
+
* The Devlab is running.
|
|
1270
|
+
*
|
|
1271
|
+
*/
|
|
1272
|
+
RUNNING: 3,
|
|
1273
|
+
/**
|
|
1274
|
+
* The Devlab is being stopped.
|
|
1275
|
+
*
|
|
1276
|
+
*/
|
|
1277
|
+
STOPPING: 4,
|
|
1278
|
+
/**
|
|
1279
|
+
* The Devlab is being deleted.
|
|
1280
|
+
*
|
|
1281
|
+
*/
|
|
1282
|
+
DELETING: 5,
|
|
1283
|
+
/**
|
|
1284
|
+
* The Devlab has been stopped.
|
|
1285
|
+
*
|
|
1286
|
+
*/
|
|
1287
|
+
STOPPED: 6,
|
|
1288
|
+
/**
|
|
1289
|
+
* The Devlab has failed.
|
|
1290
|
+
*
|
|
1291
|
+
*/
|
|
1292
|
+
FAILED: 7,
|
|
1293
|
+
/**
|
|
1294
|
+
* The Devlab encountered an error.
|
|
1295
|
+
*
|
|
1296
|
+
*/
|
|
1297
|
+
ERROR: 8,
|
|
1298
|
+
/**
|
|
1299
|
+
* The Devlab is pulling an image (STARTING -> IMAGE_PULLING -> RUNNING).
|
|
1300
|
+
*
|
|
1301
|
+
*/
|
|
1302
|
+
IMAGE_PULLING: 9,
|
|
1303
|
+
}, DevlabInstanceStatus_State_VALUE_COMMENTS);
|
|
1304
|
+
protobuf_js_1.protoRegistry.registerEnum(exports.DevlabInstanceStatus_State);
|
|
1305
|
+
const Devlab_MESSAGE_DESCRIPTOR = {
|
|
1306
|
+
fields: {
|
|
1307
|
+
"metadata": { pbName: "metadata", message: () => index_js_2.ResourceMetadata.$descriptor },
|
|
1308
|
+
"spec": { pbName: "spec", message: () => exports.DevlabSpec.$descriptor },
|
|
1309
|
+
"status": { pbName: "status", message: () => exports.DevlabStatus.$descriptor },
|
|
1310
|
+
},
|
|
1311
|
+
};
|
|
1312
|
+
/** Encodes, decodes, converts, and creates {@link Devlab} messages. */
|
|
1313
|
+
exports.Devlab = {
|
|
1314
|
+
$type: "nebius.ai.v1.Devlab",
|
|
1315
|
+
$descriptor: Devlab_MESSAGE_DESCRIPTOR,
|
|
1316
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
1317
|
+
if (message.metadata !== undefined) {
|
|
1318
|
+
const w = writer.uint32(10).fork();
|
|
1319
|
+
index_js_2.ResourceMetadata.encode(message.metadata, w);
|
|
1320
|
+
w.join();
|
|
1321
|
+
}
|
|
1322
|
+
if (message.spec !== undefined) {
|
|
1323
|
+
const w = writer.uint32(18).fork();
|
|
1324
|
+
exports.DevlabSpec.encode(message.spec, w);
|
|
1325
|
+
w.join();
|
|
1326
|
+
}
|
|
1327
|
+
if (message.status !== undefined) {
|
|
1328
|
+
const w = writer.uint32(26).fork();
|
|
1329
|
+
exports.DevlabStatus.encode(message.status, w);
|
|
1330
|
+
w.join();
|
|
1331
|
+
}
|
|
1332
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
1333
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
1334
|
+
}
|
|
1335
|
+
return writer;
|
|
1336
|
+
},
|
|
1337
|
+
decode(input, length) {
|
|
1338
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
1339
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1340
|
+
const message = createBaseDevlab();
|
|
1341
|
+
let writer = undefined;
|
|
1342
|
+
while (reader.pos < end) {
|
|
1343
|
+
const tag = reader.uint32();
|
|
1344
|
+
switch (tag >>> 3) {
|
|
1345
|
+
case 1: {
|
|
1346
|
+
if (tag !== 10)
|
|
1347
|
+
break;
|
|
1348
|
+
message.metadata = index_js_2.ResourceMetadata.decode(reader, reader.uint32());
|
|
1349
|
+
continue;
|
|
1350
|
+
}
|
|
1351
|
+
case 2: {
|
|
1352
|
+
if (tag !== 18)
|
|
1353
|
+
break;
|
|
1354
|
+
message.spec = exports.DevlabSpec.decode(reader, reader.uint32());
|
|
1355
|
+
continue;
|
|
1356
|
+
}
|
|
1357
|
+
case 3: {
|
|
1358
|
+
if (tag !== 26)
|
|
1359
|
+
break;
|
|
1360
|
+
message.status = exports.DevlabStatus.decode(reader, reader.uint32());
|
|
1361
|
+
continue;
|
|
1362
|
+
}
|
|
1363
|
+
default:
|
|
1364
|
+
break;
|
|
1365
|
+
}
|
|
1366
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1367
|
+
break;
|
|
1368
|
+
}
|
|
1369
|
+
{
|
|
1370
|
+
if (!writer)
|
|
1371
|
+
writer = new index_js_1.BinaryWriter();
|
|
1372
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
1373
|
+
writer.uint32(tag).raw(skipped);
|
|
1374
|
+
}
|
|
1375
|
+
}
|
|
1376
|
+
if (writer) {
|
|
1377
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
1378
|
+
}
|
|
1379
|
+
return message;
|
|
1380
|
+
},
|
|
1381
|
+
fromJSON(object) {
|
|
1382
|
+
return applyDevlabCustom({
|
|
1383
|
+
$type: "nebius.ai.v1.Devlab",
|
|
1384
|
+
metadata: (0, index_js_1.isSet)(object.metadata ?? object.metadata)
|
|
1385
|
+
? index_js_2.ResourceMetadata.fromJSON(object.metadata ?? object.metadata)
|
|
1386
|
+
: undefined,
|
|
1387
|
+
spec: (0, index_js_1.isSet)(object.spec ?? object.spec)
|
|
1388
|
+
? exports.DevlabSpec.fromJSON(object.spec ?? object.spec)
|
|
1389
|
+
: undefined,
|
|
1390
|
+
status: (0, index_js_1.isSet)(object.status ?? object.status)
|
|
1391
|
+
? exports.DevlabStatus.fromJSON(object.status ?? object.status)
|
|
1392
|
+
: undefined,
|
|
1393
|
+
});
|
|
1394
|
+
},
|
|
1395
|
+
toJSON(message, use = "json") {
|
|
1396
|
+
const obj = {};
|
|
1397
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
1398
|
+
if (message.metadata !== undefined) {
|
|
1399
|
+
obj[pick("metadata", "metadata")] = message.metadata
|
|
1400
|
+
? index_js_2.ResourceMetadata.toJSON(message.metadata, use)
|
|
1401
|
+
: undefined;
|
|
1402
|
+
}
|
|
1403
|
+
if (message.spec !== undefined) {
|
|
1404
|
+
obj[pick("spec", "spec")] = message.spec
|
|
1405
|
+
? exports.DevlabSpec.toJSON(message.spec, use)
|
|
1406
|
+
: undefined;
|
|
1407
|
+
}
|
|
1408
|
+
if (message.status !== undefined) {
|
|
1409
|
+
obj[pick("status", "status")] = message.status
|
|
1410
|
+
? exports.DevlabStatus.toJSON(message.status, use)
|
|
1411
|
+
: undefined;
|
|
1412
|
+
}
|
|
1413
|
+
return obj;
|
|
1414
|
+
},
|
|
1415
|
+
create(base) {
|
|
1416
|
+
return exports.Devlab.fromPartial(base ?? {});
|
|
1417
|
+
},
|
|
1418
|
+
fromPartial(object) {
|
|
1419
|
+
const message = createBaseDevlab();
|
|
1420
|
+
message.metadata = (object.metadata !== undefined && object.metadata !== null)
|
|
1421
|
+
? index_js_2.ResourceMetadata.fromPartial(object.metadata)
|
|
1422
|
+
: undefined;
|
|
1423
|
+
message.spec = (object.spec !== undefined && object.spec !== null)
|
|
1424
|
+
? exports.DevlabSpec.fromPartial(object.spec)
|
|
1425
|
+
: undefined;
|
|
1426
|
+
message.status = (object.status !== undefined && object.status !== null)
|
|
1427
|
+
? exports.DevlabStatus.fromPartial(object.status)
|
|
1428
|
+
: undefined;
|
|
1429
|
+
return message;
|
|
1430
|
+
},
|
|
1431
|
+
};
|
|
1432
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.Devlab);
|
|
1433
|
+
function DevlabCustomInspect() {
|
|
1434
|
+
const parts = [];
|
|
1435
|
+
if (this.metadata !== undefined)
|
|
1436
|
+
parts.push("metadata" + "=" + (0, util_1.inspect)(this.metadata));
|
|
1437
|
+
if (this.spec !== undefined)
|
|
1438
|
+
parts.push("spec" + "=" + (0, util_1.inspect)(this.spec));
|
|
1439
|
+
if (this.status !== undefined)
|
|
1440
|
+
parts.push("status" + "=" + (0, util_1.inspect)(this.status));
|
|
1441
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
1442
|
+
}
|
|
1443
|
+
function DevlabCustomJson() {
|
|
1444
|
+
const obj = {
|
|
1445
|
+
type: this.$type,
|
|
1446
|
+
};
|
|
1447
|
+
if (this.metadata !== undefined)
|
|
1448
|
+
obj.metadata = (0, logging_js_1.inspectJson)(this.metadata);
|
|
1449
|
+
if (this.spec !== undefined)
|
|
1450
|
+
obj.spec = (0, logging_js_1.inspectJson)(this.spec);
|
|
1451
|
+
if (this.status !== undefined)
|
|
1452
|
+
obj.status = (0, logging_js_1.inspectJson)(this.status);
|
|
1453
|
+
return obj;
|
|
1454
|
+
}
|
|
1455
|
+
function applyDevlabCustom(message) {
|
|
1456
|
+
message[logging_js_1.custom] = DevlabCustomInspect;
|
|
1457
|
+
message[logging_js_1.customJson] = DevlabCustomJson;
|
|
1458
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.Devlab.$descriptor);
|
|
1459
|
+
}
|
|
1460
|
+
function createBaseDevlab() {
|
|
1461
|
+
const message = {
|
|
1462
|
+
$type: "nebius.ai.v1.Devlab",
|
|
1463
|
+
metadata: undefined,
|
|
1464
|
+
spec: undefined,
|
|
1465
|
+
status: undefined,
|
|
1466
|
+
};
|
|
1467
|
+
return applyDevlabCustom(message);
|
|
1468
|
+
}
|
|
1469
|
+
const DevlabSpec_MESSAGE_DESCRIPTOR = {
|
|
1470
|
+
fields: {
|
|
1471
|
+
"image": { pbName: "image", immutable: true, scalarType: 9 },
|
|
1472
|
+
"environmentVariables": { pbName: "environment_variables", immutable: true, repeated: true, message: () => exports.DevlabSpec_EnvironmentVariable.$descriptor },
|
|
1473
|
+
"ports": { pbName: "ports", immutable: true, repeated: true, message: () => exports.DevlabSpec_Port.$descriptor },
|
|
1474
|
+
"containerCommand": { pbName: "container_command", immutable: true, scalarType: 9 },
|
|
1475
|
+
"args": { pbName: "args", immutable: true, scalarType: 9 },
|
|
1476
|
+
"workingDir": { pbName: "working_dir", immutable: true, scalarType: 9 },
|
|
1477
|
+
"volumes": { pbName: "volumes", immutable: true, repeated: true, message: () => exports.DevlabSpec_VolumeMount.$descriptor },
|
|
1478
|
+
"registryCredentials": { pbName: "registry_credentials", immutable: true, message: () => exports.DevlabSpec_RegistryCredentials.$descriptor },
|
|
1479
|
+
"platform": { pbName: "platform", immutable: true, scalarType: 9 },
|
|
1480
|
+
"preset": { pbName: "preset", immutable: true, scalarType: 9 },
|
|
1481
|
+
"shmSizeBytes": { pbName: "shm_size_bytes", immutable: true, scalarType: 3 },
|
|
1482
|
+
"disk": { pbName: "disk", immutable: true, message: () => exports.DevlabSpec_DiskSpec.$descriptor },
|
|
1483
|
+
"subnetId": { pbName: "subnet_id", immutable: true, scalarType: 9 },
|
|
1484
|
+
"publicIp": { pbName: "public_ip", immutable: true, scalarType: 8 },
|
|
1485
|
+
"sshAuthorizedKeys": { pbName: "ssh_authorized_keys", immutable: true, scalarType: 9, repeated: true },
|
|
1486
|
+
"workspace": { pbName: "workspace", immutable: true, message: () => exports.DevlabSpec_Workspace.$descriptor },
|
|
1487
|
+
"primaryRoute": { pbName: "primary_route", immutable: true, message: () => exports.DevlabSpec_PrimaryRoute.$descriptor },
|
|
1488
|
+
"template": { pbName: "template", immutable: true, message: () => exports.DevlabSpec_Template.$descriptor },
|
|
1489
|
+
"injectedFiles": { pbName: "injected_files", immutable: true, repeated: true, message: () => exports.DevlabSpec_FileInjection.$descriptor },
|
|
1490
|
+
"authTokenMysteryboxSecret": { pbName: "auth_token_mysterybox_secret", immutable: true, message: () => exports.DevlabSpec_MysteryBoxSecretRef.$descriptor },
|
|
1491
|
+
},
|
|
1492
|
+
};
|
|
1493
|
+
/** Encodes, decodes, converts, and creates {@link DevlabSpec} messages. */
|
|
1494
|
+
exports.DevlabSpec = {
|
|
1495
|
+
$type: "nebius.ai.v1.DevlabSpec",
|
|
1496
|
+
$descriptor: DevlabSpec_MESSAGE_DESCRIPTOR,
|
|
1497
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
1498
|
+
if (message.image !== "") {
|
|
1499
|
+
writer.uint32(10).string(message.image);
|
|
1500
|
+
}
|
|
1501
|
+
for (const v of (message.environmentVariables ?? [])) {
|
|
1502
|
+
const w = writer.uint32(18).fork();
|
|
1503
|
+
exports.DevlabSpec_EnvironmentVariable.encode(v, w);
|
|
1504
|
+
w.join();
|
|
1505
|
+
}
|
|
1506
|
+
for (const v of (message.ports ?? [])) {
|
|
1507
|
+
const w = writer.uint32(26).fork();
|
|
1508
|
+
exports.DevlabSpec_Port.encode(v, w);
|
|
1509
|
+
w.join();
|
|
1510
|
+
}
|
|
1511
|
+
if (message.containerCommand !== "") {
|
|
1512
|
+
writer.uint32(34).string(message.containerCommand);
|
|
1513
|
+
}
|
|
1514
|
+
if (message.args !== "") {
|
|
1515
|
+
writer.uint32(42).string(message.args);
|
|
1516
|
+
}
|
|
1517
|
+
if (message.workingDir !== "") {
|
|
1518
|
+
writer.uint32(50).string(message.workingDir);
|
|
1519
|
+
}
|
|
1520
|
+
for (const v of (message.volumes ?? [])) {
|
|
1521
|
+
const w = writer.uint32(58).fork();
|
|
1522
|
+
exports.DevlabSpec_VolumeMount.encode(v, w);
|
|
1523
|
+
w.join();
|
|
1524
|
+
}
|
|
1525
|
+
if (message.registryCredentials !== undefined) {
|
|
1526
|
+
const w = writer.uint32(82).fork();
|
|
1527
|
+
exports.DevlabSpec_RegistryCredentials.encode(message.registryCredentials, w);
|
|
1528
|
+
w.join();
|
|
1529
|
+
}
|
|
1530
|
+
if (message.platform !== "") {
|
|
1531
|
+
writer.uint32(162).string(message.platform);
|
|
1532
|
+
}
|
|
1533
|
+
if (message.preset !== "") {
|
|
1534
|
+
writer.uint32(170).string(message.preset);
|
|
1535
|
+
}
|
|
1536
|
+
if (message.shmSizeBytes !== undefined && !message.shmSizeBytes.isZero?.()) {
|
|
1537
|
+
writer.uint32(176).int64(message.shmSizeBytes.toString());
|
|
1538
|
+
}
|
|
1539
|
+
if (message.disk !== undefined) {
|
|
1540
|
+
const w = writer.uint32(186).fork();
|
|
1541
|
+
exports.DevlabSpec_DiskSpec.encode(message.disk, w);
|
|
1542
|
+
w.join();
|
|
1543
|
+
}
|
|
1544
|
+
if (message.subnetId !== "") {
|
|
1545
|
+
writer.uint32(194).string(message.subnetId);
|
|
1546
|
+
}
|
|
1547
|
+
if (message.publicIp === true) {
|
|
1548
|
+
writer.uint32(200).bool(message.publicIp);
|
|
1549
|
+
}
|
|
1550
|
+
for (const v of (message.sshAuthorizedKeys ?? [])) {
|
|
1551
|
+
writer.uint32(210).string(v);
|
|
1552
|
+
}
|
|
1553
|
+
if (message.workspace !== undefined) {
|
|
1554
|
+
const w = writer.uint32(242).fork();
|
|
1555
|
+
exports.DevlabSpec_Workspace.encode(message.workspace, w);
|
|
1556
|
+
w.join();
|
|
1557
|
+
}
|
|
1558
|
+
if (message.primaryRoute !== undefined) {
|
|
1559
|
+
const w = writer.uint32(250).fork();
|
|
1560
|
+
exports.DevlabSpec_PrimaryRoute.encode(message.primaryRoute, w);
|
|
1561
|
+
w.join();
|
|
1562
|
+
}
|
|
1563
|
+
if (message.template !== undefined) {
|
|
1564
|
+
const w = writer.uint32(258).fork();
|
|
1565
|
+
exports.DevlabSpec_Template.encode(message.template, w);
|
|
1566
|
+
w.join();
|
|
1567
|
+
}
|
|
1568
|
+
for (const v of (message.injectedFiles ?? [])) {
|
|
1569
|
+
const w = writer.uint32(266).fork();
|
|
1570
|
+
exports.DevlabSpec_FileInjection.encode(v, w);
|
|
1571
|
+
w.join();
|
|
1572
|
+
}
|
|
1573
|
+
if (message.authTokenMysteryboxSecret !== undefined) {
|
|
1574
|
+
const w = writer.uint32(274).fork();
|
|
1575
|
+
exports.DevlabSpec_MysteryBoxSecretRef.encode(message.authTokenMysteryboxSecret, w);
|
|
1576
|
+
w.join();
|
|
1577
|
+
}
|
|
1578
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
1579
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
1580
|
+
}
|
|
1581
|
+
return writer;
|
|
1582
|
+
},
|
|
1583
|
+
decode(input, length) {
|
|
1584
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
1585
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1586
|
+
const message = createBaseDevlabSpec();
|
|
1587
|
+
let writer = undefined;
|
|
1588
|
+
while (reader.pos < end) {
|
|
1589
|
+
const tag = reader.uint32();
|
|
1590
|
+
switch (tag >>> 3) {
|
|
1591
|
+
case 1: {
|
|
1592
|
+
if (tag !== 10)
|
|
1593
|
+
break;
|
|
1594
|
+
message.image = reader.string();
|
|
1595
|
+
continue;
|
|
1596
|
+
}
|
|
1597
|
+
case 2: {
|
|
1598
|
+
if (tag !== 18)
|
|
1599
|
+
break;
|
|
1600
|
+
message.environmentVariables.push(exports.DevlabSpec_EnvironmentVariable.decode(reader, reader.uint32()));
|
|
1601
|
+
continue;
|
|
1602
|
+
}
|
|
1603
|
+
case 3: {
|
|
1604
|
+
if (tag !== 26)
|
|
1605
|
+
break;
|
|
1606
|
+
message.ports.push(exports.DevlabSpec_Port.decode(reader, reader.uint32()));
|
|
1607
|
+
continue;
|
|
1608
|
+
}
|
|
1609
|
+
case 4: {
|
|
1610
|
+
if (tag !== 34)
|
|
1611
|
+
break;
|
|
1612
|
+
message.containerCommand = reader.string();
|
|
1613
|
+
continue;
|
|
1614
|
+
}
|
|
1615
|
+
case 5: {
|
|
1616
|
+
if (tag !== 42)
|
|
1617
|
+
break;
|
|
1618
|
+
message.args = reader.string();
|
|
1619
|
+
continue;
|
|
1620
|
+
}
|
|
1621
|
+
case 6: {
|
|
1622
|
+
if (tag !== 50)
|
|
1623
|
+
break;
|
|
1624
|
+
message.workingDir = reader.string();
|
|
1625
|
+
continue;
|
|
1626
|
+
}
|
|
1627
|
+
case 7: {
|
|
1628
|
+
if (tag !== 58)
|
|
1629
|
+
break;
|
|
1630
|
+
message.volumes.push(exports.DevlabSpec_VolumeMount.decode(reader, reader.uint32()));
|
|
1631
|
+
continue;
|
|
1632
|
+
}
|
|
1633
|
+
case 10: {
|
|
1634
|
+
if (tag !== 82)
|
|
1635
|
+
break;
|
|
1636
|
+
message.registryCredentials = exports.DevlabSpec_RegistryCredentials.decode(reader, reader.uint32());
|
|
1637
|
+
continue;
|
|
1638
|
+
}
|
|
1639
|
+
case 20: {
|
|
1640
|
+
if (tag !== 162)
|
|
1641
|
+
break;
|
|
1642
|
+
message.platform = reader.string();
|
|
1643
|
+
continue;
|
|
1644
|
+
}
|
|
1645
|
+
case 21: {
|
|
1646
|
+
if (tag !== 170)
|
|
1647
|
+
break;
|
|
1648
|
+
message.preset = reader.string();
|
|
1649
|
+
continue;
|
|
1650
|
+
}
|
|
1651
|
+
case 22: {
|
|
1652
|
+
if (tag !== 176)
|
|
1653
|
+
break;
|
|
1654
|
+
message.shmSizeBytes = index_js_1.Long.fromValue(reader.int64());
|
|
1655
|
+
continue;
|
|
1656
|
+
}
|
|
1657
|
+
case 23: {
|
|
1658
|
+
if (tag !== 186)
|
|
1659
|
+
break;
|
|
1660
|
+
message.disk = exports.DevlabSpec_DiskSpec.decode(reader, reader.uint32());
|
|
1661
|
+
continue;
|
|
1662
|
+
}
|
|
1663
|
+
case 24: {
|
|
1664
|
+
if (tag !== 194)
|
|
1665
|
+
break;
|
|
1666
|
+
message.subnetId = reader.string();
|
|
1667
|
+
continue;
|
|
1668
|
+
}
|
|
1669
|
+
case 25: {
|
|
1670
|
+
if (tag !== 200)
|
|
1671
|
+
break;
|
|
1672
|
+
message.publicIp = reader.bool();
|
|
1673
|
+
continue;
|
|
1674
|
+
}
|
|
1675
|
+
case 26: {
|
|
1676
|
+
if (tag !== 210)
|
|
1677
|
+
break;
|
|
1678
|
+
message.sshAuthorizedKeys.push(reader.string());
|
|
1679
|
+
continue;
|
|
1680
|
+
}
|
|
1681
|
+
case 30: {
|
|
1682
|
+
if (tag !== 242)
|
|
1683
|
+
break;
|
|
1684
|
+
message.workspace = exports.DevlabSpec_Workspace.decode(reader, reader.uint32());
|
|
1685
|
+
continue;
|
|
1686
|
+
}
|
|
1687
|
+
case 31: {
|
|
1688
|
+
if (tag !== 250)
|
|
1689
|
+
break;
|
|
1690
|
+
message.primaryRoute = exports.DevlabSpec_PrimaryRoute.decode(reader, reader.uint32());
|
|
1691
|
+
continue;
|
|
1692
|
+
}
|
|
1693
|
+
case 32: {
|
|
1694
|
+
if (tag !== 258)
|
|
1695
|
+
break;
|
|
1696
|
+
message.template = exports.DevlabSpec_Template.decode(reader, reader.uint32());
|
|
1697
|
+
continue;
|
|
1698
|
+
}
|
|
1699
|
+
case 33: {
|
|
1700
|
+
if (tag !== 266)
|
|
1701
|
+
break;
|
|
1702
|
+
message.injectedFiles.push(exports.DevlabSpec_FileInjection.decode(reader, reader.uint32()));
|
|
1703
|
+
continue;
|
|
1704
|
+
}
|
|
1705
|
+
case 34: {
|
|
1706
|
+
if (tag !== 274)
|
|
1707
|
+
break;
|
|
1708
|
+
message.authTokenMysteryboxSecret = exports.DevlabSpec_MysteryBoxSecretRef.decode(reader, reader.uint32());
|
|
1709
|
+
continue;
|
|
1710
|
+
}
|
|
1711
|
+
default:
|
|
1712
|
+
break;
|
|
1713
|
+
}
|
|
1714
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1715
|
+
break;
|
|
1716
|
+
}
|
|
1717
|
+
{
|
|
1718
|
+
if (!writer)
|
|
1719
|
+
writer = new index_js_1.BinaryWriter();
|
|
1720
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
1721
|
+
writer.uint32(tag).raw(skipped);
|
|
1722
|
+
}
|
|
1723
|
+
}
|
|
1724
|
+
if (writer) {
|
|
1725
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
1726
|
+
}
|
|
1727
|
+
return message;
|
|
1728
|
+
},
|
|
1729
|
+
fromJSON(object) {
|
|
1730
|
+
return applyDevlabSpecCustom({
|
|
1731
|
+
$type: "nebius.ai.v1.DevlabSpec",
|
|
1732
|
+
image: (0, index_js_1.isSet)(object.image ?? object.image)
|
|
1733
|
+
? String(object.image ?? object.image)
|
|
1734
|
+
: "",
|
|
1735
|
+
environmentVariables: globalThis.Array.isArray(object?.environmentVariables ?? object?.environment_variables)
|
|
1736
|
+
? (object.environmentVariables ?? object.environment_variables).map((e) => exports.DevlabSpec_EnvironmentVariable.fromJSON(e))
|
|
1737
|
+
: [],
|
|
1738
|
+
ports: globalThis.Array.isArray(object?.ports ?? object?.ports)
|
|
1739
|
+
? (object.ports ?? object.ports).map((e) => exports.DevlabSpec_Port.fromJSON(e))
|
|
1740
|
+
: [],
|
|
1741
|
+
containerCommand: (0, index_js_1.isSet)(object.containerCommand ?? object.container_command)
|
|
1742
|
+
? String(object.containerCommand ?? object.container_command)
|
|
1743
|
+
: "",
|
|
1744
|
+
args: (0, index_js_1.isSet)(object.args ?? object.args)
|
|
1745
|
+
? String(object.args ?? object.args)
|
|
1746
|
+
: "",
|
|
1747
|
+
workingDir: (0, index_js_1.isSet)(object.workingDir ?? object.working_dir)
|
|
1748
|
+
? String(object.workingDir ?? object.working_dir)
|
|
1749
|
+
: "",
|
|
1750
|
+
volumes: globalThis.Array.isArray(object?.volumes ?? object?.volumes)
|
|
1751
|
+
? (object.volumes ?? object.volumes).map((e) => exports.DevlabSpec_VolumeMount.fromJSON(e))
|
|
1752
|
+
: [],
|
|
1753
|
+
registryCredentials: (0, index_js_1.isSet)(object.registryCredentials ?? object.registry_credentials)
|
|
1754
|
+
? exports.DevlabSpec_RegistryCredentials.fromJSON(object.registryCredentials ?? object.registry_credentials)
|
|
1755
|
+
: undefined,
|
|
1756
|
+
platform: (0, index_js_1.isSet)(object.platform ?? object.platform)
|
|
1757
|
+
? String(object.platform ?? object.platform)
|
|
1758
|
+
: "",
|
|
1759
|
+
preset: (0, index_js_1.isSet)(object.preset ?? object.preset)
|
|
1760
|
+
? String(object.preset ?? object.preset)
|
|
1761
|
+
: "",
|
|
1762
|
+
shmSizeBytes: (0, index_js_1.isSet)(object.shmSizeBytes ?? object.shm_size_bytes)
|
|
1763
|
+
? index_js_1.Long.fromValue(object.shmSizeBytes ?? object.shm_size_bytes)
|
|
1764
|
+
: index_js_1.Long.ZERO,
|
|
1765
|
+
disk: (0, index_js_1.isSet)(object.disk ?? object.disk)
|
|
1766
|
+
? exports.DevlabSpec_DiskSpec.fromJSON(object.disk ?? object.disk)
|
|
1767
|
+
: undefined,
|
|
1768
|
+
subnetId: (0, index_js_1.isSet)(object.subnetId ?? object.subnet_id)
|
|
1769
|
+
? String(object.subnetId ?? object.subnet_id)
|
|
1770
|
+
: "",
|
|
1771
|
+
publicIp: (0, index_js_1.isSet)(object.publicIp ?? object.public_ip)
|
|
1772
|
+
? Boolean(object.publicIp ?? object.public_ip)
|
|
1773
|
+
: false,
|
|
1774
|
+
sshAuthorizedKeys: globalThis.Array.isArray(object?.sshAuthorizedKeys ?? object?.ssh_authorized_keys)
|
|
1775
|
+
? (object.sshAuthorizedKeys ?? object.ssh_authorized_keys).map((e) => String(e))
|
|
1776
|
+
: [],
|
|
1777
|
+
workspace: (0, index_js_1.isSet)(object.workspace ?? object.workspace)
|
|
1778
|
+
? exports.DevlabSpec_Workspace.fromJSON(object.workspace ?? object.workspace)
|
|
1779
|
+
: undefined,
|
|
1780
|
+
primaryRoute: (0, index_js_1.isSet)(object.primaryRoute ?? object.primary_route)
|
|
1781
|
+
? exports.DevlabSpec_PrimaryRoute.fromJSON(object.primaryRoute ?? object.primary_route)
|
|
1782
|
+
: undefined,
|
|
1783
|
+
template: (0, index_js_1.isSet)(object.template ?? object.template)
|
|
1784
|
+
? exports.DevlabSpec_Template.fromJSON(object.template ?? object.template)
|
|
1785
|
+
: undefined,
|
|
1786
|
+
injectedFiles: globalThis.Array.isArray(object?.injectedFiles ?? object?.injected_files)
|
|
1787
|
+
? (object.injectedFiles ?? object.injected_files).map((e) => exports.DevlabSpec_FileInjection.fromJSON(e))
|
|
1788
|
+
: [],
|
|
1789
|
+
authTokenMysteryboxSecret: (0, index_js_1.isSet)(object.authTokenMysteryboxSecret ?? object.auth_token_mysterybox_secret)
|
|
1790
|
+
? exports.DevlabSpec_MysteryBoxSecretRef.fromJSON(object.authTokenMysteryboxSecret ?? object.auth_token_mysterybox_secret)
|
|
1791
|
+
: undefined,
|
|
1792
|
+
});
|
|
1793
|
+
},
|
|
1794
|
+
toJSON(message, use = "json") {
|
|
1795
|
+
const obj = {};
|
|
1796
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
1797
|
+
if (message.image !== "") {
|
|
1798
|
+
obj[pick("image", "image")] = message.image;
|
|
1799
|
+
}
|
|
1800
|
+
if (message.environmentVariables?.length) {
|
|
1801
|
+
obj[pick("environmentVariables", "environment_variables")] = message.environmentVariables.map((e) => e ? exports.DevlabSpec_EnvironmentVariable.toJSON(e, use) : undefined);
|
|
1802
|
+
}
|
|
1803
|
+
if (message.ports?.length) {
|
|
1804
|
+
obj[pick("ports", "ports")] = message.ports.map((e) => e ? exports.DevlabSpec_Port.toJSON(e, use) : undefined);
|
|
1805
|
+
}
|
|
1806
|
+
if (message.containerCommand !== "") {
|
|
1807
|
+
obj[pick("containerCommand", "container_command")] = message.containerCommand;
|
|
1808
|
+
}
|
|
1809
|
+
if (message.args !== "") {
|
|
1810
|
+
obj[pick("args", "args")] = message.args;
|
|
1811
|
+
}
|
|
1812
|
+
if (message.workingDir !== "") {
|
|
1813
|
+
obj[pick("workingDir", "working_dir")] = message.workingDir;
|
|
1814
|
+
}
|
|
1815
|
+
if (message.volumes?.length) {
|
|
1816
|
+
obj[pick("volumes", "volumes")] = message.volumes.map((e) => e ? exports.DevlabSpec_VolumeMount.toJSON(e, use) : undefined);
|
|
1817
|
+
}
|
|
1818
|
+
if (message.registryCredentials !== undefined) {
|
|
1819
|
+
obj[pick("registryCredentials", "registry_credentials")] = message.registryCredentials
|
|
1820
|
+
? exports.DevlabSpec_RegistryCredentials.toJSON(message.registryCredentials, use)
|
|
1821
|
+
: undefined;
|
|
1822
|
+
}
|
|
1823
|
+
if (message.platform !== "") {
|
|
1824
|
+
obj[pick("platform", "platform")] = message.platform;
|
|
1825
|
+
}
|
|
1826
|
+
if (message.preset !== "") {
|
|
1827
|
+
obj[pick("preset", "preset")] = message.preset;
|
|
1828
|
+
}
|
|
1829
|
+
if (!message.shmSizeBytes?.isZero?.()) {
|
|
1830
|
+
obj[pick("shmSizeBytes", "shm_size_bytes")] = (message.shmSizeBytes || index_js_1.Long.ZERO).toString();
|
|
1831
|
+
}
|
|
1832
|
+
if (message.disk !== undefined) {
|
|
1833
|
+
obj[pick("disk", "disk")] = message.disk
|
|
1834
|
+
? exports.DevlabSpec_DiskSpec.toJSON(message.disk, use)
|
|
1835
|
+
: undefined;
|
|
1836
|
+
}
|
|
1837
|
+
if (message.subnetId !== "") {
|
|
1838
|
+
obj[pick("subnetId", "subnet_id")] = message.subnetId;
|
|
1839
|
+
}
|
|
1840
|
+
if (message.publicIp === true) {
|
|
1841
|
+
obj[pick("publicIp", "public_ip")] = message.publicIp;
|
|
1842
|
+
}
|
|
1843
|
+
if (message.sshAuthorizedKeys?.length) {
|
|
1844
|
+
obj[pick("sshAuthorizedKeys", "ssh_authorized_keys")] = message.sshAuthorizedKeys.map((e) => e);
|
|
1845
|
+
}
|
|
1846
|
+
if (message.workspace !== undefined) {
|
|
1847
|
+
obj[pick("workspace", "workspace")] = message.workspace
|
|
1848
|
+
? exports.DevlabSpec_Workspace.toJSON(message.workspace, use)
|
|
1849
|
+
: undefined;
|
|
1850
|
+
}
|
|
1851
|
+
if (message.primaryRoute !== undefined) {
|
|
1852
|
+
obj[pick("primaryRoute", "primary_route")] = message.primaryRoute
|
|
1853
|
+
? exports.DevlabSpec_PrimaryRoute.toJSON(message.primaryRoute, use)
|
|
1854
|
+
: undefined;
|
|
1855
|
+
}
|
|
1856
|
+
if (message.template !== undefined) {
|
|
1857
|
+
obj[pick("template", "template")] = message.template
|
|
1858
|
+
? exports.DevlabSpec_Template.toJSON(message.template, use)
|
|
1859
|
+
: undefined;
|
|
1860
|
+
}
|
|
1861
|
+
if (message.injectedFiles?.length) {
|
|
1862
|
+
obj[pick("injectedFiles", "injected_files")] = message.injectedFiles.map((e) => e ? exports.DevlabSpec_FileInjection.toJSON(e, use) : undefined);
|
|
1863
|
+
}
|
|
1864
|
+
if (message.authTokenMysteryboxSecret !== undefined) {
|
|
1865
|
+
obj[pick("authTokenMysteryboxSecret", "auth_token_mysterybox_secret")] = message.authTokenMysteryboxSecret
|
|
1866
|
+
? exports.DevlabSpec_MysteryBoxSecretRef.toJSON(message.authTokenMysteryboxSecret, use)
|
|
1867
|
+
: undefined;
|
|
1868
|
+
}
|
|
1869
|
+
return obj;
|
|
1870
|
+
},
|
|
1871
|
+
create(base) {
|
|
1872
|
+
return exports.DevlabSpec.fromPartial(base ?? {});
|
|
1873
|
+
},
|
|
1874
|
+
fromPartial(object) {
|
|
1875
|
+
const message = createBaseDevlabSpec();
|
|
1876
|
+
message.image = (object.image !== undefined && object.image !== null)
|
|
1877
|
+
? object.image
|
|
1878
|
+
: "";
|
|
1879
|
+
message.environmentVariables = object.environmentVariables?.map((e) => exports.DevlabSpec_EnvironmentVariable.fromPartial(e)) || [];
|
|
1880
|
+
message.ports = object.ports?.map((e) => exports.DevlabSpec_Port.fromPartial(e)) || [];
|
|
1881
|
+
message.containerCommand = (object.containerCommand !== undefined && object.containerCommand !== null)
|
|
1882
|
+
? object.containerCommand
|
|
1883
|
+
: "";
|
|
1884
|
+
message.args = (object.args !== undefined && object.args !== null)
|
|
1885
|
+
? object.args
|
|
1886
|
+
: "";
|
|
1887
|
+
message.workingDir = (object.workingDir !== undefined && object.workingDir !== null)
|
|
1888
|
+
? object.workingDir
|
|
1889
|
+
: "";
|
|
1890
|
+
message.volumes = object.volumes?.map((e) => exports.DevlabSpec_VolumeMount.fromPartial(e)) || [];
|
|
1891
|
+
message.registryCredentials = (object.registryCredentials !== undefined && object.registryCredentials !== null)
|
|
1892
|
+
? exports.DevlabSpec_RegistryCredentials.fromPartial(object.registryCredentials)
|
|
1893
|
+
: undefined;
|
|
1894
|
+
message.platform = (object.platform !== undefined && object.platform !== null)
|
|
1895
|
+
? object.platform
|
|
1896
|
+
: "";
|
|
1897
|
+
message.preset = (object.preset !== undefined && object.preset !== null)
|
|
1898
|
+
? object.preset
|
|
1899
|
+
: "";
|
|
1900
|
+
message.shmSizeBytes = (object.shmSizeBytes !== undefined && object.shmSizeBytes !== null)
|
|
1901
|
+
? index_js_1.Long.fromValue(object.shmSizeBytes)
|
|
1902
|
+
: index_js_1.Long.ZERO;
|
|
1903
|
+
message.disk = (object.disk !== undefined && object.disk !== null)
|
|
1904
|
+
? exports.DevlabSpec_DiskSpec.fromPartial(object.disk)
|
|
1905
|
+
: undefined;
|
|
1906
|
+
message.subnetId = (object.subnetId !== undefined && object.subnetId !== null)
|
|
1907
|
+
? object.subnetId
|
|
1908
|
+
: "";
|
|
1909
|
+
message.publicIp = (object.publicIp !== undefined && object.publicIp !== null)
|
|
1910
|
+
? object.publicIp
|
|
1911
|
+
: false;
|
|
1912
|
+
message.sshAuthorizedKeys = object.sshAuthorizedKeys?.map((e) => e) || [];
|
|
1913
|
+
message.workspace = (object.workspace !== undefined && object.workspace !== null)
|
|
1914
|
+
? exports.DevlabSpec_Workspace.fromPartial(object.workspace)
|
|
1915
|
+
: undefined;
|
|
1916
|
+
message.primaryRoute = (object.primaryRoute !== undefined && object.primaryRoute !== null)
|
|
1917
|
+
? exports.DevlabSpec_PrimaryRoute.fromPartial(object.primaryRoute)
|
|
1918
|
+
: undefined;
|
|
1919
|
+
message.template = (object.template !== undefined && object.template !== null)
|
|
1920
|
+
? exports.DevlabSpec_Template.fromPartial(object.template)
|
|
1921
|
+
: undefined;
|
|
1922
|
+
message.injectedFiles = object.injectedFiles?.map((e) => exports.DevlabSpec_FileInjection.fromPartial(e)) || [];
|
|
1923
|
+
message.authTokenMysteryboxSecret = (object.authTokenMysteryboxSecret !== undefined && object.authTokenMysteryboxSecret !== null)
|
|
1924
|
+
? exports.DevlabSpec_MysteryBoxSecretRef.fromPartial(object.authTokenMysteryboxSecret)
|
|
1925
|
+
: undefined;
|
|
1926
|
+
return message;
|
|
1927
|
+
},
|
|
1928
|
+
};
|
|
1929
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabSpec);
|
|
1930
|
+
function DevlabSpecCustomInspect() {
|
|
1931
|
+
const parts = [];
|
|
1932
|
+
if (this.image !== "")
|
|
1933
|
+
parts.push("image" + "=" + (0, util_1.inspect)(this.image));
|
|
1934
|
+
if ((this.environmentVariables?.length ?? 0) !== 0)
|
|
1935
|
+
parts.push("environmentVariables" + "=" + (0, util_1.inspect)(this.environmentVariables));
|
|
1936
|
+
if ((this.ports?.length ?? 0) !== 0)
|
|
1937
|
+
parts.push("ports" + "=" + (0, util_1.inspect)(this.ports));
|
|
1938
|
+
if (this.containerCommand !== "")
|
|
1939
|
+
parts.push("containerCommand" + "=" + (0, util_1.inspect)(this.containerCommand));
|
|
1940
|
+
if (this.args !== "")
|
|
1941
|
+
parts.push("args" + "=" + (0, util_1.inspect)(this.args));
|
|
1942
|
+
if (this.workingDir !== "")
|
|
1943
|
+
parts.push("workingDir" + "=" + (0, util_1.inspect)(this.workingDir));
|
|
1944
|
+
if ((this.volumes?.length ?? 0) !== 0)
|
|
1945
|
+
parts.push("volumes" + "=" + (0, util_1.inspect)(this.volumes));
|
|
1946
|
+
if (this.registryCredentials !== undefined)
|
|
1947
|
+
parts.push("registryCredentials" + "=" + (0, util_1.inspect)(this.registryCredentials));
|
|
1948
|
+
if (this.platform !== "")
|
|
1949
|
+
parts.push("platform" + "=" + (0, util_1.inspect)(this.platform));
|
|
1950
|
+
if (this.preset !== "")
|
|
1951
|
+
parts.push("preset" + "=" + (0, util_1.inspect)(this.preset));
|
|
1952
|
+
if (!this.shmSizeBytes?.isZero?.())
|
|
1953
|
+
parts.push("shmSizeBytes" + "=" + (0, util_1.inspect)(this.shmSizeBytes));
|
|
1954
|
+
if (this.disk !== undefined)
|
|
1955
|
+
parts.push("disk" + "=" + (0, util_1.inspect)(this.disk));
|
|
1956
|
+
if (this.subnetId !== "")
|
|
1957
|
+
parts.push("subnetId" + "=" + (0, util_1.inspect)(this.subnetId));
|
|
1958
|
+
if (this.publicIp === true)
|
|
1959
|
+
parts.push("publicIp" + "=" + (0, util_1.inspect)(this.publicIp));
|
|
1960
|
+
if ((this.sshAuthorizedKeys?.length ?? 0) !== 0)
|
|
1961
|
+
parts.push("sshAuthorizedKeys" + "=" + (0, util_1.inspect)(this.sshAuthorizedKeys));
|
|
1962
|
+
if (this.workspace !== undefined)
|
|
1963
|
+
parts.push("workspace" + "=" + (0, util_1.inspect)(this.workspace));
|
|
1964
|
+
if (this.primaryRoute !== undefined)
|
|
1965
|
+
parts.push("primaryRoute" + "=" + (0, util_1.inspect)(this.primaryRoute));
|
|
1966
|
+
if (this.template !== undefined)
|
|
1967
|
+
parts.push("template" + "=" + (0, util_1.inspect)(this.template));
|
|
1968
|
+
if ((this.injectedFiles?.length ?? 0) !== 0)
|
|
1969
|
+
parts.push("injectedFiles" + "=" + (0, util_1.inspect)(this.injectedFiles));
|
|
1970
|
+
if (this.authTokenMysteryboxSecret !== undefined)
|
|
1971
|
+
parts.push("authTokenMysteryboxSecret" + "=" + (0, util_1.inspect)(this.authTokenMysteryboxSecret));
|
|
1972
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
1973
|
+
}
|
|
1974
|
+
function DevlabSpecCustomJson() {
|
|
1975
|
+
const obj = {
|
|
1976
|
+
type: this.$type,
|
|
1977
|
+
};
|
|
1978
|
+
if (this.image !== "")
|
|
1979
|
+
obj.image = (0, logging_js_1.inspectJson)(this.image);
|
|
1980
|
+
if ((this.environmentVariables?.length ?? 0) !== 0)
|
|
1981
|
+
obj.environmentVariables = (0, logging_js_1.inspectJson)(this.environmentVariables);
|
|
1982
|
+
if ((this.ports?.length ?? 0) !== 0)
|
|
1983
|
+
obj.ports = (0, logging_js_1.inspectJson)(this.ports);
|
|
1984
|
+
if (this.containerCommand !== "")
|
|
1985
|
+
obj.containerCommand = (0, logging_js_1.inspectJson)(this.containerCommand);
|
|
1986
|
+
if (this.args !== "")
|
|
1987
|
+
obj.args = (0, logging_js_1.inspectJson)(this.args);
|
|
1988
|
+
if (this.workingDir !== "")
|
|
1989
|
+
obj.workingDir = (0, logging_js_1.inspectJson)(this.workingDir);
|
|
1990
|
+
if ((this.volumes?.length ?? 0) !== 0)
|
|
1991
|
+
obj.volumes = (0, logging_js_1.inspectJson)(this.volumes);
|
|
1992
|
+
if (this.registryCredentials !== undefined)
|
|
1993
|
+
obj.registryCredentials = (0, logging_js_1.inspectJson)(this.registryCredentials);
|
|
1994
|
+
if (this.platform !== "")
|
|
1995
|
+
obj.platform = (0, logging_js_1.inspectJson)(this.platform);
|
|
1996
|
+
if (this.preset !== "")
|
|
1997
|
+
obj.preset = (0, logging_js_1.inspectJson)(this.preset);
|
|
1998
|
+
if (!this.shmSizeBytes?.isZero?.())
|
|
1999
|
+
obj.shmSizeBytes = (0, logging_js_1.inspectJson)(this.shmSizeBytes);
|
|
2000
|
+
if (this.disk !== undefined)
|
|
2001
|
+
obj.disk = (0, logging_js_1.inspectJson)(this.disk);
|
|
2002
|
+
if (this.subnetId !== "")
|
|
2003
|
+
obj.subnetId = (0, logging_js_1.inspectJson)(this.subnetId);
|
|
2004
|
+
if (this.publicIp === true)
|
|
2005
|
+
obj.publicIp = (0, logging_js_1.inspectJson)(this.publicIp);
|
|
2006
|
+
if ((this.sshAuthorizedKeys?.length ?? 0) !== 0)
|
|
2007
|
+
obj.sshAuthorizedKeys = (0, logging_js_1.inspectJson)(this.sshAuthorizedKeys);
|
|
2008
|
+
if (this.workspace !== undefined)
|
|
2009
|
+
obj.workspace = (0, logging_js_1.inspectJson)(this.workspace);
|
|
2010
|
+
if (this.primaryRoute !== undefined)
|
|
2011
|
+
obj.primaryRoute = (0, logging_js_1.inspectJson)(this.primaryRoute);
|
|
2012
|
+
if (this.template !== undefined)
|
|
2013
|
+
obj.template = (0, logging_js_1.inspectJson)(this.template);
|
|
2014
|
+
if ((this.injectedFiles?.length ?? 0) !== 0)
|
|
2015
|
+
obj.injectedFiles = (0, logging_js_1.inspectJson)(this.injectedFiles);
|
|
2016
|
+
if (this.authTokenMysteryboxSecret !== undefined)
|
|
2017
|
+
obj.authTokenMysteryboxSecret = (0, logging_js_1.inspectJson)(this.authTokenMysteryboxSecret);
|
|
2018
|
+
return obj;
|
|
2019
|
+
}
|
|
2020
|
+
function applyDevlabSpecCustom(message) {
|
|
2021
|
+
message[logging_js_1.custom] = DevlabSpecCustomInspect;
|
|
2022
|
+
message[logging_js_1.customJson] = DevlabSpecCustomJson;
|
|
2023
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabSpec.$descriptor);
|
|
2024
|
+
}
|
|
2025
|
+
function createBaseDevlabSpec() {
|
|
2026
|
+
const message = {
|
|
2027
|
+
$type: "nebius.ai.v1.DevlabSpec",
|
|
2028
|
+
image: "",
|
|
2029
|
+
environmentVariables: [],
|
|
2030
|
+
ports: [],
|
|
2031
|
+
containerCommand: "",
|
|
2032
|
+
args: "",
|
|
2033
|
+
workingDir: "",
|
|
2034
|
+
volumes: [],
|
|
2035
|
+
registryCredentials: undefined,
|
|
2036
|
+
platform: "",
|
|
2037
|
+
preset: "",
|
|
2038
|
+
shmSizeBytes: index_js_1.Long.ZERO,
|
|
2039
|
+
disk: undefined,
|
|
2040
|
+
subnetId: "",
|
|
2041
|
+
publicIp: false,
|
|
2042
|
+
sshAuthorizedKeys: [],
|
|
2043
|
+
workspace: undefined,
|
|
2044
|
+
primaryRoute: undefined,
|
|
2045
|
+
template: undefined,
|
|
2046
|
+
injectedFiles: [],
|
|
2047
|
+
authTokenMysteryboxSecret: undefined,
|
|
2048
|
+
};
|
|
2049
|
+
return applyDevlabSpecCustom(message);
|
|
2050
|
+
}
|
|
2051
|
+
const DevlabSpec_EnvironmentVariable_valueSource_ONEOF_DESCRIPTOR = {
|
|
2052
|
+
fields: {
|
|
2053
|
+
"value": { pbName: "value", scalarType: 9 },
|
|
2054
|
+
"mysteryboxSecret": { pbName: "mysterybox_secret", message: () => exports.DevlabSpec_MysteryBoxSecretRef.$descriptor },
|
|
2055
|
+
},
|
|
2056
|
+
};
|
|
2057
|
+
const DevlabSpec_EnvironmentVariable_MESSAGE_DESCRIPTOR = {
|
|
2058
|
+
fields: {
|
|
2059
|
+
"name": { pbName: "name", scalarType: 9 },
|
|
2060
|
+
"valueSource": { pbName: "value_source", oneof: true, message: () => DevlabSpec_EnvironmentVariable_valueSource_ONEOF_DESCRIPTOR },
|
|
2061
|
+
},
|
|
2062
|
+
};
|
|
2063
|
+
/** Encodes, decodes, converts, and creates {@link DevlabSpec_EnvironmentVariable} messages. */
|
|
2064
|
+
exports.DevlabSpec_EnvironmentVariable = {
|
|
2065
|
+
$type: "nebius.ai.v1.DevlabSpec.EnvironmentVariable",
|
|
2066
|
+
$descriptor: DevlabSpec_EnvironmentVariable_MESSAGE_DESCRIPTOR,
|
|
2067
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
2068
|
+
if (message.name !== "") {
|
|
2069
|
+
writer.uint32(10).string(message.name);
|
|
2070
|
+
}
|
|
2071
|
+
if (message.valueSource?.$case === undefined) { /* noop */ }
|
|
2072
|
+
else if (message.valueSource?.$case === "value") {
|
|
2073
|
+
writer.uint32(18).string(message.valueSource.value);
|
|
2074
|
+
}
|
|
2075
|
+
else if (message.valueSource?.$case === "mysteryboxSecret") {
|
|
2076
|
+
const w = writer.uint32(26).fork();
|
|
2077
|
+
exports.DevlabSpec_MysteryBoxSecretRef.encode(message.valueSource.mysteryboxSecret, w);
|
|
2078
|
+
w.join();
|
|
2079
|
+
}
|
|
2080
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
2081
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
2082
|
+
}
|
|
2083
|
+
return writer;
|
|
2084
|
+
},
|
|
2085
|
+
decode(input, length) {
|
|
2086
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
2087
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
2088
|
+
const message = createBaseDevlabSpec_EnvironmentVariable();
|
|
2089
|
+
let writer = undefined;
|
|
2090
|
+
while (reader.pos < end) {
|
|
2091
|
+
const tag = reader.uint32();
|
|
2092
|
+
switch (tag >>> 3) {
|
|
2093
|
+
case 1: {
|
|
2094
|
+
if (tag !== 10)
|
|
2095
|
+
break;
|
|
2096
|
+
message.name = reader.string();
|
|
2097
|
+
continue;
|
|
2098
|
+
}
|
|
2099
|
+
case 2: {
|
|
2100
|
+
if (tag !== 18)
|
|
2101
|
+
break;
|
|
2102
|
+
message.valueSource = {
|
|
2103
|
+
$case: "value",
|
|
2104
|
+
value: reader.string()
|
|
2105
|
+
};
|
|
2106
|
+
continue;
|
|
2107
|
+
}
|
|
2108
|
+
case 3: {
|
|
2109
|
+
if (tag !== 26)
|
|
2110
|
+
break;
|
|
2111
|
+
message.valueSource = {
|
|
2112
|
+
$case: "mysteryboxSecret",
|
|
2113
|
+
mysteryboxSecret: exports.DevlabSpec_MysteryBoxSecretRef.decode(reader, reader.uint32())
|
|
2114
|
+
};
|
|
2115
|
+
continue;
|
|
2116
|
+
}
|
|
2117
|
+
default:
|
|
2118
|
+
break;
|
|
2119
|
+
}
|
|
2120
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
2121
|
+
break;
|
|
2122
|
+
}
|
|
2123
|
+
{
|
|
2124
|
+
if (!writer)
|
|
2125
|
+
writer = new index_js_1.BinaryWriter();
|
|
2126
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
2127
|
+
writer.uint32(tag).raw(skipped);
|
|
2128
|
+
}
|
|
2129
|
+
}
|
|
2130
|
+
if (writer) {
|
|
2131
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
2132
|
+
}
|
|
2133
|
+
return message;
|
|
2134
|
+
},
|
|
2135
|
+
fromJSON(object) {
|
|
2136
|
+
return applyDevlabSpec_EnvironmentVariableCustom({
|
|
2137
|
+
$type: "nebius.ai.v1.DevlabSpec.EnvironmentVariable",
|
|
2138
|
+
name: (0, index_js_1.isSet)(object.name ?? object.name)
|
|
2139
|
+
? String(object.name ?? object.name)
|
|
2140
|
+
: "",
|
|
2141
|
+
valueSource: (() => {
|
|
2142
|
+
if ((0, index_js_1.isSet)(object.value) || (0, index_js_1.isSet)(object.value)) {
|
|
2143
|
+
return {
|
|
2144
|
+
$case: "value",
|
|
2145
|
+
value: String(object.value ?? object.value)
|
|
2146
|
+
};
|
|
2147
|
+
}
|
|
2148
|
+
if ((0, index_js_1.isSet)(object.mysteryboxSecret) || (0, index_js_1.isSet)(object.mysterybox_secret)) {
|
|
2149
|
+
return {
|
|
2150
|
+
$case: "mysteryboxSecret",
|
|
2151
|
+
mysteryboxSecret: exports.DevlabSpec_MysteryBoxSecretRef.fromJSON(object.mysteryboxSecret ?? object.mysterybox_secret)
|
|
2152
|
+
};
|
|
2153
|
+
}
|
|
2154
|
+
return undefined;
|
|
2155
|
+
})(),
|
|
2156
|
+
});
|
|
2157
|
+
},
|
|
2158
|
+
toJSON(message, use = "json") {
|
|
2159
|
+
const obj = {};
|
|
2160
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
2161
|
+
if (message.name !== "") {
|
|
2162
|
+
obj[pick("name", "name")] = message.name;
|
|
2163
|
+
}
|
|
2164
|
+
switch (message.valueSource?.$case) {
|
|
2165
|
+
case "value": {
|
|
2166
|
+
obj[pick("value", "value")] = message.valueSource.value;
|
|
2167
|
+
break;
|
|
2168
|
+
}
|
|
2169
|
+
case "mysteryboxSecret": {
|
|
2170
|
+
obj[pick("mysteryboxSecret", "mysterybox_secret")] = exports.DevlabSpec_MysteryBoxSecretRef.toJSON(message.valueSource.mysteryboxSecret, use);
|
|
2171
|
+
break;
|
|
2172
|
+
}
|
|
2173
|
+
default: break;
|
|
2174
|
+
}
|
|
2175
|
+
return obj;
|
|
2176
|
+
},
|
|
2177
|
+
create(base) {
|
|
2178
|
+
return exports.DevlabSpec_EnvironmentVariable.fromPartial(base ?? {});
|
|
2179
|
+
},
|
|
2180
|
+
fromPartial(object) {
|
|
2181
|
+
const message = createBaseDevlabSpec_EnvironmentVariable();
|
|
2182
|
+
message.name = (object.name !== undefined && object.name !== null)
|
|
2183
|
+
? object.name
|
|
2184
|
+
: "";
|
|
2185
|
+
switch (object.valueSource?.$case) {
|
|
2186
|
+
case "value": {
|
|
2187
|
+
if (object.valueSource?.value !== undefined && object.valueSource?.value !== null) {
|
|
2188
|
+
message.valueSource = {
|
|
2189
|
+
$case: "value",
|
|
2190
|
+
value: object.valueSource.value,
|
|
2191
|
+
};
|
|
2192
|
+
}
|
|
2193
|
+
break;
|
|
2194
|
+
}
|
|
2195
|
+
case "mysteryboxSecret": {
|
|
2196
|
+
if (object.valueSource.mysteryboxSecret !== undefined && object.valueSource.mysteryboxSecret !== null) {
|
|
2197
|
+
message.valueSource = {
|
|
2198
|
+
$case: "mysteryboxSecret",
|
|
2199
|
+
mysteryboxSecret: exports.DevlabSpec_MysteryBoxSecretRef.fromPartial(object.valueSource.mysteryboxSecret),
|
|
2200
|
+
};
|
|
2201
|
+
}
|
|
2202
|
+
break;
|
|
2203
|
+
}
|
|
2204
|
+
default: break;
|
|
2205
|
+
}
|
|
2206
|
+
return message;
|
|
2207
|
+
},
|
|
2208
|
+
};
|
|
2209
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabSpec_EnvironmentVariable);
|
|
2210
|
+
function DevlabSpec_EnvironmentVariableCustomInspect() {
|
|
2211
|
+
const parts = [];
|
|
2212
|
+
if (this.name !== "")
|
|
2213
|
+
parts.push("name" + "=" + (0, util_1.inspect)(this.name));
|
|
2214
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
2215
|
+
}
|
|
2216
|
+
function DevlabSpec_EnvironmentVariableCustomJson() {
|
|
2217
|
+
const obj = {
|
|
2218
|
+
type: this.$type,
|
|
2219
|
+
};
|
|
2220
|
+
if (this.name !== "")
|
|
2221
|
+
obj.name = (0, logging_js_1.inspectJson)(this.name);
|
|
2222
|
+
return obj;
|
|
2223
|
+
}
|
|
2224
|
+
function applyDevlabSpec_EnvironmentVariableCustom(message) {
|
|
2225
|
+
message[logging_js_1.custom] = DevlabSpec_EnvironmentVariableCustomInspect;
|
|
2226
|
+
message[logging_js_1.customJson] = DevlabSpec_EnvironmentVariableCustomJson;
|
|
2227
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabSpec_EnvironmentVariable.$descriptor);
|
|
2228
|
+
}
|
|
2229
|
+
function createBaseDevlabSpec_EnvironmentVariable() {
|
|
2230
|
+
const message = {
|
|
2231
|
+
$type: "nebius.ai.v1.DevlabSpec.EnvironmentVariable",
|
|
2232
|
+
name: "",
|
|
2233
|
+
valueSource: undefined,
|
|
2234
|
+
};
|
|
2235
|
+
return applyDevlabSpec_EnvironmentVariableCustom(message);
|
|
2236
|
+
}
|
|
2237
|
+
const DevlabSpec_Port_MESSAGE_DESCRIPTOR = {
|
|
2238
|
+
fields: {
|
|
2239
|
+
"containerPort": { pbName: "container_port", scalarType: 5 },
|
|
2240
|
+
"hostPort": { pbName: "host_port", scalarType: 5 },
|
|
2241
|
+
"protocol": { pbName: "protocol", scalarType: 14 },
|
|
2242
|
+
},
|
|
2243
|
+
};
|
|
2244
|
+
/** Encodes, decodes, converts, and creates {@link DevlabSpec_Port} messages. */
|
|
2245
|
+
exports.DevlabSpec_Port = {
|
|
2246
|
+
$type: "nebius.ai.v1.DevlabSpec.Port",
|
|
2247
|
+
$descriptor: DevlabSpec_Port_MESSAGE_DESCRIPTOR,
|
|
2248
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
2249
|
+
if ((message.containerPort ?? 0) !== 0) {
|
|
2250
|
+
writer.uint32(8).int32(message.containerPort);
|
|
2251
|
+
}
|
|
2252
|
+
if ((message.hostPort ?? 0) !== 0) {
|
|
2253
|
+
writer.uint32(16).int32(message.hostPort);
|
|
2254
|
+
}
|
|
2255
|
+
if ((message.protocol ?? exports.DevlabSpec_Port_Protocol.PROTOCOL_UNSPECIFIED) !== exports.DevlabSpec_Port_Protocol.PROTOCOL_UNSPECIFIED) {
|
|
2256
|
+
exports.DevlabSpec_Port_Protocol.encodeField(writer, 3, message.protocol);
|
|
2257
|
+
}
|
|
2258
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
2259
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
2260
|
+
}
|
|
2261
|
+
return writer;
|
|
2262
|
+
},
|
|
2263
|
+
decode(input, length) {
|
|
2264
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
2265
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
2266
|
+
const message = createBaseDevlabSpec_Port();
|
|
2267
|
+
let writer = undefined;
|
|
2268
|
+
while (reader.pos < end) {
|
|
2269
|
+
const tag = reader.uint32();
|
|
2270
|
+
switch (tag >>> 3) {
|
|
2271
|
+
case 1: {
|
|
2272
|
+
if (tag !== 8)
|
|
2273
|
+
break;
|
|
2274
|
+
message.containerPort = reader.int32();
|
|
2275
|
+
continue;
|
|
2276
|
+
}
|
|
2277
|
+
case 2: {
|
|
2278
|
+
if (tag !== 16)
|
|
2279
|
+
break;
|
|
2280
|
+
message.hostPort = reader.int32();
|
|
2281
|
+
continue;
|
|
2282
|
+
}
|
|
2283
|
+
case 3: {
|
|
2284
|
+
if (tag !== 24)
|
|
2285
|
+
break;
|
|
2286
|
+
message.protocol = exports.DevlabSpec_Port_Protocol.fromNumber(reader.int32());
|
|
2287
|
+
continue;
|
|
2288
|
+
}
|
|
2289
|
+
default:
|
|
2290
|
+
break;
|
|
2291
|
+
}
|
|
2292
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
2293
|
+
break;
|
|
2294
|
+
}
|
|
2295
|
+
{
|
|
2296
|
+
if (!writer)
|
|
2297
|
+
writer = new index_js_1.BinaryWriter();
|
|
2298
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
2299
|
+
writer.uint32(tag).raw(skipped);
|
|
2300
|
+
}
|
|
2301
|
+
}
|
|
2302
|
+
if (writer) {
|
|
2303
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
2304
|
+
}
|
|
2305
|
+
return message;
|
|
2306
|
+
},
|
|
2307
|
+
fromJSON(object) {
|
|
2308
|
+
return applyDevlabSpec_PortCustom({
|
|
2309
|
+
$type: "nebius.ai.v1.DevlabSpec.Port",
|
|
2310
|
+
containerPort: (0, index_js_1.isSet)(object.containerPort ?? object.container_port)
|
|
2311
|
+
? Number(object.containerPort ?? object.container_port)
|
|
2312
|
+
: 0,
|
|
2313
|
+
hostPort: (0, index_js_1.isSet)(object.hostPort ?? object.host_port)
|
|
2314
|
+
? Number(object.hostPort ?? object.host_port)
|
|
2315
|
+
: 0,
|
|
2316
|
+
protocol: (0, index_js_1.isSet)(object.protocol ?? object.protocol)
|
|
2317
|
+
? exports.DevlabSpec_Port_Protocol.fromJSON(object.protocol ?? object.protocol)
|
|
2318
|
+
: exports.DevlabSpec_Port_Protocol.PROTOCOL_UNSPECIFIED,
|
|
2319
|
+
});
|
|
2320
|
+
},
|
|
2321
|
+
toJSON(message, use = "json") {
|
|
2322
|
+
const obj = {};
|
|
2323
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
2324
|
+
if ((message.containerPort ?? 0) !== 0) {
|
|
2325
|
+
obj[pick("containerPort", "container_port")] = message.containerPort;
|
|
2326
|
+
}
|
|
2327
|
+
if ((message.hostPort ?? 0) !== 0) {
|
|
2328
|
+
obj[pick("hostPort", "host_port")] = message.hostPort;
|
|
2329
|
+
}
|
|
2330
|
+
if ((message.protocol ?? exports.DevlabSpec_Port_Protocol.PROTOCOL_UNSPECIFIED) !== exports.DevlabSpec_Port_Protocol.PROTOCOL_UNSPECIFIED) {
|
|
2331
|
+
obj[pick("protocol", "protocol")] = exports.DevlabSpec_Port_Protocol.toJSON(message.protocol);
|
|
2332
|
+
}
|
|
2333
|
+
return obj;
|
|
2334
|
+
},
|
|
2335
|
+
create(base) {
|
|
2336
|
+
return exports.DevlabSpec_Port.fromPartial(base ?? {});
|
|
2337
|
+
},
|
|
2338
|
+
fromPartial(object) {
|
|
2339
|
+
const message = createBaseDevlabSpec_Port();
|
|
2340
|
+
message.containerPort = (object.containerPort !== undefined && object.containerPort !== null)
|
|
2341
|
+
? object.containerPort
|
|
2342
|
+
: 0;
|
|
2343
|
+
message.hostPort = (object.hostPort !== undefined && object.hostPort !== null)
|
|
2344
|
+
? object.hostPort
|
|
2345
|
+
: 0;
|
|
2346
|
+
message.protocol = (object.protocol !== undefined && object.protocol !== null)
|
|
2347
|
+
? exports.DevlabSpec_Port_Protocol.fromJSON(object.protocol.name)
|
|
2348
|
+
: exports.DevlabSpec_Port_Protocol.PROTOCOL_UNSPECIFIED;
|
|
2349
|
+
return message;
|
|
2350
|
+
},
|
|
2351
|
+
};
|
|
2352
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabSpec_Port);
|
|
2353
|
+
function DevlabSpec_PortCustomInspect() {
|
|
2354
|
+
const parts = [];
|
|
2355
|
+
if ((this.containerPort ?? 0) !== 0)
|
|
2356
|
+
parts.push("containerPort" + "=" + (0, util_1.inspect)(this.containerPort));
|
|
2357
|
+
if ((this.hostPort ?? 0) !== 0)
|
|
2358
|
+
parts.push("hostPort" + "=" + (0, util_1.inspect)(this.hostPort));
|
|
2359
|
+
if (this.protocol !== undefined)
|
|
2360
|
+
parts.push("protocol" + "=" + (0, util_1.inspect)(this.protocol));
|
|
2361
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
2362
|
+
}
|
|
2363
|
+
function DevlabSpec_PortCustomJson() {
|
|
2364
|
+
const obj = {
|
|
2365
|
+
type: this.$type,
|
|
2366
|
+
};
|
|
2367
|
+
if ((this.containerPort ?? 0) !== 0)
|
|
2368
|
+
obj.containerPort = (0, logging_js_1.inspectJson)(this.containerPort);
|
|
2369
|
+
if ((this.hostPort ?? 0) !== 0)
|
|
2370
|
+
obj.hostPort = (0, logging_js_1.inspectJson)(this.hostPort);
|
|
2371
|
+
if (this.protocol !== undefined)
|
|
2372
|
+
obj.protocol = (0, logging_js_1.inspectJson)(this.protocol);
|
|
2373
|
+
return obj;
|
|
2374
|
+
}
|
|
2375
|
+
function applyDevlabSpec_PortCustom(message) {
|
|
2376
|
+
message[logging_js_1.custom] = DevlabSpec_PortCustomInspect;
|
|
2377
|
+
message[logging_js_1.customJson] = DevlabSpec_PortCustomJson;
|
|
2378
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabSpec_Port.$descriptor);
|
|
2379
|
+
}
|
|
2380
|
+
function createBaseDevlabSpec_Port() {
|
|
2381
|
+
const message = {
|
|
2382
|
+
$type: "nebius.ai.v1.DevlabSpec.Port",
|
|
2383
|
+
containerPort: 0,
|
|
2384
|
+
hostPort: 0,
|
|
2385
|
+
protocol: exports.DevlabSpec_Port_Protocol.PROTOCOL_UNSPECIFIED,
|
|
2386
|
+
};
|
|
2387
|
+
return applyDevlabSpec_PortCustom(message);
|
|
2388
|
+
}
|
|
2389
|
+
const DevlabSpec_VolumeMount_sourceConfig_ONEOF_DESCRIPTOR = {
|
|
2390
|
+
fields: {
|
|
2391
|
+
"s3Config": { pbName: "s3_config", message: () => exports.DevlabSpec_VolumeMount_S3Config.$descriptor },
|
|
2392
|
+
},
|
|
2393
|
+
};
|
|
2394
|
+
const DevlabSpec_VolumeMount_MESSAGE_DESCRIPTOR = {
|
|
2395
|
+
fields: {
|
|
2396
|
+
"source": { pbName: "source", scalarType: 9 },
|
|
2397
|
+
"sourcePath": { pbName: "source_path", scalarType: 9 },
|
|
2398
|
+
"containerPath": { pbName: "container_path", scalarType: 9 },
|
|
2399
|
+
"mode": { pbName: "mode", scalarType: 14 },
|
|
2400
|
+
"sourceConfig": { pbName: "source_config", oneof: true, message: () => DevlabSpec_VolumeMount_sourceConfig_ONEOF_DESCRIPTOR },
|
|
2401
|
+
},
|
|
2402
|
+
};
|
|
2403
|
+
/** Encodes, decodes, converts, and creates {@link DevlabSpec_VolumeMount} messages. */
|
|
2404
|
+
exports.DevlabSpec_VolumeMount = {
|
|
2405
|
+
$type: "nebius.ai.v1.DevlabSpec.VolumeMount",
|
|
2406
|
+
$descriptor: DevlabSpec_VolumeMount_MESSAGE_DESCRIPTOR,
|
|
2407
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
2408
|
+
if (message.source !== "") {
|
|
2409
|
+
writer.uint32(10).string(message.source);
|
|
2410
|
+
}
|
|
2411
|
+
if (message.sourcePath !== "") {
|
|
2412
|
+
writer.uint32(18).string(message.sourcePath);
|
|
2413
|
+
}
|
|
2414
|
+
if (message.containerPath !== "") {
|
|
2415
|
+
writer.uint32(26).string(message.containerPath);
|
|
2416
|
+
}
|
|
2417
|
+
if ((message.mode ?? exports.DevlabSpec_VolumeMount_Mode.MODE_UNSPECIFIED) !== exports.DevlabSpec_VolumeMount_Mode.MODE_UNSPECIFIED) {
|
|
2418
|
+
exports.DevlabSpec_VolumeMount_Mode.encodeField(writer, 4, message.mode);
|
|
2419
|
+
}
|
|
2420
|
+
if (message.sourceConfig?.$case === undefined) { /* noop */ }
|
|
2421
|
+
else if (message.sourceConfig?.$case === "s3Config") {
|
|
2422
|
+
const w = writer.uint32(42).fork();
|
|
2423
|
+
exports.DevlabSpec_VolumeMount_S3Config.encode(message.sourceConfig.s3Config, w);
|
|
2424
|
+
w.join();
|
|
2425
|
+
}
|
|
2426
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
2427
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
2428
|
+
}
|
|
2429
|
+
return writer;
|
|
2430
|
+
},
|
|
2431
|
+
decode(input, length) {
|
|
2432
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
2433
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
2434
|
+
const message = createBaseDevlabSpec_VolumeMount();
|
|
2435
|
+
let writer = undefined;
|
|
2436
|
+
while (reader.pos < end) {
|
|
2437
|
+
const tag = reader.uint32();
|
|
2438
|
+
switch (tag >>> 3) {
|
|
2439
|
+
case 1: {
|
|
2440
|
+
if (tag !== 10)
|
|
2441
|
+
break;
|
|
2442
|
+
message.source = reader.string();
|
|
2443
|
+
continue;
|
|
2444
|
+
}
|
|
2445
|
+
case 2: {
|
|
2446
|
+
if (tag !== 18)
|
|
2447
|
+
break;
|
|
2448
|
+
message.sourcePath = reader.string();
|
|
2449
|
+
continue;
|
|
2450
|
+
}
|
|
2451
|
+
case 3: {
|
|
2452
|
+
if (tag !== 26)
|
|
2453
|
+
break;
|
|
2454
|
+
message.containerPath = reader.string();
|
|
2455
|
+
continue;
|
|
2456
|
+
}
|
|
2457
|
+
case 4: {
|
|
2458
|
+
if (tag !== 32)
|
|
2459
|
+
break;
|
|
2460
|
+
message.mode = exports.DevlabSpec_VolumeMount_Mode.fromNumber(reader.int32());
|
|
2461
|
+
continue;
|
|
2462
|
+
}
|
|
2463
|
+
case 5: {
|
|
2464
|
+
if (tag !== 42)
|
|
2465
|
+
break;
|
|
2466
|
+
message.sourceConfig = {
|
|
2467
|
+
$case: "s3Config",
|
|
2468
|
+
s3Config: exports.DevlabSpec_VolumeMount_S3Config.decode(reader, reader.uint32())
|
|
2469
|
+
};
|
|
2470
|
+
continue;
|
|
2471
|
+
}
|
|
2472
|
+
default:
|
|
2473
|
+
break;
|
|
2474
|
+
}
|
|
2475
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
2476
|
+
break;
|
|
2477
|
+
}
|
|
2478
|
+
{
|
|
2479
|
+
if (!writer)
|
|
2480
|
+
writer = new index_js_1.BinaryWriter();
|
|
2481
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
2482
|
+
writer.uint32(tag).raw(skipped);
|
|
2483
|
+
}
|
|
2484
|
+
}
|
|
2485
|
+
if (writer) {
|
|
2486
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
2487
|
+
}
|
|
2488
|
+
return message;
|
|
2489
|
+
},
|
|
2490
|
+
fromJSON(object) {
|
|
2491
|
+
return applyDevlabSpec_VolumeMountCustom({
|
|
2492
|
+
$type: "nebius.ai.v1.DevlabSpec.VolumeMount",
|
|
2493
|
+
source: (0, index_js_1.isSet)(object.source ?? object.source)
|
|
2494
|
+
? String(object.source ?? object.source)
|
|
2495
|
+
: "",
|
|
2496
|
+
sourcePath: (0, index_js_1.isSet)(object.sourcePath ?? object.source_path)
|
|
2497
|
+
? String(object.sourcePath ?? object.source_path)
|
|
2498
|
+
: "",
|
|
2499
|
+
containerPath: (0, index_js_1.isSet)(object.containerPath ?? object.container_path)
|
|
2500
|
+
? String(object.containerPath ?? object.container_path)
|
|
2501
|
+
: "",
|
|
2502
|
+
mode: (0, index_js_1.isSet)(object.mode ?? object.mode)
|
|
2503
|
+
? exports.DevlabSpec_VolumeMount_Mode.fromJSON(object.mode ?? object.mode)
|
|
2504
|
+
: exports.DevlabSpec_VolumeMount_Mode.MODE_UNSPECIFIED,
|
|
2505
|
+
sourceConfig: (() => {
|
|
2506
|
+
if ((0, index_js_1.isSet)(object.s3Config) || (0, index_js_1.isSet)(object.s3_config)) {
|
|
2507
|
+
return {
|
|
2508
|
+
$case: "s3Config",
|
|
2509
|
+
s3Config: exports.DevlabSpec_VolumeMount_S3Config.fromJSON(object.s3Config ?? object.s3_config)
|
|
2510
|
+
};
|
|
2511
|
+
}
|
|
2512
|
+
return undefined;
|
|
2513
|
+
})(),
|
|
2514
|
+
});
|
|
2515
|
+
},
|
|
2516
|
+
toJSON(message, use = "json") {
|
|
2517
|
+
const obj = {};
|
|
2518
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
2519
|
+
if (message.source !== "") {
|
|
2520
|
+
obj[pick("source", "source")] = message.source;
|
|
2521
|
+
}
|
|
2522
|
+
if (message.sourcePath !== "") {
|
|
2523
|
+
obj[pick("sourcePath", "source_path")] = message.sourcePath;
|
|
2524
|
+
}
|
|
2525
|
+
if (message.containerPath !== "") {
|
|
2526
|
+
obj[pick("containerPath", "container_path")] = message.containerPath;
|
|
2527
|
+
}
|
|
2528
|
+
if ((message.mode ?? exports.DevlabSpec_VolumeMount_Mode.MODE_UNSPECIFIED) !== exports.DevlabSpec_VolumeMount_Mode.MODE_UNSPECIFIED) {
|
|
2529
|
+
obj[pick("mode", "mode")] = exports.DevlabSpec_VolumeMount_Mode.toJSON(message.mode);
|
|
2530
|
+
}
|
|
2531
|
+
switch (message.sourceConfig?.$case) {
|
|
2532
|
+
case "s3Config": {
|
|
2533
|
+
obj[pick("s3Config", "s3_config")] = exports.DevlabSpec_VolumeMount_S3Config.toJSON(message.sourceConfig.s3Config, use);
|
|
2534
|
+
break;
|
|
2535
|
+
}
|
|
2536
|
+
default: break;
|
|
2537
|
+
}
|
|
2538
|
+
return obj;
|
|
2539
|
+
},
|
|
2540
|
+
create(base) {
|
|
2541
|
+
return exports.DevlabSpec_VolumeMount.fromPartial(base ?? {});
|
|
2542
|
+
},
|
|
2543
|
+
fromPartial(object) {
|
|
2544
|
+
const message = createBaseDevlabSpec_VolumeMount();
|
|
2545
|
+
message.source = (object.source !== undefined && object.source !== null)
|
|
2546
|
+
? object.source
|
|
2547
|
+
: "";
|
|
2548
|
+
message.sourcePath = (object.sourcePath !== undefined && object.sourcePath !== null)
|
|
2549
|
+
? object.sourcePath
|
|
2550
|
+
: "";
|
|
2551
|
+
message.containerPath = (object.containerPath !== undefined && object.containerPath !== null)
|
|
2552
|
+
? object.containerPath
|
|
2553
|
+
: "";
|
|
2554
|
+
message.mode = (object.mode !== undefined && object.mode !== null)
|
|
2555
|
+
? exports.DevlabSpec_VolumeMount_Mode.fromJSON(object.mode.name)
|
|
2556
|
+
: exports.DevlabSpec_VolumeMount_Mode.MODE_UNSPECIFIED;
|
|
2557
|
+
switch (object.sourceConfig?.$case) {
|
|
2558
|
+
case "s3Config": {
|
|
2559
|
+
if (object.sourceConfig.s3Config !== undefined && object.sourceConfig.s3Config !== null) {
|
|
2560
|
+
message.sourceConfig = {
|
|
2561
|
+
$case: "s3Config",
|
|
2562
|
+
s3Config: exports.DevlabSpec_VolumeMount_S3Config.fromPartial(object.sourceConfig.s3Config),
|
|
2563
|
+
};
|
|
2564
|
+
}
|
|
2565
|
+
break;
|
|
2566
|
+
}
|
|
2567
|
+
default: break;
|
|
2568
|
+
}
|
|
2569
|
+
return message;
|
|
2570
|
+
},
|
|
2571
|
+
};
|
|
2572
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabSpec_VolumeMount);
|
|
2573
|
+
function DevlabSpec_VolumeMountCustomInspect() {
|
|
2574
|
+
const parts = [];
|
|
2575
|
+
if (this.source !== "")
|
|
2576
|
+
parts.push("source" + "=" + (0, util_1.inspect)(this.source));
|
|
2577
|
+
if (this.sourcePath !== "")
|
|
2578
|
+
parts.push("sourcePath" + "=" + (0, util_1.inspect)(this.sourcePath));
|
|
2579
|
+
if (this.containerPath !== "")
|
|
2580
|
+
parts.push("containerPath" + "=" + (0, util_1.inspect)(this.containerPath));
|
|
2581
|
+
if (this.mode !== undefined)
|
|
2582
|
+
parts.push("mode" + "=" + (0, util_1.inspect)(this.mode));
|
|
2583
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
2584
|
+
}
|
|
2585
|
+
function DevlabSpec_VolumeMountCustomJson() {
|
|
2586
|
+
const obj = {
|
|
2587
|
+
type: this.$type,
|
|
2588
|
+
};
|
|
2589
|
+
if (this.source !== "")
|
|
2590
|
+
obj.source = (0, logging_js_1.inspectJson)(this.source);
|
|
2591
|
+
if (this.sourcePath !== "")
|
|
2592
|
+
obj.sourcePath = (0, logging_js_1.inspectJson)(this.sourcePath);
|
|
2593
|
+
if (this.containerPath !== "")
|
|
2594
|
+
obj.containerPath = (0, logging_js_1.inspectJson)(this.containerPath);
|
|
2595
|
+
if (this.mode !== undefined)
|
|
2596
|
+
obj.mode = (0, logging_js_1.inspectJson)(this.mode);
|
|
2597
|
+
return obj;
|
|
2598
|
+
}
|
|
2599
|
+
function applyDevlabSpec_VolumeMountCustom(message) {
|
|
2600
|
+
message[logging_js_1.custom] = DevlabSpec_VolumeMountCustomInspect;
|
|
2601
|
+
message[logging_js_1.customJson] = DevlabSpec_VolumeMountCustomJson;
|
|
2602
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabSpec_VolumeMount.$descriptor);
|
|
2603
|
+
}
|
|
2604
|
+
function createBaseDevlabSpec_VolumeMount() {
|
|
2605
|
+
const message = {
|
|
2606
|
+
$type: "nebius.ai.v1.DevlabSpec.VolumeMount",
|
|
2607
|
+
source: "",
|
|
2608
|
+
sourcePath: "",
|
|
2609
|
+
containerPath: "",
|
|
2610
|
+
mode: exports.DevlabSpec_VolumeMount_Mode.MODE_UNSPECIFIED,
|
|
2611
|
+
sourceConfig: undefined,
|
|
2612
|
+
};
|
|
2613
|
+
return applyDevlabSpec_VolumeMountCustom(message);
|
|
2614
|
+
}
|
|
2615
|
+
const DevlabSpec_VolumeMount_S3Config_MESSAGE_DESCRIPTOR = {
|
|
2616
|
+
fields: {
|
|
2617
|
+
"endpoint": { pbName: "endpoint", scalarType: 9 },
|
|
2618
|
+
"region": { pbName: "region", scalarType: 9 },
|
|
2619
|
+
"mysteryboxSecret": { pbName: "mysterybox_secret", message: () => exports.DevlabSpec_MysteryBoxSecretRef.$descriptor },
|
|
2620
|
+
},
|
|
2621
|
+
};
|
|
2622
|
+
/** Encodes, decodes, converts, and creates {@link DevlabSpec_VolumeMount_S3Config} messages. */
|
|
2623
|
+
exports.DevlabSpec_VolumeMount_S3Config = {
|
|
2624
|
+
$type: "nebius.ai.v1.DevlabSpec.VolumeMount.S3Config",
|
|
2625
|
+
$descriptor: DevlabSpec_VolumeMount_S3Config_MESSAGE_DESCRIPTOR,
|
|
2626
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
2627
|
+
if (message.endpoint !== "") {
|
|
2628
|
+
writer.uint32(10).string(message.endpoint);
|
|
2629
|
+
}
|
|
2630
|
+
if (message.region !== "") {
|
|
2631
|
+
writer.uint32(18).string(message.region);
|
|
2632
|
+
}
|
|
2633
|
+
if (message.mysteryboxSecret !== undefined) {
|
|
2634
|
+
const w = writer.uint32(26).fork();
|
|
2635
|
+
exports.DevlabSpec_MysteryBoxSecretRef.encode(message.mysteryboxSecret, w);
|
|
2636
|
+
w.join();
|
|
2637
|
+
}
|
|
2638
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
2639
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
2640
|
+
}
|
|
2641
|
+
return writer;
|
|
2642
|
+
},
|
|
2643
|
+
decode(input, length) {
|
|
2644
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
2645
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
2646
|
+
const message = createBaseDevlabSpec_VolumeMount_S3Config();
|
|
2647
|
+
let writer = undefined;
|
|
2648
|
+
while (reader.pos < end) {
|
|
2649
|
+
const tag = reader.uint32();
|
|
2650
|
+
switch (tag >>> 3) {
|
|
2651
|
+
case 1: {
|
|
2652
|
+
if (tag !== 10)
|
|
2653
|
+
break;
|
|
2654
|
+
message.endpoint = reader.string();
|
|
2655
|
+
continue;
|
|
2656
|
+
}
|
|
2657
|
+
case 2: {
|
|
2658
|
+
if (tag !== 18)
|
|
2659
|
+
break;
|
|
2660
|
+
message.region = reader.string();
|
|
2661
|
+
continue;
|
|
2662
|
+
}
|
|
2663
|
+
case 3: {
|
|
2664
|
+
if (tag !== 26)
|
|
2665
|
+
break;
|
|
2666
|
+
message.mysteryboxSecret = exports.DevlabSpec_MysteryBoxSecretRef.decode(reader, reader.uint32());
|
|
2667
|
+
continue;
|
|
2668
|
+
}
|
|
2669
|
+
default:
|
|
2670
|
+
break;
|
|
2671
|
+
}
|
|
2672
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
2673
|
+
break;
|
|
2674
|
+
}
|
|
2675
|
+
{
|
|
2676
|
+
if (!writer)
|
|
2677
|
+
writer = new index_js_1.BinaryWriter();
|
|
2678
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
2679
|
+
writer.uint32(tag).raw(skipped);
|
|
2680
|
+
}
|
|
2681
|
+
}
|
|
2682
|
+
if (writer) {
|
|
2683
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
2684
|
+
}
|
|
2685
|
+
return message;
|
|
2686
|
+
},
|
|
2687
|
+
fromJSON(object) {
|
|
2688
|
+
return applyDevlabSpec_VolumeMount_S3ConfigCustom({
|
|
2689
|
+
$type: "nebius.ai.v1.DevlabSpec.VolumeMount.S3Config",
|
|
2690
|
+
endpoint: (0, index_js_1.isSet)(object.endpoint ?? object.endpoint)
|
|
2691
|
+
? String(object.endpoint ?? object.endpoint)
|
|
2692
|
+
: "",
|
|
2693
|
+
region: (0, index_js_1.isSet)(object.region ?? object.region)
|
|
2694
|
+
? String(object.region ?? object.region)
|
|
2695
|
+
: "",
|
|
2696
|
+
mysteryboxSecret: (0, index_js_1.isSet)(object.mysteryboxSecret ?? object.mysterybox_secret)
|
|
2697
|
+
? exports.DevlabSpec_MysteryBoxSecretRef.fromJSON(object.mysteryboxSecret ?? object.mysterybox_secret)
|
|
2698
|
+
: undefined,
|
|
2699
|
+
});
|
|
2700
|
+
},
|
|
2701
|
+
toJSON(message, use = "json") {
|
|
2702
|
+
const obj = {};
|
|
2703
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
2704
|
+
if (message.endpoint !== "") {
|
|
2705
|
+
obj[pick("endpoint", "endpoint")] = message.endpoint;
|
|
2706
|
+
}
|
|
2707
|
+
if (message.region !== "") {
|
|
2708
|
+
obj[pick("region", "region")] = message.region;
|
|
2709
|
+
}
|
|
2710
|
+
if (message.mysteryboxSecret !== undefined) {
|
|
2711
|
+
obj[pick("mysteryboxSecret", "mysterybox_secret")] = message.mysteryboxSecret
|
|
2712
|
+
? exports.DevlabSpec_MysteryBoxSecretRef.toJSON(message.mysteryboxSecret, use)
|
|
2713
|
+
: undefined;
|
|
2714
|
+
}
|
|
2715
|
+
return obj;
|
|
2716
|
+
},
|
|
2717
|
+
create(base) {
|
|
2718
|
+
return exports.DevlabSpec_VolumeMount_S3Config.fromPartial(base ?? {});
|
|
2719
|
+
},
|
|
2720
|
+
fromPartial(object) {
|
|
2721
|
+
const message = createBaseDevlabSpec_VolumeMount_S3Config();
|
|
2722
|
+
message.endpoint = (object.endpoint !== undefined && object.endpoint !== null)
|
|
2723
|
+
? object.endpoint
|
|
2724
|
+
: "";
|
|
2725
|
+
message.region = (object.region !== undefined && object.region !== null)
|
|
2726
|
+
? object.region
|
|
2727
|
+
: "";
|
|
2728
|
+
message.mysteryboxSecret = (object.mysteryboxSecret !== undefined && object.mysteryboxSecret !== null)
|
|
2729
|
+
? exports.DevlabSpec_MysteryBoxSecretRef.fromPartial(object.mysteryboxSecret)
|
|
2730
|
+
: undefined;
|
|
2731
|
+
return message;
|
|
2732
|
+
},
|
|
2733
|
+
};
|
|
2734
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabSpec_VolumeMount_S3Config);
|
|
2735
|
+
function DevlabSpec_VolumeMount_S3ConfigCustomInspect() {
|
|
2736
|
+
const parts = [];
|
|
2737
|
+
if (this.endpoint !== "")
|
|
2738
|
+
parts.push("endpoint" + "=" + (0, util_1.inspect)(this.endpoint));
|
|
2739
|
+
if (this.region !== "")
|
|
2740
|
+
parts.push("region" + "=" + (0, util_1.inspect)(this.region));
|
|
2741
|
+
if (this.mysteryboxSecret !== undefined)
|
|
2742
|
+
parts.push("mysteryboxSecret" + "=" + (0, util_1.inspect)(this.mysteryboxSecret));
|
|
2743
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
2744
|
+
}
|
|
2745
|
+
function DevlabSpec_VolumeMount_S3ConfigCustomJson() {
|
|
2746
|
+
const obj = {
|
|
2747
|
+
type: this.$type,
|
|
2748
|
+
};
|
|
2749
|
+
if (this.endpoint !== "")
|
|
2750
|
+
obj.endpoint = (0, logging_js_1.inspectJson)(this.endpoint);
|
|
2751
|
+
if (this.region !== "")
|
|
2752
|
+
obj.region = (0, logging_js_1.inspectJson)(this.region);
|
|
2753
|
+
if (this.mysteryboxSecret !== undefined)
|
|
2754
|
+
obj.mysteryboxSecret = (0, logging_js_1.inspectJson)(this.mysteryboxSecret);
|
|
2755
|
+
return obj;
|
|
2756
|
+
}
|
|
2757
|
+
function applyDevlabSpec_VolumeMount_S3ConfigCustom(message) {
|
|
2758
|
+
message[logging_js_1.custom] = DevlabSpec_VolumeMount_S3ConfigCustomInspect;
|
|
2759
|
+
message[logging_js_1.customJson] = DevlabSpec_VolumeMount_S3ConfigCustomJson;
|
|
2760
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabSpec_VolumeMount_S3Config.$descriptor);
|
|
2761
|
+
}
|
|
2762
|
+
function createBaseDevlabSpec_VolumeMount_S3Config() {
|
|
2763
|
+
const message = {
|
|
2764
|
+
$type: "nebius.ai.v1.DevlabSpec.VolumeMount.S3Config",
|
|
2765
|
+
endpoint: "",
|
|
2766
|
+
region: "",
|
|
2767
|
+
mysteryboxSecret: undefined,
|
|
2768
|
+
};
|
|
2769
|
+
return applyDevlabSpec_VolumeMount_S3ConfigCustom(message);
|
|
2770
|
+
}
|
|
2771
|
+
const DevlabSpec_DiskSpec_MESSAGE_DESCRIPTOR = {
|
|
2772
|
+
fields: {
|
|
2773
|
+
"type": { pbName: "type", scalarType: 14 },
|
|
2774
|
+
"sizeBytes": { pbName: "size_bytes", scalarType: 3 },
|
|
2775
|
+
},
|
|
2776
|
+
};
|
|
2777
|
+
/** Encodes, decodes, converts, and creates {@link DevlabSpec_DiskSpec} messages. */
|
|
2778
|
+
exports.DevlabSpec_DiskSpec = {
|
|
2779
|
+
$type: "nebius.ai.v1.DevlabSpec.DiskSpec",
|
|
2780
|
+
$descriptor: DevlabSpec_DiskSpec_MESSAGE_DESCRIPTOR,
|
|
2781
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
2782
|
+
if ((message.type ?? index_js_3.DiskSpec_DiskType.UNSPECIFIED) !== index_js_3.DiskSpec_DiskType.UNSPECIFIED) {
|
|
2783
|
+
index_js_3.DiskSpec_DiskType.encodeField(writer, 1, message.type);
|
|
2784
|
+
}
|
|
2785
|
+
if (message.sizeBytes !== undefined && !message.sizeBytes.isZero?.()) {
|
|
2786
|
+
writer.uint32(16).int64(message.sizeBytes.toString());
|
|
2787
|
+
}
|
|
2788
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
2789
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
2790
|
+
}
|
|
2791
|
+
return writer;
|
|
2792
|
+
},
|
|
2793
|
+
decode(input, length) {
|
|
2794
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
2795
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
2796
|
+
const message = createBaseDevlabSpec_DiskSpec();
|
|
2797
|
+
let writer = undefined;
|
|
2798
|
+
while (reader.pos < end) {
|
|
2799
|
+
const tag = reader.uint32();
|
|
2800
|
+
switch (tag >>> 3) {
|
|
2801
|
+
case 1: {
|
|
2802
|
+
if (tag !== 8)
|
|
2803
|
+
break;
|
|
2804
|
+
message.type = index_js_3.DiskSpec_DiskType.fromNumber(reader.int32());
|
|
2805
|
+
continue;
|
|
2806
|
+
}
|
|
2807
|
+
case 2: {
|
|
2808
|
+
if (tag !== 16)
|
|
2809
|
+
break;
|
|
2810
|
+
message.sizeBytes = index_js_1.Long.fromValue(reader.int64());
|
|
2811
|
+
continue;
|
|
2812
|
+
}
|
|
2813
|
+
default:
|
|
2814
|
+
break;
|
|
2815
|
+
}
|
|
2816
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
2817
|
+
break;
|
|
2818
|
+
}
|
|
2819
|
+
{
|
|
2820
|
+
if (!writer)
|
|
2821
|
+
writer = new index_js_1.BinaryWriter();
|
|
2822
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
2823
|
+
writer.uint32(tag).raw(skipped);
|
|
2824
|
+
}
|
|
2825
|
+
}
|
|
2826
|
+
if (writer) {
|
|
2827
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
2828
|
+
}
|
|
2829
|
+
return message;
|
|
2830
|
+
},
|
|
2831
|
+
fromJSON(object) {
|
|
2832
|
+
return applyDevlabSpec_DiskSpecCustom({
|
|
2833
|
+
$type: "nebius.ai.v1.DevlabSpec.DiskSpec",
|
|
2834
|
+
type: (0, index_js_1.isSet)(object.type ?? object.type)
|
|
2835
|
+
? index_js_3.DiskSpec_DiskType.fromJSON(object.type ?? object.type)
|
|
2836
|
+
: index_js_3.DiskSpec_DiskType.UNSPECIFIED,
|
|
2837
|
+
sizeBytes: (0, index_js_1.isSet)(object.sizeBytes ?? object.size_bytes)
|
|
2838
|
+
? index_js_1.Long.fromValue(object.sizeBytes ?? object.size_bytes)
|
|
2839
|
+
: index_js_1.Long.ZERO,
|
|
2840
|
+
});
|
|
2841
|
+
},
|
|
2842
|
+
toJSON(message, use = "json") {
|
|
2843
|
+
const obj = {};
|
|
2844
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
2845
|
+
if ((message.type ?? index_js_3.DiskSpec_DiskType.UNSPECIFIED) !== index_js_3.DiskSpec_DiskType.UNSPECIFIED) {
|
|
2846
|
+
obj[pick("type", "type")] = index_js_3.DiskSpec_DiskType.toJSON(message.type);
|
|
2847
|
+
}
|
|
2848
|
+
if (!message.sizeBytes?.isZero?.()) {
|
|
2849
|
+
obj[pick("sizeBytes", "size_bytes")] = (message.sizeBytes || index_js_1.Long.ZERO).toString();
|
|
2850
|
+
}
|
|
2851
|
+
return obj;
|
|
2852
|
+
},
|
|
2853
|
+
create(base) {
|
|
2854
|
+
return exports.DevlabSpec_DiskSpec.fromPartial(base ?? {});
|
|
2855
|
+
},
|
|
2856
|
+
fromPartial(object) {
|
|
2857
|
+
const message = createBaseDevlabSpec_DiskSpec();
|
|
2858
|
+
message.type = (object.type !== undefined && object.type !== null)
|
|
2859
|
+
? index_js_3.DiskSpec_DiskType.fromJSON(object.type.name)
|
|
2860
|
+
: index_js_3.DiskSpec_DiskType.UNSPECIFIED;
|
|
2861
|
+
message.sizeBytes = (object.sizeBytes !== undefined && object.sizeBytes !== null)
|
|
2862
|
+
? index_js_1.Long.fromValue(object.sizeBytes)
|
|
2863
|
+
: index_js_1.Long.ZERO;
|
|
2864
|
+
return message;
|
|
2865
|
+
},
|
|
2866
|
+
};
|
|
2867
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabSpec_DiskSpec);
|
|
2868
|
+
function DevlabSpec_DiskSpecCustomInspect() {
|
|
2869
|
+
const parts = [];
|
|
2870
|
+
if (this.type !== undefined)
|
|
2871
|
+
parts.push("type" + "=" + (0, util_1.inspect)(this.type));
|
|
2872
|
+
if (!this.sizeBytes?.isZero?.())
|
|
2873
|
+
parts.push("sizeBytes" + "=" + (0, util_1.inspect)(this.sizeBytes));
|
|
2874
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
2875
|
+
}
|
|
2876
|
+
function DevlabSpec_DiskSpecCustomJson() {
|
|
2877
|
+
const obj = {
|
|
2878
|
+
type: this.$type,
|
|
2879
|
+
};
|
|
2880
|
+
if (this.type !== undefined)
|
|
2881
|
+
obj.type = (0, logging_js_1.inspectJson)(this.type);
|
|
2882
|
+
if (!this.sizeBytes?.isZero?.())
|
|
2883
|
+
obj.sizeBytes = (0, logging_js_1.inspectJson)(this.sizeBytes);
|
|
2884
|
+
return obj;
|
|
2885
|
+
}
|
|
2886
|
+
function applyDevlabSpec_DiskSpecCustom(message) {
|
|
2887
|
+
message[logging_js_1.custom] = DevlabSpec_DiskSpecCustomInspect;
|
|
2888
|
+
message[logging_js_1.customJson] = DevlabSpec_DiskSpecCustomJson;
|
|
2889
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabSpec_DiskSpec.$descriptor);
|
|
2890
|
+
}
|
|
2891
|
+
function createBaseDevlabSpec_DiskSpec() {
|
|
2892
|
+
const message = {
|
|
2893
|
+
$type: "nebius.ai.v1.DevlabSpec.DiskSpec",
|
|
2894
|
+
type: index_js_3.DiskSpec_DiskType.UNSPECIFIED,
|
|
2895
|
+
sizeBytes: index_js_1.Long.ZERO,
|
|
2896
|
+
};
|
|
2897
|
+
return applyDevlabSpec_DiskSpecCustom(message);
|
|
2898
|
+
}
|
|
2899
|
+
const DevlabSpec_RegistryCredentials_MESSAGE_DESCRIPTOR = {
|
|
2900
|
+
fields: {
|
|
2901
|
+
"mysteryboxSecretVersion": { pbName: "mysterybox_secret_version", scalarType: 9 },
|
|
2902
|
+
},
|
|
2903
|
+
};
|
|
2904
|
+
/** Encodes, decodes, converts, and creates {@link DevlabSpec_RegistryCredentials} messages. */
|
|
2905
|
+
exports.DevlabSpec_RegistryCredentials = {
|
|
2906
|
+
$type: "nebius.ai.v1.DevlabSpec.RegistryCredentials",
|
|
2907
|
+
$descriptor: DevlabSpec_RegistryCredentials_MESSAGE_DESCRIPTOR,
|
|
2908
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
2909
|
+
if (message.mysteryboxSecretVersion !== "") {
|
|
2910
|
+
writer.uint32(10).string(message.mysteryboxSecretVersion);
|
|
2911
|
+
}
|
|
2912
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
2913
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
2914
|
+
}
|
|
2915
|
+
return writer;
|
|
2916
|
+
},
|
|
2917
|
+
decode(input, length) {
|
|
2918
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
2919
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
2920
|
+
const message = createBaseDevlabSpec_RegistryCredentials();
|
|
2921
|
+
let writer = undefined;
|
|
2922
|
+
while (reader.pos < end) {
|
|
2923
|
+
const tag = reader.uint32();
|
|
2924
|
+
switch (tag >>> 3) {
|
|
2925
|
+
case 1: {
|
|
2926
|
+
if (tag !== 10)
|
|
2927
|
+
break;
|
|
2928
|
+
message.mysteryboxSecretVersion = reader.string();
|
|
2929
|
+
continue;
|
|
2930
|
+
}
|
|
2931
|
+
default:
|
|
2932
|
+
break;
|
|
2933
|
+
}
|
|
2934
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
2935
|
+
break;
|
|
2936
|
+
}
|
|
2937
|
+
{
|
|
2938
|
+
if (!writer)
|
|
2939
|
+
writer = new index_js_1.BinaryWriter();
|
|
2940
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
2941
|
+
writer.uint32(tag).raw(skipped);
|
|
2942
|
+
}
|
|
2943
|
+
}
|
|
2944
|
+
if (writer) {
|
|
2945
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
2946
|
+
}
|
|
2947
|
+
return message;
|
|
2948
|
+
},
|
|
2949
|
+
fromJSON(object) {
|
|
2950
|
+
return applyDevlabSpec_RegistryCredentialsCustom({
|
|
2951
|
+
$type: "nebius.ai.v1.DevlabSpec.RegistryCredentials",
|
|
2952
|
+
mysteryboxSecretVersion: (0, index_js_1.isSet)(object.mysteryboxSecretVersion ?? object.mysterybox_secret_version)
|
|
2953
|
+
? String(object.mysteryboxSecretVersion ?? object.mysterybox_secret_version)
|
|
2954
|
+
: "",
|
|
2955
|
+
});
|
|
2956
|
+
},
|
|
2957
|
+
toJSON(message, use = "json") {
|
|
2958
|
+
const obj = {};
|
|
2959
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
2960
|
+
if (message.mysteryboxSecretVersion !== "") {
|
|
2961
|
+
obj[pick("mysteryboxSecretVersion", "mysterybox_secret_version")] = message.mysteryboxSecretVersion;
|
|
2962
|
+
}
|
|
2963
|
+
return obj;
|
|
2964
|
+
},
|
|
2965
|
+
create(base) {
|
|
2966
|
+
return exports.DevlabSpec_RegistryCredentials.fromPartial(base ?? {});
|
|
2967
|
+
},
|
|
2968
|
+
fromPartial(object) {
|
|
2969
|
+
const message = createBaseDevlabSpec_RegistryCredentials();
|
|
2970
|
+
message.mysteryboxSecretVersion = (object.mysteryboxSecretVersion !== undefined && object.mysteryboxSecretVersion !== null)
|
|
2971
|
+
? object.mysteryboxSecretVersion
|
|
2972
|
+
: "";
|
|
2973
|
+
return message;
|
|
2974
|
+
},
|
|
2975
|
+
};
|
|
2976
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabSpec_RegistryCredentials);
|
|
2977
|
+
function DevlabSpec_RegistryCredentialsCustomInspect() {
|
|
2978
|
+
const parts = [];
|
|
2979
|
+
if (this.mysteryboxSecretVersion !== "")
|
|
2980
|
+
parts.push("mysteryboxSecretVersion" + "=" + (0, util_1.inspect)(this.mysteryboxSecretVersion));
|
|
2981
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
2982
|
+
}
|
|
2983
|
+
function DevlabSpec_RegistryCredentialsCustomJson() {
|
|
2984
|
+
const obj = {
|
|
2985
|
+
type: this.$type,
|
|
2986
|
+
};
|
|
2987
|
+
if (this.mysteryboxSecretVersion !== "")
|
|
2988
|
+
obj.mysteryboxSecretVersion = (0, logging_js_1.inspectJson)(this.mysteryboxSecretVersion);
|
|
2989
|
+
return obj;
|
|
2990
|
+
}
|
|
2991
|
+
function applyDevlabSpec_RegistryCredentialsCustom(message) {
|
|
2992
|
+
message[logging_js_1.custom] = DevlabSpec_RegistryCredentialsCustomInspect;
|
|
2993
|
+
message[logging_js_1.customJson] = DevlabSpec_RegistryCredentialsCustomJson;
|
|
2994
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabSpec_RegistryCredentials.$descriptor);
|
|
2995
|
+
}
|
|
2996
|
+
function createBaseDevlabSpec_RegistryCredentials() {
|
|
2997
|
+
const message = {
|
|
2998
|
+
$type: "nebius.ai.v1.DevlabSpec.RegistryCredentials",
|
|
2999
|
+
mysteryboxSecretVersion: "",
|
|
3000
|
+
};
|
|
3001
|
+
return applyDevlabSpec_RegistryCredentialsCustom(message);
|
|
3002
|
+
}
|
|
3003
|
+
const DevlabSpec_Workspace_MESSAGE_DESCRIPTOR = {
|
|
3004
|
+
fields: {
|
|
3005
|
+
"containerPath": { pbName: "container_path", immutable: true, scalarType: 9 },
|
|
3006
|
+
},
|
|
3007
|
+
};
|
|
3008
|
+
/** Encodes, decodes, converts, and creates {@link DevlabSpec_Workspace} messages. */
|
|
3009
|
+
exports.DevlabSpec_Workspace = {
|
|
3010
|
+
$type: "nebius.ai.v1.DevlabSpec.Workspace",
|
|
3011
|
+
$descriptor: DevlabSpec_Workspace_MESSAGE_DESCRIPTOR,
|
|
3012
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
3013
|
+
if (message.containerPath !== "") {
|
|
3014
|
+
writer.uint32(10).string(message.containerPath);
|
|
3015
|
+
}
|
|
3016
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
3017
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
3018
|
+
}
|
|
3019
|
+
return writer;
|
|
3020
|
+
},
|
|
3021
|
+
decode(input, length) {
|
|
3022
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
3023
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
3024
|
+
const message = createBaseDevlabSpec_Workspace();
|
|
3025
|
+
let writer = undefined;
|
|
3026
|
+
while (reader.pos < end) {
|
|
3027
|
+
const tag = reader.uint32();
|
|
3028
|
+
switch (tag >>> 3) {
|
|
3029
|
+
case 1: {
|
|
3030
|
+
if (tag !== 10)
|
|
3031
|
+
break;
|
|
3032
|
+
message.containerPath = reader.string();
|
|
3033
|
+
continue;
|
|
3034
|
+
}
|
|
3035
|
+
default:
|
|
3036
|
+
break;
|
|
3037
|
+
}
|
|
3038
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
3039
|
+
break;
|
|
3040
|
+
}
|
|
3041
|
+
{
|
|
3042
|
+
if (!writer)
|
|
3043
|
+
writer = new index_js_1.BinaryWriter();
|
|
3044
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
3045
|
+
writer.uint32(tag).raw(skipped);
|
|
3046
|
+
}
|
|
3047
|
+
}
|
|
3048
|
+
if (writer) {
|
|
3049
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
3050
|
+
}
|
|
3051
|
+
return message;
|
|
3052
|
+
},
|
|
3053
|
+
fromJSON(object) {
|
|
3054
|
+
return applyDevlabSpec_WorkspaceCustom({
|
|
3055
|
+
$type: "nebius.ai.v1.DevlabSpec.Workspace",
|
|
3056
|
+
containerPath: (0, index_js_1.isSet)(object.containerPath ?? object.container_path)
|
|
3057
|
+
? String(object.containerPath ?? object.container_path)
|
|
3058
|
+
: "",
|
|
3059
|
+
});
|
|
3060
|
+
},
|
|
3061
|
+
toJSON(message, use = "json") {
|
|
3062
|
+
const obj = {};
|
|
3063
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
3064
|
+
if (message.containerPath !== "") {
|
|
3065
|
+
obj[pick("containerPath", "container_path")] = message.containerPath;
|
|
3066
|
+
}
|
|
3067
|
+
return obj;
|
|
3068
|
+
},
|
|
3069
|
+
create(base) {
|
|
3070
|
+
return exports.DevlabSpec_Workspace.fromPartial(base ?? {});
|
|
3071
|
+
},
|
|
3072
|
+
fromPartial(object) {
|
|
3073
|
+
const message = createBaseDevlabSpec_Workspace();
|
|
3074
|
+
message.containerPath = (object.containerPath !== undefined && object.containerPath !== null)
|
|
3075
|
+
? object.containerPath
|
|
3076
|
+
: "";
|
|
3077
|
+
return message;
|
|
3078
|
+
},
|
|
3079
|
+
};
|
|
3080
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabSpec_Workspace);
|
|
3081
|
+
function DevlabSpec_WorkspaceCustomInspect() {
|
|
3082
|
+
const parts = [];
|
|
3083
|
+
if (this.containerPath !== "")
|
|
3084
|
+
parts.push("containerPath" + "=" + (0, util_1.inspect)(this.containerPath));
|
|
3085
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
3086
|
+
}
|
|
3087
|
+
function DevlabSpec_WorkspaceCustomJson() {
|
|
3088
|
+
const obj = {
|
|
3089
|
+
type: this.$type,
|
|
3090
|
+
};
|
|
3091
|
+
if (this.containerPath !== "")
|
|
3092
|
+
obj.containerPath = (0, logging_js_1.inspectJson)(this.containerPath);
|
|
3093
|
+
return obj;
|
|
3094
|
+
}
|
|
3095
|
+
function applyDevlabSpec_WorkspaceCustom(message) {
|
|
3096
|
+
message[logging_js_1.custom] = DevlabSpec_WorkspaceCustomInspect;
|
|
3097
|
+
message[logging_js_1.customJson] = DevlabSpec_WorkspaceCustomJson;
|
|
3098
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabSpec_Workspace.$descriptor);
|
|
3099
|
+
}
|
|
3100
|
+
function createBaseDevlabSpec_Workspace() {
|
|
3101
|
+
const message = {
|
|
3102
|
+
$type: "nebius.ai.v1.DevlabSpec.Workspace",
|
|
3103
|
+
containerPath: "",
|
|
3104
|
+
};
|
|
3105
|
+
return applyDevlabSpec_WorkspaceCustom(message);
|
|
3106
|
+
}
|
|
3107
|
+
const DevlabSpec_PrimaryRoute_MESSAGE_DESCRIPTOR = {
|
|
3108
|
+
fields: {
|
|
3109
|
+
"containerPort": { pbName: "container_port", immutable: true, scalarType: 5 },
|
|
3110
|
+
},
|
|
3111
|
+
};
|
|
3112
|
+
/** Encodes, decodes, converts, and creates {@link DevlabSpec_PrimaryRoute} messages. */
|
|
3113
|
+
exports.DevlabSpec_PrimaryRoute = {
|
|
3114
|
+
$type: "nebius.ai.v1.DevlabSpec.PrimaryRoute",
|
|
3115
|
+
$descriptor: DevlabSpec_PrimaryRoute_MESSAGE_DESCRIPTOR,
|
|
3116
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
3117
|
+
if ((message.containerPort ?? 0) !== 0) {
|
|
3118
|
+
writer.uint32(8).int32(message.containerPort);
|
|
3119
|
+
}
|
|
3120
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
3121
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
3122
|
+
}
|
|
3123
|
+
return writer;
|
|
3124
|
+
},
|
|
3125
|
+
decode(input, length) {
|
|
3126
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
3127
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
3128
|
+
const message = createBaseDevlabSpec_PrimaryRoute();
|
|
3129
|
+
let writer = undefined;
|
|
3130
|
+
while (reader.pos < end) {
|
|
3131
|
+
const tag = reader.uint32();
|
|
3132
|
+
switch (tag >>> 3) {
|
|
3133
|
+
case 1: {
|
|
3134
|
+
if (tag !== 8)
|
|
3135
|
+
break;
|
|
3136
|
+
message.containerPort = reader.int32();
|
|
3137
|
+
continue;
|
|
3138
|
+
}
|
|
3139
|
+
default:
|
|
3140
|
+
break;
|
|
3141
|
+
}
|
|
3142
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
3143
|
+
break;
|
|
3144
|
+
}
|
|
3145
|
+
{
|
|
3146
|
+
if (!writer)
|
|
3147
|
+
writer = new index_js_1.BinaryWriter();
|
|
3148
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
3149
|
+
writer.uint32(tag).raw(skipped);
|
|
3150
|
+
}
|
|
3151
|
+
}
|
|
3152
|
+
if (writer) {
|
|
3153
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
3154
|
+
}
|
|
3155
|
+
return message;
|
|
3156
|
+
},
|
|
3157
|
+
fromJSON(object) {
|
|
3158
|
+
return applyDevlabSpec_PrimaryRouteCustom({
|
|
3159
|
+
$type: "nebius.ai.v1.DevlabSpec.PrimaryRoute",
|
|
3160
|
+
containerPort: (0, index_js_1.isSet)(object.containerPort ?? object.container_port)
|
|
3161
|
+
? Number(object.containerPort ?? object.container_port)
|
|
3162
|
+
: 0,
|
|
3163
|
+
});
|
|
3164
|
+
},
|
|
3165
|
+
toJSON(message, use = "json") {
|
|
3166
|
+
const obj = {};
|
|
3167
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
3168
|
+
if ((message.containerPort ?? 0) !== 0) {
|
|
3169
|
+
obj[pick("containerPort", "container_port")] = message.containerPort;
|
|
3170
|
+
}
|
|
3171
|
+
return obj;
|
|
3172
|
+
},
|
|
3173
|
+
create(base) {
|
|
3174
|
+
return exports.DevlabSpec_PrimaryRoute.fromPartial(base ?? {});
|
|
3175
|
+
},
|
|
3176
|
+
fromPartial(object) {
|
|
3177
|
+
const message = createBaseDevlabSpec_PrimaryRoute();
|
|
3178
|
+
message.containerPort = (object.containerPort !== undefined && object.containerPort !== null)
|
|
3179
|
+
? object.containerPort
|
|
3180
|
+
: 0;
|
|
3181
|
+
return message;
|
|
3182
|
+
},
|
|
3183
|
+
};
|
|
3184
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabSpec_PrimaryRoute);
|
|
3185
|
+
function DevlabSpec_PrimaryRouteCustomInspect() {
|
|
3186
|
+
const parts = [];
|
|
3187
|
+
if ((this.containerPort ?? 0) !== 0)
|
|
3188
|
+
parts.push("containerPort" + "=" + (0, util_1.inspect)(this.containerPort));
|
|
3189
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
3190
|
+
}
|
|
3191
|
+
function DevlabSpec_PrimaryRouteCustomJson() {
|
|
3192
|
+
const obj = {
|
|
3193
|
+
type: this.$type,
|
|
3194
|
+
};
|
|
3195
|
+
if ((this.containerPort ?? 0) !== 0)
|
|
3196
|
+
obj.containerPort = (0, logging_js_1.inspectJson)(this.containerPort);
|
|
3197
|
+
return obj;
|
|
3198
|
+
}
|
|
3199
|
+
function applyDevlabSpec_PrimaryRouteCustom(message) {
|
|
3200
|
+
message[logging_js_1.custom] = DevlabSpec_PrimaryRouteCustomInspect;
|
|
3201
|
+
message[logging_js_1.customJson] = DevlabSpec_PrimaryRouteCustomJson;
|
|
3202
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabSpec_PrimaryRoute.$descriptor);
|
|
3203
|
+
}
|
|
3204
|
+
function createBaseDevlabSpec_PrimaryRoute() {
|
|
3205
|
+
const message = {
|
|
3206
|
+
$type: "nebius.ai.v1.DevlabSpec.PrimaryRoute",
|
|
3207
|
+
containerPort: 0,
|
|
3208
|
+
};
|
|
3209
|
+
return applyDevlabSpec_PrimaryRouteCustom(message);
|
|
3210
|
+
}
|
|
3211
|
+
const DevlabSpec_FileInjection_MESSAGE_DESCRIPTOR = {
|
|
3212
|
+
fields: {
|
|
3213
|
+
"containerPath": { pbName: "container_path", scalarType: 9 },
|
|
3214
|
+
"content": { pbName: "content", scalarType: 12 },
|
|
3215
|
+
},
|
|
3216
|
+
};
|
|
3217
|
+
/** Encodes, decodes, converts, and creates {@link DevlabSpec_FileInjection} messages. */
|
|
3218
|
+
exports.DevlabSpec_FileInjection = {
|
|
3219
|
+
$type: "nebius.ai.v1.DevlabSpec.FileInjection",
|
|
3220
|
+
$descriptor: DevlabSpec_FileInjection_MESSAGE_DESCRIPTOR,
|
|
3221
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
3222
|
+
if (message.containerPath !== "") {
|
|
3223
|
+
writer.uint32(10).string(message.containerPath);
|
|
3224
|
+
}
|
|
3225
|
+
if ((message.content?.length ?? 0) !== 0) {
|
|
3226
|
+
writer.uint32(18).bytes(message.content);
|
|
3227
|
+
}
|
|
3228
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
3229
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
3230
|
+
}
|
|
3231
|
+
return writer;
|
|
3232
|
+
},
|
|
3233
|
+
decode(input, length) {
|
|
3234
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
3235
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
3236
|
+
const message = createBaseDevlabSpec_FileInjection();
|
|
3237
|
+
let writer = undefined;
|
|
3238
|
+
while (reader.pos < end) {
|
|
3239
|
+
const tag = reader.uint32();
|
|
3240
|
+
switch (tag >>> 3) {
|
|
3241
|
+
case 1: {
|
|
3242
|
+
if (tag !== 10)
|
|
3243
|
+
break;
|
|
3244
|
+
message.containerPath = reader.string();
|
|
3245
|
+
continue;
|
|
3246
|
+
}
|
|
3247
|
+
case 2: {
|
|
3248
|
+
if (tag !== 18)
|
|
3249
|
+
break;
|
|
3250
|
+
message.content = reader.bytes();
|
|
3251
|
+
continue;
|
|
3252
|
+
}
|
|
3253
|
+
default:
|
|
3254
|
+
break;
|
|
3255
|
+
}
|
|
3256
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
3257
|
+
break;
|
|
3258
|
+
}
|
|
3259
|
+
{
|
|
3260
|
+
if (!writer)
|
|
3261
|
+
writer = new index_js_1.BinaryWriter();
|
|
3262
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
3263
|
+
writer.uint32(tag).raw(skipped);
|
|
3264
|
+
}
|
|
3265
|
+
}
|
|
3266
|
+
if (writer) {
|
|
3267
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
3268
|
+
}
|
|
3269
|
+
return message;
|
|
3270
|
+
},
|
|
3271
|
+
fromJSON(object) {
|
|
3272
|
+
return applyDevlabSpec_FileInjectionCustom({
|
|
3273
|
+
$type: "nebius.ai.v1.DevlabSpec.FileInjection",
|
|
3274
|
+
containerPath: (0, index_js_1.isSet)(object.containerPath ?? object.container_path)
|
|
3275
|
+
? String(object.containerPath ?? object.container_path)
|
|
3276
|
+
: "",
|
|
3277
|
+
content: (0, index_js_1.isSet)(object.content ?? object.content)
|
|
3278
|
+
? (0, index_js_1.bytesFromBase64)(object.content ?? object.content)
|
|
3279
|
+
: new Uint8Array(0),
|
|
3280
|
+
});
|
|
3281
|
+
},
|
|
3282
|
+
toJSON(message, use = "json") {
|
|
3283
|
+
const obj = {};
|
|
3284
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
3285
|
+
if (message.containerPath !== "") {
|
|
3286
|
+
obj[pick("containerPath", "container_path")] = message.containerPath;
|
|
3287
|
+
}
|
|
3288
|
+
if ((message.content?.length ?? 0) !== 0) {
|
|
3289
|
+
obj[pick("content", "content")] = (0, index_js_1.base64FromBytes)(message.content);
|
|
3290
|
+
}
|
|
3291
|
+
return obj;
|
|
3292
|
+
},
|
|
3293
|
+
create(base) {
|
|
3294
|
+
return exports.DevlabSpec_FileInjection.fromPartial(base ?? {});
|
|
3295
|
+
},
|
|
3296
|
+
fromPartial(object) {
|
|
3297
|
+
const message = createBaseDevlabSpec_FileInjection();
|
|
3298
|
+
message.containerPath = (object.containerPath !== undefined && object.containerPath !== null)
|
|
3299
|
+
? object.containerPath
|
|
3300
|
+
: "";
|
|
3301
|
+
message.content = (object.content !== undefined && object.content !== null)
|
|
3302
|
+
? object.content
|
|
3303
|
+
: new Uint8Array(0);
|
|
3304
|
+
return message;
|
|
3305
|
+
},
|
|
3306
|
+
};
|
|
3307
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabSpec_FileInjection);
|
|
3308
|
+
function DevlabSpec_FileInjectionCustomInspect() {
|
|
3309
|
+
const parts = [];
|
|
3310
|
+
if (this.containerPath !== "")
|
|
3311
|
+
parts.push("containerPath" + "=" + (0, util_1.inspect)(this.containerPath));
|
|
3312
|
+
if ((this.content?.length ?? 0) !== 0)
|
|
3313
|
+
parts.push("content" + "=***");
|
|
3314
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
3315
|
+
}
|
|
3316
|
+
function DevlabSpec_FileInjectionCustomJson() {
|
|
3317
|
+
const obj = {
|
|
3318
|
+
type: this.$type,
|
|
3319
|
+
};
|
|
3320
|
+
if (this.containerPath !== "")
|
|
3321
|
+
obj.containerPath = (0, logging_js_1.inspectJson)(this.containerPath);
|
|
3322
|
+
if ((this.content?.length ?? 0) !== 0)
|
|
3323
|
+
obj.content = "***";
|
|
3324
|
+
return obj;
|
|
3325
|
+
}
|
|
3326
|
+
function applyDevlabSpec_FileInjectionCustom(message) {
|
|
3327
|
+
message[logging_js_1.custom] = DevlabSpec_FileInjectionCustomInspect;
|
|
3328
|
+
message[logging_js_1.customJson] = DevlabSpec_FileInjectionCustomJson;
|
|
3329
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabSpec_FileInjection.$descriptor);
|
|
3330
|
+
}
|
|
3331
|
+
function createBaseDevlabSpec_FileInjection() {
|
|
3332
|
+
const message = {
|
|
3333
|
+
$type: "nebius.ai.v1.DevlabSpec.FileInjection",
|
|
3334
|
+
containerPath: "",
|
|
3335
|
+
content: new Uint8Array(0),
|
|
3336
|
+
};
|
|
3337
|
+
return applyDevlabSpec_FileInjectionCustom(message);
|
|
3338
|
+
}
|
|
3339
|
+
const DevlabSpec_Template_MESSAGE_DESCRIPTOR = {
|
|
3340
|
+
fields: {
|
|
3341
|
+
"id": { pbName: "id", scalarType: 9 },
|
|
3342
|
+
"inputFieldValues": { pbName: "input_field_values", map: true, mapValue: () => index_js_1.wkt[".google.protobuf.Value"].$descriptor },
|
|
3343
|
+
},
|
|
3344
|
+
};
|
|
3345
|
+
/** Encodes, decodes, converts, and creates {@link DevlabSpec_Template} messages. */
|
|
3346
|
+
exports.DevlabSpec_Template = {
|
|
3347
|
+
$type: "nebius.ai.v1.DevlabSpec.Template",
|
|
3348
|
+
$descriptor: DevlabSpec_Template_MESSAGE_DESCRIPTOR,
|
|
3349
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
3350
|
+
if (message.id !== "") {
|
|
3351
|
+
writer.uint32(10).string(message.id);
|
|
3352
|
+
}
|
|
3353
|
+
for (const [k, v] of Object.entries(message.inputFieldValues ?? {})) {
|
|
3354
|
+
const w = writer.uint32(18).fork();
|
|
3355
|
+
w.uint32(10).string(k);
|
|
3356
|
+
(() => {
|
|
3357
|
+
const w2 = writer.uint32(18).fork();
|
|
3358
|
+
index_js_1.wkt[".google.protobuf.Value"].writeMessage(w2, v);
|
|
3359
|
+
w2.join();
|
|
3360
|
+
})();
|
|
3361
|
+
w.join();
|
|
3362
|
+
}
|
|
3363
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
3364
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
3365
|
+
}
|
|
3366
|
+
return writer;
|
|
3367
|
+
},
|
|
3368
|
+
decode(input, length) {
|
|
3369
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
3370
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
3371
|
+
const message = createBaseDevlabSpec_Template();
|
|
3372
|
+
let writer = undefined;
|
|
3373
|
+
while (reader.pos < end) {
|
|
3374
|
+
const tag = reader.uint32();
|
|
3375
|
+
switch (tag >>> 3) {
|
|
3376
|
+
case 1: {
|
|
3377
|
+
if (tag !== 10)
|
|
3378
|
+
break;
|
|
3379
|
+
message.id = reader.string();
|
|
3380
|
+
continue;
|
|
3381
|
+
}
|
|
3382
|
+
case 2: {
|
|
3383
|
+
if (tag !== 18)
|
|
3384
|
+
break; // wire type guard
|
|
3385
|
+
const end2 = reader.uint32() + reader.pos;
|
|
3386
|
+
let key = "";
|
|
3387
|
+
let value = undefined;
|
|
3388
|
+
while (reader.pos < end2) {
|
|
3389
|
+
const tag2 = reader.uint32();
|
|
3390
|
+
switch (tag2 >>> 3) {
|
|
3391
|
+
case 1: {
|
|
3392
|
+
key = reader.string();
|
|
3393
|
+
continue;
|
|
3394
|
+
}
|
|
3395
|
+
case 2: {
|
|
3396
|
+
value = index_js_1.wkt[".google.protobuf.Value"].readMessage(reader, reader.uint32());
|
|
3397
|
+
continue;
|
|
3398
|
+
}
|
|
3399
|
+
}
|
|
3400
|
+
if ((tag2 & 7) === 4 || tag2 === 0)
|
|
3401
|
+
break;
|
|
3402
|
+
reader.skip(tag2 & 7);
|
|
3403
|
+
}
|
|
3404
|
+
if (value !== undefined) {
|
|
3405
|
+
const stringKey = String(key);
|
|
3406
|
+
message.inputFieldValues[stringKey] = value;
|
|
3407
|
+
}
|
|
3408
|
+
continue;
|
|
3409
|
+
}
|
|
3410
|
+
default:
|
|
3411
|
+
break;
|
|
3412
|
+
}
|
|
3413
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
3414
|
+
break;
|
|
3415
|
+
}
|
|
3416
|
+
{
|
|
3417
|
+
if (!writer)
|
|
3418
|
+
writer = new index_js_1.BinaryWriter();
|
|
3419
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
3420
|
+
writer.uint32(tag).raw(skipped);
|
|
3421
|
+
}
|
|
3422
|
+
}
|
|
3423
|
+
if (writer) {
|
|
3424
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
3425
|
+
}
|
|
3426
|
+
return message;
|
|
3427
|
+
},
|
|
3428
|
+
fromJSON(object) {
|
|
3429
|
+
return applyDevlabSpec_TemplateCustom({
|
|
3430
|
+
$type: "nebius.ai.v1.DevlabSpec.Template",
|
|
3431
|
+
id: (0, index_js_1.isSet)(object.id ?? object.id)
|
|
3432
|
+
? String(object.id ?? object.id)
|
|
3433
|
+
: "",
|
|
3434
|
+
inputFieldValues: ((0, index_js_1.isSet)(object.inputFieldValues) && typeof object.inputFieldValues === "object" ? object.inputFieldValues
|
|
3435
|
+
: ((0, index_js_1.isSet)(object.input_field_values) && typeof object.input_field_values === "object" ? object.input_field_values : undefined))
|
|
3436
|
+
? Object.entries((object.inputFieldValues ?? object.input_field_values)).reduce((acc, [key, value]) => {
|
|
3437
|
+
acc[key] = index_js_1.wkt[".google.protobuf.Value"].fromJSON(value);
|
|
3438
|
+
return acc;
|
|
3439
|
+
}, {})
|
|
3440
|
+
: {},
|
|
3441
|
+
});
|
|
3442
|
+
},
|
|
3443
|
+
toJSON(message, use = "json") {
|
|
3444
|
+
const obj = {};
|
|
3445
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
3446
|
+
if (message.id !== "") {
|
|
3447
|
+
obj[pick("id", "id")] = message.id;
|
|
3448
|
+
}
|
|
3449
|
+
if (message.inputFieldValues) {
|
|
3450
|
+
const entries = Object.entries(message.inputFieldValues);
|
|
3451
|
+
if (entries.length > 0) {
|
|
3452
|
+
obj[pick("inputFieldValues", "input_field_values")] = {};
|
|
3453
|
+
entries.forEach(([k, v]) => {
|
|
3454
|
+
obj[pick("inputFieldValues", "input_field_values")][k] = index_js_1.wkt[".google.protobuf.Value"].toJSON(v, use);
|
|
3455
|
+
});
|
|
3456
|
+
}
|
|
3457
|
+
}
|
|
3458
|
+
return obj;
|
|
3459
|
+
},
|
|
3460
|
+
create(base) {
|
|
3461
|
+
return exports.DevlabSpec_Template.fromPartial(base ?? {});
|
|
3462
|
+
},
|
|
3463
|
+
fromPartial(object) {
|
|
3464
|
+
const message = createBaseDevlabSpec_Template();
|
|
3465
|
+
message.id = (object.id !== undefined && object.id !== null)
|
|
3466
|
+
? object.id
|
|
3467
|
+
: "";
|
|
3468
|
+
message.inputFieldValues = Object.entries(object.inputFieldValues ?? {}).reduce((acc, [key, value]) => {
|
|
3469
|
+
if (value !== undefined) {
|
|
3470
|
+
acc[key] = value;
|
|
3471
|
+
}
|
|
3472
|
+
return acc;
|
|
3473
|
+
}, {});
|
|
3474
|
+
return message;
|
|
3475
|
+
},
|
|
3476
|
+
};
|
|
3477
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabSpec_Template);
|
|
3478
|
+
function DevlabSpec_TemplateCustomInspect() {
|
|
3479
|
+
const parts = [];
|
|
3480
|
+
if (this.id !== "")
|
|
3481
|
+
parts.push("id" + "=" + (0, util_1.inspect)(this.id));
|
|
3482
|
+
if (Object.keys(this.inputFieldValues || {}).length)
|
|
3483
|
+
parts.push("inputFieldValues" + "=***");
|
|
3484
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
3485
|
+
}
|
|
3486
|
+
function DevlabSpec_TemplateCustomJson() {
|
|
3487
|
+
const obj = {
|
|
3488
|
+
type: this.$type,
|
|
3489
|
+
};
|
|
3490
|
+
if (this.id !== "")
|
|
3491
|
+
obj.id = (0, logging_js_1.inspectJson)(this.id);
|
|
3492
|
+
if (Object.keys(this.inputFieldValues || {}).length)
|
|
3493
|
+
obj.inputFieldValues = "***";
|
|
3494
|
+
return obj;
|
|
3495
|
+
}
|
|
3496
|
+
function applyDevlabSpec_TemplateCustom(message) {
|
|
3497
|
+
message[logging_js_1.custom] = DevlabSpec_TemplateCustomInspect;
|
|
3498
|
+
message[logging_js_1.customJson] = DevlabSpec_TemplateCustomJson;
|
|
3499
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabSpec_Template.$descriptor);
|
|
3500
|
+
}
|
|
3501
|
+
function createBaseDevlabSpec_Template() {
|
|
3502
|
+
const message = {
|
|
3503
|
+
$type: "nebius.ai.v1.DevlabSpec.Template",
|
|
3504
|
+
id: "",
|
|
3505
|
+
inputFieldValues: {},
|
|
3506
|
+
};
|
|
3507
|
+
return applyDevlabSpec_TemplateCustom(message);
|
|
3508
|
+
}
|
|
3509
|
+
const DevlabSpec_MysteryBoxSecretRef_MESSAGE_DESCRIPTOR = {
|
|
3510
|
+
fields: {
|
|
3511
|
+
"secretId": { pbName: "secret_id", scalarType: 9 },
|
|
3512
|
+
"versionId": { pbName: "version_id", scalarType: 9 },
|
|
3513
|
+
},
|
|
3514
|
+
};
|
|
3515
|
+
/** Encodes, decodes, converts, and creates {@link DevlabSpec_MysteryBoxSecretRef} messages. */
|
|
3516
|
+
exports.DevlabSpec_MysteryBoxSecretRef = {
|
|
3517
|
+
$type: "nebius.ai.v1.DevlabSpec.MysteryBoxSecretRef",
|
|
3518
|
+
$descriptor: DevlabSpec_MysteryBoxSecretRef_MESSAGE_DESCRIPTOR,
|
|
3519
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
3520
|
+
if (message.secretId !== "") {
|
|
3521
|
+
writer.uint32(10).string(message.secretId);
|
|
3522
|
+
}
|
|
3523
|
+
if (message.versionId !== "") {
|
|
3524
|
+
writer.uint32(18).string(message.versionId);
|
|
3525
|
+
}
|
|
3526
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
3527
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
3528
|
+
}
|
|
3529
|
+
return writer;
|
|
3530
|
+
},
|
|
3531
|
+
decode(input, length) {
|
|
3532
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
3533
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
3534
|
+
const message = createBaseDevlabSpec_MysteryBoxSecretRef();
|
|
3535
|
+
let writer = undefined;
|
|
3536
|
+
while (reader.pos < end) {
|
|
3537
|
+
const tag = reader.uint32();
|
|
3538
|
+
switch (tag >>> 3) {
|
|
3539
|
+
case 1: {
|
|
3540
|
+
if (tag !== 10)
|
|
3541
|
+
break;
|
|
3542
|
+
message.secretId = reader.string();
|
|
3543
|
+
continue;
|
|
3544
|
+
}
|
|
3545
|
+
case 2: {
|
|
3546
|
+
if (tag !== 18)
|
|
3547
|
+
break;
|
|
3548
|
+
message.versionId = reader.string();
|
|
3549
|
+
continue;
|
|
3550
|
+
}
|
|
3551
|
+
default:
|
|
3552
|
+
break;
|
|
3553
|
+
}
|
|
3554
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
3555
|
+
break;
|
|
3556
|
+
}
|
|
3557
|
+
{
|
|
3558
|
+
if (!writer)
|
|
3559
|
+
writer = new index_js_1.BinaryWriter();
|
|
3560
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
3561
|
+
writer.uint32(tag).raw(skipped);
|
|
3562
|
+
}
|
|
3563
|
+
}
|
|
3564
|
+
if (writer) {
|
|
3565
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
3566
|
+
}
|
|
3567
|
+
return message;
|
|
3568
|
+
},
|
|
3569
|
+
fromJSON(object) {
|
|
3570
|
+
return applyDevlabSpec_MysteryBoxSecretRefCustom({
|
|
3571
|
+
$type: "nebius.ai.v1.DevlabSpec.MysteryBoxSecretRef",
|
|
3572
|
+
secretId: (0, index_js_1.isSet)(object.secretId ?? object.secret_id)
|
|
3573
|
+
? String(object.secretId ?? object.secret_id)
|
|
3574
|
+
: "",
|
|
3575
|
+
versionId: (0, index_js_1.isSet)(object.versionId ?? object.version_id)
|
|
3576
|
+
? String(object.versionId ?? object.version_id)
|
|
3577
|
+
: "",
|
|
3578
|
+
});
|
|
3579
|
+
},
|
|
3580
|
+
toJSON(message, use = "json") {
|
|
3581
|
+
const obj = {};
|
|
3582
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
3583
|
+
if (message.secretId !== "") {
|
|
3584
|
+
obj[pick("secretId", "secret_id")] = message.secretId;
|
|
3585
|
+
}
|
|
3586
|
+
if (message.versionId !== "") {
|
|
3587
|
+
obj[pick("versionId", "version_id")] = message.versionId;
|
|
3588
|
+
}
|
|
3589
|
+
return obj;
|
|
3590
|
+
},
|
|
3591
|
+
create(base) {
|
|
3592
|
+
return exports.DevlabSpec_MysteryBoxSecretRef.fromPartial(base ?? {});
|
|
3593
|
+
},
|
|
3594
|
+
fromPartial(object) {
|
|
3595
|
+
const message = createBaseDevlabSpec_MysteryBoxSecretRef();
|
|
3596
|
+
message.secretId = (object.secretId !== undefined && object.secretId !== null)
|
|
3597
|
+
? object.secretId
|
|
3598
|
+
: "";
|
|
3599
|
+
message.versionId = (object.versionId !== undefined && object.versionId !== null)
|
|
3600
|
+
? object.versionId
|
|
3601
|
+
: "";
|
|
3602
|
+
return message;
|
|
3603
|
+
},
|
|
3604
|
+
};
|
|
3605
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabSpec_MysteryBoxSecretRef);
|
|
3606
|
+
function DevlabSpec_MysteryBoxSecretRefCustomInspect() {
|
|
3607
|
+
const parts = [];
|
|
3608
|
+
if (this.secretId !== "")
|
|
3609
|
+
parts.push("secretId" + "=" + (0, util_1.inspect)(this.secretId));
|
|
3610
|
+
if (this.versionId !== "")
|
|
3611
|
+
parts.push("versionId" + "=" + (0, util_1.inspect)(this.versionId));
|
|
3612
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
3613
|
+
}
|
|
3614
|
+
function DevlabSpec_MysteryBoxSecretRefCustomJson() {
|
|
3615
|
+
const obj = {
|
|
3616
|
+
type: this.$type,
|
|
3617
|
+
};
|
|
3618
|
+
if (this.secretId !== "")
|
|
3619
|
+
obj.secretId = (0, logging_js_1.inspectJson)(this.secretId);
|
|
3620
|
+
if (this.versionId !== "")
|
|
3621
|
+
obj.versionId = (0, logging_js_1.inspectJson)(this.versionId);
|
|
3622
|
+
return obj;
|
|
3623
|
+
}
|
|
3624
|
+
function applyDevlabSpec_MysteryBoxSecretRefCustom(message) {
|
|
3625
|
+
message[logging_js_1.custom] = DevlabSpec_MysteryBoxSecretRefCustomInspect;
|
|
3626
|
+
message[logging_js_1.customJson] = DevlabSpec_MysteryBoxSecretRefCustomJson;
|
|
3627
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabSpec_MysteryBoxSecretRef.$descriptor);
|
|
3628
|
+
}
|
|
3629
|
+
function createBaseDevlabSpec_MysteryBoxSecretRef() {
|
|
3630
|
+
const message = {
|
|
3631
|
+
$type: "nebius.ai.v1.DevlabSpec.MysteryBoxSecretRef",
|
|
3632
|
+
secretId: "",
|
|
3633
|
+
versionId: "",
|
|
3634
|
+
};
|
|
3635
|
+
return applyDevlabSpec_MysteryBoxSecretRefCustom(message);
|
|
3636
|
+
}
|
|
3637
|
+
const DevlabStatus_MESSAGE_DESCRIPTOR = {
|
|
3638
|
+
fields: {
|
|
3639
|
+
"privateEndpoints": { pbName: "private_endpoints", scalarType: 9, repeated: true },
|
|
3640
|
+
"publicEndpoints": { pbName: "public_endpoints", scalarType: 9, repeated: true },
|
|
3641
|
+
"instances": { pbName: "instances", repeated: true, message: () => exports.DevlabInstanceStatus.$descriptor },
|
|
3642
|
+
"state": { pbName: "state", scalarType: 14 },
|
|
3643
|
+
"stateDetails": { pbName: "state_details", message: () => exports.DevlabStateDetails.$descriptor },
|
|
3644
|
+
},
|
|
3645
|
+
};
|
|
3646
|
+
/** Encodes, decodes, converts, and creates {@link DevlabStatus} messages. */
|
|
3647
|
+
exports.DevlabStatus = {
|
|
3648
|
+
$type: "nebius.ai.v1.DevlabStatus",
|
|
3649
|
+
$descriptor: DevlabStatus_MESSAGE_DESCRIPTOR,
|
|
3650
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
3651
|
+
for (const v of (message.privateEndpoints ?? [])) {
|
|
3652
|
+
writer.uint32(10).string(v);
|
|
3653
|
+
}
|
|
3654
|
+
for (const v of (message.publicEndpoints ?? [])) {
|
|
3655
|
+
writer.uint32(18).string(v);
|
|
3656
|
+
}
|
|
3657
|
+
for (const v of (message.instances ?? [])) {
|
|
3658
|
+
const w = writer.uint32(82).fork();
|
|
3659
|
+
exports.DevlabInstanceStatus.encode(v, w);
|
|
3660
|
+
w.join();
|
|
3661
|
+
}
|
|
3662
|
+
if ((message.state ?? exports.DevlabStatus_State.STATE_UNSPECIFIED) !== exports.DevlabStatus_State.STATE_UNSPECIFIED) {
|
|
3663
|
+
exports.DevlabStatus_State.encodeField(writer, 20, message.state);
|
|
3664
|
+
}
|
|
3665
|
+
if (message.stateDetails !== undefined) {
|
|
3666
|
+
const w = writer.uint32(170).fork();
|
|
3667
|
+
exports.DevlabStateDetails.encode(message.stateDetails, w);
|
|
3668
|
+
w.join();
|
|
3669
|
+
}
|
|
3670
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
3671
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
3672
|
+
}
|
|
3673
|
+
return writer;
|
|
3674
|
+
},
|
|
3675
|
+
decode(input, length) {
|
|
3676
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
3677
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
3678
|
+
const message = createBaseDevlabStatus();
|
|
3679
|
+
let writer = undefined;
|
|
3680
|
+
while (reader.pos < end) {
|
|
3681
|
+
const tag = reader.uint32();
|
|
3682
|
+
switch (tag >>> 3) {
|
|
3683
|
+
case 1: {
|
|
3684
|
+
if (tag !== 10)
|
|
3685
|
+
break;
|
|
3686
|
+
message.privateEndpoints.push(reader.string());
|
|
3687
|
+
continue;
|
|
3688
|
+
}
|
|
3689
|
+
case 2: {
|
|
3690
|
+
if (tag !== 18)
|
|
3691
|
+
break;
|
|
3692
|
+
message.publicEndpoints.push(reader.string());
|
|
3693
|
+
continue;
|
|
3694
|
+
}
|
|
3695
|
+
case 10: {
|
|
3696
|
+
if (tag !== 82)
|
|
3697
|
+
break;
|
|
3698
|
+
message.instances.push(exports.DevlabInstanceStatus.decode(reader, reader.uint32()));
|
|
3699
|
+
continue;
|
|
3700
|
+
}
|
|
3701
|
+
case 20: {
|
|
3702
|
+
if (tag !== 160)
|
|
3703
|
+
break;
|
|
3704
|
+
message.state = exports.DevlabStatus_State.fromNumber(reader.int32());
|
|
3705
|
+
continue;
|
|
3706
|
+
}
|
|
3707
|
+
case 21: {
|
|
3708
|
+
if (tag !== 170)
|
|
3709
|
+
break;
|
|
3710
|
+
message.stateDetails = exports.DevlabStateDetails.decode(reader, reader.uint32());
|
|
3711
|
+
continue;
|
|
3712
|
+
}
|
|
3713
|
+
default:
|
|
3714
|
+
break;
|
|
3715
|
+
}
|
|
3716
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
3717
|
+
break;
|
|
3718
|
+
}
|
|
3719
|
+
{
|
|
3720
|
+
if (!writer)
|
|
3721
|
+
writer = new index_js_1.BinaryWriter();
|
|
3722
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
3723
|
+
writer.uint32(tag).raw(skipped);
|
|
3724
|
+
}
|
|
3725
|
+
}
|
|
3726
|
+
if (writer) {
|
|
3727
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
3728
|
+
}
|
|
3729
|
+
return message;
|
|
3730
|
+
},
|
|
3731
|
+
fromJSON(object) {
|
|
3732
|
+
return applyDevlabStatusCustom({
|
|
3733
|
+
$type: "nebius.ai.v1.DevlabStatus",
|
|
3734
|
+
privateEndpoints: globalThis.Array.isArray(object?.privateEndpoints ?? object?.private_endpoints)
|
|
3735
|
+
? (object.privateEndpoints ?? object.private_endpoints).map((e) => String(e))
|
|
3736
|
+
: [],
|
|
3737
|
+
publicEndpoints: globalThis.Array.isArray(object?.publicEndpoints ?? object?.public_endpoints)
|
|
3738
|
+
? (object.publicEndpoints ?? object.public_endpoints).map((e) => String(e))
|
|
3739
|
+
: [],
|
|
3740
|
+
instances: globalThis.Array.isArray(object?.instances ?? object?.instances)
|
|
3741
|
+
? (object.instances ?? object.instances).map((e) => exports.DevlabInstanceStatus.fromJSON(e))
|
|
3742
|
+
: [],
|
|
3743
|
+
state: (0, index_js_1.isSet)(object.state ?? object.state)
|
|
3744
|
+
? exports.DevlabStatus_State.fromJSON(object.state ?? object.state)
|
|
3745
|
+
: exports.DevlabStatus_State.STATE_UNSPECIFIED,
|
|
3746
|
+
stateDetails: (0, index_js_1.isSet)(object.stateDetails ?? object.state_details)
|
|
3747
|
+
? exports.DevlabStateDetails.fromJSON(object.stateDetails ?? object.state_details)
|
|
3748
|
+
: undefined,
|
|
3749
|
+
});
|
|
3750
|
+
},
|
|
3751
|
+
toJSON(message, use = "json") {
|
|
3752
|
+
const obj = {};
|
|
3753
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
3754
|
+
if (message.privateEndpoints?.length) {
|
|
3755
|
+
obj[pick("privateEndpoints", "private_endpoints")] = message.privateEndpoints.map((e) => e);
|
|
3756
|
+
}
|
|
3757
|
+
if (message.publicEndpoints?.length) {
|
|
3758
|
+
obj[pick("publicEndpoints", "public_endpoints")] = message.publicEndpoints.map((e) => e);
|
|
3759
|
+
}
|
|
3760
|
+
if (message.instances?.length) {
|
|
3761
|
+
obj[pick("instances", "instances")] = message.instances.map((e) => e ? exports.DevlabInstanceStatus.toJSON(e, use) : undefined);
|
|
3762
|
+
}
|
|
3763
|
+
if ((message.state ?? exports.DevlabStatus_State.STATE_UNSPECIFIED) !== exports.DevlabStatus_State.STATE_UNSPECIFIED) {
|
|
3764
|
+
obj[pick("state", "state")] = exports.DevlabStatus_State.toJSON(message.state);
|
|
3765
|
+
}
|
|
3766
|
+
if (message.stateDetails !== undefined) {
|
|
3767
|
+
obj[pick("stateDetails", "state_details")] = message.stateDetails
|
|
3768
|
+
? exports.DevlabStateDetails.toJSON(message.stateDetails, use)
|
|
3769
|
+
: undefined;
|
|
3770
|
+
}
|
|
3771
|
+
return obj;
|
|
3772
|
+
},
|
|
3773
|
+
create(base) {
|
|
3774
|
+
return exports.DevlabStatus.fromPartial(base ?? {});
|
|
3775
|
+
},
|
|
3776
|
+
fromPartial(object) {
|
|
3777
|
+
const message = createBaseDevlabStatus();
|
|
3778
|
+
message.privateEndpoints = object.privateEndpoints?.map((e) => e) || [];
|
|
3779
|
+
message.publicEndpoints = object.publicEndpoints?.map((e) => e) || [];
|
|
3780
|
+
message.instances = object.instances?.map((e) => exports.DevlabInstanceStatus.fromPartial(e)) || [];
|
|
3781
|
+
message.state = (object.state !== undefined && object.state !== null)
|
|
3782
|
+
? exports.DevlabStatus_State.fromJSON(object.state.name)
|
|
3783
|
+
: exports.DevlabStatus_State.STATE_UNSPECIFIED;
|
|
3784
|
+
message.stateDetails = (object.stateDetails !== undefined && object.stateDetails !== null)
|
|
3785
|
+
? exports.DevlabStateDetails.fromPartial(object.stateDetails)
|
|
3786
|
+
: undefined;
|
|
3787
|
+
return message;
|
|
3788
|
+
},
|
|
3789
|
+
};
|
|
3790
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabStatus);
|
|
3791
|
+
function DevlabStatusCustomInspect() {
|
|
3792
|
+
const parts = [];
|
|
3793
|
+
if ((this.privateEndpoints?.length ?? 0) !== 0)
|
|
3794
|
+
parts.push("privateEndpoints" + "=" + (0, util_1.inspect)(this.privateEndpoints));
|
|
3795
|
+
if ((this.publicEndpoints?.length ?? 0) !== 0)
|
|
3796
|
+
parts.push("publicEndpoints" + "=" + (0, util_1.inspect)(this.publicEndpoints));
|
|
3797
|
+
if ((this.instances?.length ?? 0) !== 0)
|
|
3798
|
+
parts.push("instances" + "=" + (0, util_1.inspect)(this.instances));
|
|
3799
|
+
if (this.state !== undefined)
|
|
3800
|
+
parts.push("state" + "=" + (0, util_1.inspect)(this.state));
|
|
3801
|
+
if (this.stateDetails !== undefined)
|
|
3802
|
+
parts.push("stateDetails" + "=" + (0, util_1.inspect)(this.stateDetails));
|
|
3803
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
3804
|
+
}
|
|
3805
|
+
function DevlabStatusCustomJson() {
|
|
3806
|
+
const obj = {
|
|
3807
|
+
type: this.$type,
|
|
3808
|
+
};
|
|
3809
|
+
if ((this.privateEndpoints?.length ?? 0) !== 0)
|
|
3810
|
+
obj.privateEndpoints = (0, logging_js_1.inspectJson)(this.privateEndpoints);
|
|
3811
|
+
if ((this.publicEndpoints?.length ?? 0) !== 0)
|
|
3812
|
+
obj.publicEndpoints = (0, logging_js_1.inspectJson)(this.publicEndpoints);
|
|
3813
|
+
if ((this.instances?.length ?? 0) !== 0)
|
|
3814
|
+
obj.instances = (0, logging_js_1.inspectJson)(this.instances);
|
|
3815
|
+
if (this.state !== undefined)
|
|
3816
|
+
obj.state = (0, logging_js_1.inspectJson)(this.state);
|
|
3817
|
+
if (this.stateDetails !== undefined)
|
|
3818
|
+
obj.stateDetails = (0, logging_js_1.inspectJson)(this.stateDetails);
|
|
3819
|
+
return obj;
|
|
3820
|
+
}
|
|
3821
|
+
function applyDevlabStatusCustom(message) {
|
|
3822
|
+
message[logging_js_1.custom] = DevlabStatusCustomInspect;
|
|
3823
|
+
message[logging_js_1.customJson] = DevlabStatusCustomJson;
|
|
3824
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabStatus.$descriptor);
|
|
3825
|
+
}
|
|
3826
|
+
function createBaseDevlabStatus() {
|
|
3827
|
+
const message = {
|
|
3828
|
+
$type: "nebius.ai.v1.DevlabStatus",
|
|
3829
|
+
privateEndpoints: [],
|
|
3830
|
+
publicEndpoints: [],
|
|
3831
|
+
instances: [],
|
|
3832
|
+
state: exports.DevlabStatus_State.STATE_UNSPECIFIED,
|
|
3833
|
+
stateDetails: undefined,
|
|
3834
|
+
};
|
|
3835
|
+
return applyDevlabStatusCustom(message);
|
|
3836
|
+
}
|
|
3837
|
+
const DevlabStateDetails_MESSAGE_DESCRIPTOR = {
|
|
3838
|
+
fields: {
|
|
3839
|
+
"code": { pbName: "code", scalarType: 9 },
|
|
3840
|
+
"message": { pbName: "message", scalarType: 9 },
|
|
3841
|
+
},
|
|
3842
|
+
};
|
|
3843
|
+
/** Encodes, decodes, converts, and creates {@link DevlabStateDetails} messages. */
|
|
3844
|
+
exports.DevlabStateDetails = {
|
|
3845
|
+
$type: "nebius.ai.v1.DevlabStateDetails",
|
|
3846
|
+
$descriptor: DevlabStateDetails_MESSAGE_DESCRIPTOR,
|
|
3847
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
3848
|
+
if (message.code !== "") {
|
|
3849
|
+
writer.uint32(10).string(message.code);
|
|
3850
|
+
}
|
|
3851
|
+
if (message.message !== "") {
|
|
3852
|
+
writer.uint32(18).string(message.message);
|
|
3853
|
+
}
|
|
3854
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
3855
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
3856
|
+
}
|
|
3857
|
+
return writer;
|
|
3858
|
+
},
|
|
3859
|
+
decode(input, length) {
|
|
3860
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
3861
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
3862
|
+
const message = createBaseDevlabStateDetails();
|
|
3863
|
+
let writer = undefined;
|
|
3864
|
+
while (reader.pos < end) {
|
|
3865
|
+
const tag = reader.uint32();
|
|
3866
|
+
switch (tag >>> 3) {
|
|
3867
|
+
case 1: {
|
|
3868
|
+
if (tag !== 10)
|
|
3869
|
+
break;
|
|
3870
|
+
message.code = reader.string();
|
|
3871
|
+
continue;
|
|
3872
|
+
}
|
|
3873
|
+
case 2: {
|
|
3874
|
+
if (tag !== 18)
|
|
3875
|
+
break;
|
|
3876
|
+
message.message = reader.string();
|
|
3877
|
+
continue;
|
|
3878
|
+
}
|
|
3879
|
+
default:
|
|
3880
|
+
break;
|
|
3881
|
+
}
|
|
3882
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
3883
|
+
break;
|
|
3884
|
+
}
|
|
3885
|
+
{
|
|
3886
|
+
if (!writer)
|
|
3887
|
+
writer = new index_js_1.BinaryWriter();
|
|
3888
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
3889
|
+
writer.uint32(tag).raw(skipped);
|
|
3890
|
+
}
|
|
3891
|
+
}
|
|
3892
|
+
if (writer) {
|
|
3893
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
3894
|
+
}
|
|
3895
|
+
return message;
|
|
3896
|
+
},
|
|
3897
|
+
fromJSON(object) {
|
|
3898
|
+
return applyDevlabStateDetailsCustom({
|
|
3899
|
+
$type: "nebius.ai.v1.DevlabStateDetails",
|
|
3900
|
+
code: (0, index_js_1.isSet)(object.code ?? object.code)
|
|
3901
|
+
? String(object.code ?? object.code)
|
|
3902
|
+
: "",
|
|
3903
|
+
message: (0, index_js_1.isSet)(object.message ?? object.message)
|
|
3904
|
+
? String(object.message ?? object.message)
|
|
3905
|
+
: "",
|
|
3906
|
+
});
|
|
3907
|
+
},
|
|
3908
|
+
toJSON(message, use = "json") {
|
|
3909
|
+
const obj = {};
|
|
3910
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
3911
|
+
if (message.code !== "") {
|
|
3912
|
+
obj[pick("code", "code")] = message.code;
|
|
3913
|
+
}
|
|
3914
|
+
if (message.message !== "") {
|
|
3915
|
+
obj[pick("message", "message")] = message.message;
|
|
3916
|
+
}
|
|
3917
|
+
return obj;
|
|
3918
|
+
},
|
|
3919
|
+
create(base) {
|
|
3920
|
+
return exports.DevlabStateDetails.fromPartial(base ?? {});
|
|
3921
|
+
},
|
|
3922
|
+
fromPartial(object) {
|
|
3923
|
+
const message = createBaseDevlabStateDetails();
|
|
3924
|
+
message.code = (object.code !== undefined && object.code !== null)
|
|
3925
|
+
? object.code
|
|
3926
|
+
: "";
|
|
3927
|
+
message.message = (object.message !== undefined && object.message !== null)
|
|
3928
|
+
? object.message
|
|
3929
|
+
: "";
|
|
3930
|
+
return message;
|
|
3931
|
+
},
|
|
3932
|
+
};
|
|
3933
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabStateDetails);
|
|
3934
|
+
function DevlabStateDetailsCustomInspect() {
|
|
3935
|
+
const parts = [];
|
|
3936
|
+
if (this.code !== "")
|
|
3937
|
+
parts.push("code" + "=" + (0, util_1.inspect)(this.code));
|
|
3938
|
+
if (this.message !== "")
|
|
3939
|
+
parts.push("message" + "=" + (0, util_1.inspect)(this.message));
|
|
3940
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
3941
|
+
}
|
|
3942
|
+
function DevlabStateDetailsCustomJson() {
|
|
3943
|
+
const obj = {
|
|
3944
|
+
type: this.$type,
|
|
3945
|
+
};
|
|
3946
|
+
if (this.code !== "")
|
|
3947
|
+
obj.code = (0, logging_js_1.inspectJson)(this.code);
|
|
3948
|
+
if (this.message !== "")
|
|
3949
|
+
obj.message = (0, logging_js_1.inspectJson)(this.message);
|
|
3950
|
+
return obj;
|
|
3951
|
+
}
|
|
3952
|
+
function applyDevlabStateDetailsCustom(message) {
|
|
3953
|
+
message[logging_js_1.custom] = DevlabStateDetailsCustomInspect;
|
|
3954
|
+
message[logging_js_1.customJson] = DevlabStateDetailsCustomJson;
|
|
3955
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabStateDetails.$descriptor);
|
|
3956
|
+
}
|
|
3957
|
+
function createBaseDevlabStateDetails() {
|
|
3958
|
+
const message = {
|
|
3959
|
+
$type: "nebius.ai.v1.DevlabStateDetails",
|
|
3960
|
+
code: "",
|
|
3961
|
+
message: "",
|
|
3962
|
+
};
|
|
3963
|
+
return applyDevlabStateDetailsCustom(message);
|
|
3964
|
+
}
|
|
3965
|
+
const DevlabInstanceStatus_MESSAGE_DESCRIPTOR = {
|
|
3966
|
+
fields: {
|
|
3967
|
+
"state": { pbName: "state", scalarType: 14 },
|
|
3968
|
+
"computeInstanceId": { pbName: "compute_instance_id", scalarType: 9 },
|
|
3969
|
+
"computeInstanceState": { pbName: "compute_instance_state", scalarType: 14 },
|
|
3970
|
+
"privateIp": { pbName: "private_ip", scalarType: 9 },
|
|
3971
|
+
"publicIp": { pbName: "public_ip", scalarType: 9 },
|
|
3972
|
+
},
|
|
3973
|
+
};
|
|
3974
|
+
/** Encodes, decodes, converts, and creates {@link DevlabInstanceStatus} messages. */
|
|
3975
|
+
exports.DevlabInstanceStatus = {
|
|
3976
|
+
$type: "nebius.ai.v1.DevlabInstanceStatus",
|
|
3977
|
+
$descriptor: DevlabInstanceStatus_MESSAGE_DESCRIPTOR,
|
|
3978
|
+
encode(message, writer = new index_js_1.BinaryWriter()) {
|
|
3979
|
+
if ((message.state ?? exports.DevlabInstanceStatus_State.STATE_UNSPECIFIED) !== exports.DevlabInstanceStatus_State.STATE_UNSPECIFIED) {
|
|
3980
|
+
exports.DevlabInstanceStatus_State.encodeField(writer, 1, message.state);
|
|
3981
|
+
}
|
|
3982
|
+
if (message.computeInstanceId !== "") {
|
|
3983
|
+
writer.uint32(82).string(message.computeInstanceId);
|
|
3984
|
+
}
|
|
3985
|
+
if ((message.computeInstanceState ?? index_js_3.InstanceStatus_InstanceState.UNSPECIFIED) !== index_js_3.InstanceStatus_InstanceState.UNSPECIFIED) {
|
|
3986
|
+
index_js_3.InstanceStatus_InstanceState.encodeField(writer, 11, message.computeInstanceState);
|
|
3987
|
+
}
|
|
3988
|
+
if (message.privateIp !== "") {
|
|
3989
|
+
writer.uint32(98).string(message.privateIp);
|
|
3990
|
+
}
|
|
3991
|
+
if (message.publicIp !== "") {
|
|
3992
|
+
writer.uint32(106).string(message.publicIp);
|
|
3993
|
+
}
|
|
3994
|
+
if (message[index_js_1.unknownFieldsSymbol]) {
|
|
3995
|
+
writer.raw(message[index_js_1.unknownFieldsSymbol]);
|
|
3996
|
+
}
|
|
3997
|
+
return writer;
|
|
3998
|
+
},
|
|
3999
|
+
decode(input, length) {
|
|
4000
|
+
const reader = input instanceof index_js_1.BinaryReader ? input : new index_js_1.BinaryReader(input);
|
|
4001
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
4002
|
+
const message = createBaseDevlabInstanceStatus();
|
|
4003
|
+
let writer = undefined;
|
|
4004
|
+
while (reader.pos < end) {
|
|
4005
|
+
const tag = reader.uint32();
|
|
4006
|
+
switch (tag >>> 3) {
|
|
4007
|
+
case 1: {
|
|
4008
|
+
if (tag !== 8)
|
|
4009
|
+
break;
|
|
4010
|
+
message.state = exports.DevlabInstanceStatus_State.fromNumber(reader.int32());
|
|
4011
|
+
continue;
|
|
4012
|
+
}
|
|
4013
|
+
case 10: {
|
|
4014
|
+
if (tag !== 82)
|
|
4015
|
+
break;
|
|
4016
|
+
message.computeInstanceId = reader.string();
|
|
4017
|
+
continue;
|
|
4018
|
+
}
|
|
4019
|
+
case 11: {
|
|
4020
|
+
if (tag !== 88)
|
|
4021
|
+
break;
|
|
4022
|
+
message.computeInstanceState = index_js_3.InstanceStatus_InstanceState.fromNumber(reader.int32());
|
|
4023
|
+
continue;
|
|
4024
|
+
}
|
|
4025
|
+
case 12: {
|
|
4026
|
+
if (tag !== 98)
|
|
4027
|
+
break;
|
|
4028
|
+
message.privateIp = reader.string();
|
|
4029
|
+
continue;
|
|
4030
|
+
}
|
|
4031
|
+
case 13: {
|
|
4032
|
+
if (tag !== 106)
|
|
4033
|
+
break;
|
|
4034
|
+
message.publicIp = reader.string();
|
|
4035
|
+
continue;
|
|
4036
|
+
}
|
|
4037
|
+
default:
|
|
4038
|
+
break;
|
|
4039
|
+
}
|
|
4040
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
4041
|
+
break;
|
|
4042
|
+
}
|
|
4043
|
+
{
|
|
4044
|
+
if (!writer)
|
|
4045
|
+
writer = new index_js_1.BinaryWriter();
|
|
4046
|
+
const skipped = reader.skip(tag & 7, tag >>> 3);
|
|
4047
|
+
writer.uint32(tag).raw(skipped);
|
|
4048
|
+
}
|
|
4049
|
+
}
|
|
4050
|
+
if (writer) {
|
|
4051
|
+
message[index_js_1.unknownFieldsSymbol] = writer.finish();
|
|
4052
|
+
}
|
|
4053
|
+
return message;
|
|
4054
|
+
},
|
|
4055
|
+
fromJSON(object) {
|
|
4056
|
+
return applyDevlabInstanceStatusCustom({
|
|
4057
|
+
$type: "nebius.ai.v1.DevlabInstanceStatus",
|
|
4058
|
+
state: (0, index_js_1.isSet)(object.state ?? object.state)
|
|
4059
|
+
? exports.DevlabInstanceStatus_State.fromJSON(object.state ?? object.state)
|
|
4060
|
+
: exports.DevlabInstanceStatus_State.STATE_UNSPECIFIED,
|
|
4061
|
+
computeInstanceId: (0, index_js_1.isSet)(object.computeInstanceId ?? object.compute_instance_id)
|
|
4062
|
+
? String(object.computeInstanceId ?? object.compute_instance_id)
|
|
4063
|
+
: "",
|
|
4064
|
+
computeInstanceState: (0, index_js_1.isSet)(object.computeInstanceState ?? object.compute_instance_state)
|
|
4065
|
+
? index_js_3.InstanceStatus_InstanceState.fromJSON(object.computeInstanceState ?? object.compute_instance_state)
|
|
4066
|
+
: index_js_3.InstanceStatus_InstanceState.UNSPECIFIED,
|
|
4067
|
+
privateIp: (0, index_js_1.isSet)(object.privateIp ?? object.private_ip)
|
|
4068
|
+
? String(object.privateIp ?? object.private_ip)
|
|
4069
|
+
: "",
|
|
4070
|
+
publicIp: (0, index_js_1.isSet)(object.publicIp ?? object.public_ip)
|
|
4071
|
+
? String(object.publicIp ?? object.public_ip)
|
|
4072
|
+
: "",
|
|
4073
|
+
});
|
|
4074
|
+
},
|
|
4075
|
+
toJSON(message, use = "json") {
|
|
4076
|
+
const obj = {};
|
|
4077
|
+
const pick = (json, pb) => (use === "json" ? json : pb);
|
|
4078
|
+
if ((message.state ?? exports.DevlabInstanceStatus_State.STATE_UNSPECIFIED) !== exports.DevlabInstanceStatus_State.STATE_UNSPECIFIED) {
|
|
4079
|
+
obj[pick("state", "state")] = exports.DevlabInstanceStatus_State.toJSON(message.state);
|
|
4080
|
+
}
|
|
4081
|
+
if (message.computeInstanceId !== "") {
|
|
4082
|
+
obj[pick("computeInstanceId", "compute_instance_id")] = message.computeInstanceId;
|
|
4083
|
+
}
|
|
4084
|
+
if ((message.computeInstanceState ?? index_js_3.InstanceStatus_InstanceState.UNSPECIFIED) !== index_js_3.InstanceStatus_InstanceState.UNSPECIFIED) {
|
|
4085
|
+
obj[pick("computeInstanceState", "compute_instance_state")] = index_js_3.InstanceStatus_InstanceState.toJSON(message.computeInstanceState);
|
|
4086
|
+
}
|
|
4087
|
+
if (message.privateIp !== "") {
|
|
4088
|
+
obj[pick("privateIp", "private_ip")] = message.privateIp;
|
|
4089
|
+
}
|
|
4090
|
+
if (message.publicIp !== "") {
|
|
4091
|
+
obj[pick("publicIp", "public_ip")] = message.publicIp;
|
|
4092
|
+
}
|
|
4093
|
+
return obj;
|
|
4094
|
+
},
|
|
4095
|
+
create(base) {
|
|
4096
|
+
return exports.DevlabInstanceStatus.fromPartial(base ?? {});
|
|
4097
|
+
},
|
|
4098
|
+
fromPartial(object) {
|
|
4099
|
+
const message = createBaseDevlabInstanceStatus();
|
|
4100
|
+
message.state = (object.state !== undefined && object.state !== null)
|
|
4101
|
+
? exports.DevlabInstanceStatus_State.fromJSON(object.state.name)
|
|
4102
|
+
: exports.DevlabInstanceStatus_State.STATE_UNSPECIFIED;
|
|
4103
|
+
message.computeInstanceId = (object.computeInstanceId !== undefined && object.computeInstanceId !== null)
|
|
4104
|
+
? object.computeInstanceId
|
|
4105
|
+
: "";
|
|
4106
|
+
message.computeInstanceState = (object.computeInstanceState !== undefined && object.computeInstanceState !== null)
|
|
4107
|
+
? index_js_3.InstanceStatus_InstanceState.fromJSON(object.computeInstanceState.name)
|
|
4108
|
+
: index_js_3.InstanceStatus_InstanceState.UNSPECIFIED;
|
|
4109
|
+
message.privateIp = (object.privateIp !== undefined && object.privateIp !== null)
|
|
4110
|
+
? object.privateIp
|
|
4111
|
+
: "";
|
|
4112
|
+
message.publicIp = (object.publicIp !== undefined && object.publicIp !== null)
|
|
4113
|
+
? object.publicIp
|
|
4114
|
+
: "";
|
|
4115
|
+
return message;
|
|
4116
|
+
},
|
|
4117
|
+
};
|
|
4118
|
+
protobuf_js_1.protoRegistry.registerMessage(exports.DevlabInstanceStatus);
|
|
4119
|
+
function DevlabInstanceStatusCustomInspect() {
|
|
4120
|
+
const parts = [];
|
|
4121
|
+
if (this.state !== undefined)
|
|
4122
|
+
parts.push("state" + "=" + (0, util_1.inspect)(this.state));
|
|
4123
|
+
if (this.computeInstanceId !== "")
|
|
4124
|
+
parts.push("computeInstanceId" + "=" + (0, util_1.inspect)(this.computeInstanceId));
|
|
4125
|
+
if (this.computeInstanceState !== undefined)
|
|
4126
|
+
parts.push("computeInstanceState" + "=" + (0, util_1.inspect)(this.computeInstanceState));
|
|
4127
|
+
if (this.privateIp !== "")
|
|
4128
|
+
parts.push("privateIp" + "=" + (0, util_1.inspect)(this.privateIp));
|
|
4129
|
+
if (this.publicIp !== "")
|
|
4130
|
+
parts.push("publicIp" + "=" + (0, util_1.inspect)(this.publicIp));
|
|
4131
|
+
return `${this.$type}(${parts.join(", ")})`;
|
|
4132
|
+
}
|
|
4133
|
+
function DevlabInstanceStatusCustomJson() {
|
|
4134
|
+
const obj = {
|
|
4135
|
+
type: this.$type,
|
|
4136
|
+
};
|
|
4137
|
+
if (this.state !== undefined)
|
|
4138
|
+
obj.state = (0, logging_js_1.inspectJson)(this.state);
|
|
4139
|
+
if (this.computeInstanceId !== "")
|
|
4140
|
+
obj.computeInstanceId = (0, logging_js_1.inspectJson)(this.computeInstanceId);
|
|
4141
|
+
if (this.computeInstanceState !== undefined)
|
|
4142
|
+
obj.computeInstanceState = (0, logging_js_1.inspectJson)(this.computeInstanceState);
|
|
4143
|
+
if (this.privateIp !== "")
|
|
4144
|
+
obj.privateIp = (0, logging_js_1.inspectJson)(this.privateIp);
|
|
4145
|
+
if (this.publicIp !== "")
|
|
4146
|
+
obj.publicIp = (0, logging_js_1.inspectJson)(this.publicIp);
|
|
4147
|
+
return obj;
|
|
4148
|
+
}
|
|
4149
|
+
function applyDevlabInstanceStatusCustom(message) {
|
|
4150
|
+
message[logging_js_1.custom] = DevlabInstanceStatusCustomInspect;
|
|
4151
|
+
message[logging_js_1.customJson] = DevlabInstanceStatusCustomJson;
|
|
4152
|
+
return (0, index_js_1.attachMessageDescriptor)(message, exports.DevlabInstanceStatus.$descriptor);
|
|
4153
|
+
}
|
|
4154
|
+
function createBaseDevlabInstanceStatus() {
|
|
4155
|
+
const message = {
|
|
4156
|
+
$type: "nebius.ai.v1.DevlabInstanceStatus",
|
|
4157
|
+
state: exports.DevlabInstanceStatus_State.STATE_UNSPECIFIED,
|
|
4158
|
+
computeInstanceId: "",
|
|
4159
|
+
computeInstanceState: index_js_3.InstanceStatus_InstanceState.UNSPECIFIED,
|
|
4160
|
+
privateIp: "",
|
|
4161
|
+
publicIp: "",
|
|
4162
|
+
};
|
|
4163
|
+
return applyDevlabInstanceStatusCustom(message);
|
|
4164
|
+
}
|
|
16
4165
|
/** Converts and creates {@link GetEndpointRequest_View} values. */
|
|
17
4166
|
exports.GetEndpointRequest_View = (0, index_js_1.createEnum)("nebius.ai.v1.GetEndpointRequest.View", {
|
|
18
4167
|
/**
|