@nosana/types 0.1.3 → 0.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Jobs/JobDefinition/args/expose.d.ts +34 -1
- package/dist/Jobs/JobDefinition/args/expose.js +11 -1
- package/dist/Jobs/JobDefinition/args/expose.js.map +1 -1
- package/dist/Jobs/JobDefinition/meta/index.d.ts +2 -1
- package/dist/Jobs/index.js +309 -118
- package/dist/Jobs/index.js.map +1 -1
- package/dist/Schemas/job.js +117 -0
- package/dist/Schemas/job.js.map +1 -1
- package/package.json +1 -1
|
@@ -39,6 +39,39 @@ export type UniqueExposedPorts = Array<ExposeBase> & tags.TagBase<{
|
|
|
39
39
|
`;
|
|
40
40
|
message: 'Exposed ports must be unique, number ports must not fall within any defined port range, and port ranges must not overlap or be adjacent.';
|
|
41
41
|
}>;
|
|
42
|
+
export declare const ServiceType: {
|
|
43
|
+
readonly WEB: "web";
|
|
44
|
+
readonly API: "api";
|
|
45
|
+
readonly WEBAPI: "webapi";
|
|
46
|
+
readonly WEBSOCKET: "websocket";
|
|
47
|
+
readonly NONE: "none";
|
|
48
|
+
};
|
|
49
|
+
export type ServiceType = typeof ServiceType[keyof typeof ServiceType];
|
|
50
|
+
export declare const HealthCheckType: {
|
|
51
|
+
readonly HTTP: "http";
|
|
52
|
+
readonly WEBSOCKET: "websocket";
|
|
53
|
+
};
|
|
54
|
+
export type HealthCheckType = typeof HealthCheckType[keyof typeof HealthCheckType];
|
|
55
|
+
export type HttpHealthCheck = {
|
|
56
|
+
type: typeof HealthCheckType.HTTP;
|
|
57
|
+
path: string;
|
|
58
|
+
method: 'GET' | 'POST' | 'PUT' | 'DELETE';
|
|
59
|
+
expected_status: number;
|
|
60
|
+
headers?: Record<string, string>;
|
|
61
|
+
body?: unknown;
|
|
62
|
+
continuous: boolean;
|
|
63
|
+
};
|
|
64
|
+
export type WebSocketHealthCheck = {
|
|
65
|
+
type: typeof HealthCheckType.WEBSOCKET;
|
|
66
|
+
expected_response: string;
|
|
67
|
+
continuous: boolean;
|
|
68
|
+
};
|
|
69
|
+
export type HealthCheck = HttpHealthCheck | WebSocketHealthCheck;
|
|
42
70
|
export type Port = number;
|
|
43
|
-
export type
|
|
71
|
+
export type ExposedPort = {
|
|
72
|
+
port: number;
|
|
73
|
+
type?: ServiceType;
|
|
74
|
+
health_checks?: HealthCheck[];
|
|
75
|
+
};
|
|
76
|
+
export type ExposeBase = Port | ExposedPort | LiteralString | SpreadMarker;
|
|
44
77
|
export type Expose = ExposeBase | UniqueExposedPorts;
|
|
@@ -1,2 +1,12 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export const ServiceType = {
|
|
2
|
+
WEB: 'web',
|
|
3
|
+
API: 'api',
|
|
4
|
+
WEBAPI: 'webapi',
|
|
5
|
+
WEBSOCKET: 'websocket',
|
|
6
|
+
NONE: 'none',
|
|
7
|
+
};
|
|
8
|
+
export const HealthCheckType = {
|
|
9
|
+
HTTP: 'http',
|
|
10
|
+
WEBSOCKET: 'websocket',
|
|
11
|
+
};
|
|
2
12
|
//# sourceMappingURL=expose.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"expose.js","sourceRoot":"","sources":["../../../../src/Jobs/JobDefinition/args/expose.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"expose.js","sourceRoot":"","sources":["../../../../src/Jobs/JobDefinition/args/expose.ts"],"names":[],"mappings":"AA4CA,MAAM,CAAC,MAAM,WAAW,GAAG;IACzB,GAAG,EAAE,KAAK;IACV,GAAG,EAAE,KAAK;IACV,MAAM,EAAE,QAAQ;IAChB,SAAS,EAAE,WAAW;IACtB,IAAI,EAAE,MAAM;CACJ,CAAC;AAKX,MAAM,CAAC,MAAM,eAAe,GAAG;IAC7B,IAAI,EAAE,MAAM;IACZ,SAAS,EAAE,WAAW;CACd,CAAC"}
|
package/dist/Jobs/index.js
CHANGED
|
@@ -49,7 +49,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
49
49
|
const value = input[key];
|
|
50
50
|
if (undefined === value)
|
|
51
51
|
return true;
|
|
52
|
-
return "string" === typeof value || "number" === typeof value;
|
|
52
|
+
return null !== value && (undefined === value || "string" === typeof value || "number" === typeof value || "object" === typeof value && null !== value && false === Array.isArray(value) && _io5(value, true && _exceptionable));
|
|
53
53
|
}); const _io5 = (input, _exceptionable = true) => Object.keys(input).every(key => {
|
|
54
54
|
const value = input[key];
|
|
55
55
|
if (undefined === value)
|
|
@@ -72,7 +72,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
72
72
|
if (undefined === value)
|
|
73
73
|
return true;
|
|
74
74
|
return "string" === typeof value;
|
|
75
|
-
}); const _io9 = (input, _exceptionable = true) => ("container/run" === input.type || "container/create-volume" === input.type) && "string" === typeof input.id && ("object" === typeof input.args && null !== input.args &&
|
|
75
|
+
}); const _io9 = (input, _exceptionable = true) => ("container/run" === input.type || "container/create-volume" === input.type) && "string" === typeof input.id && ("object" === typeof input.args && null !== input.args && _iu3(input.args, true && _exceptionable)) && (undefined === input.results || "object" === typeof input.results && null !== input.results && false === Array.isArray(input.results) && _io27(input.results, true && _exceptionable)) && (undefined === input.execution || "object" === typeof input.execution && null !== input.execution && false === Array.isArray(input.execution) && _iu4(input.execution, true && _exceptionable)) && (3 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
76
76
|
if (["type", "id", "args", "results", "execution"].some(prop => key === prop))
|
|
77
77
|
return true;
|
|
78
78
|
const value = input[key];
|
|
@@ -114,7 +114,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
114
114
|
}
|
|
115
115
|
}
|
|
116
116
|
return true;
|
|
117
|
-
})() && input.expose.every((elem, _index6) => null !== elem && undefined !== elem && ("number" === typeof elem || "string" === typeof elem && (typeof elem === "string" && /^%%(ops|global).[^%]+%%$/.test(elem)) || "object" === typeof elem && null !== elem &&
|
|
117
|
+
})() && input.expose.every((elem, _index6) => null !== elem && undefined !== elem && ("number" === typeof elem || "string" === typeof elem && (typeof elem === "string" && /^%%(ops|global).[^%]+%%$/.test(elem)) || "object" === typeof elem && null !== elem && _iu1(elem, true && _exceptionable)))) || "object" === typeof input.expose && null !== input.expose && _iu1(input.expose, true && _exceptionable)))) && (undefined === input.gpu || "boolean" === typeof input.gpu) && (undefined === input.work_dir || "string" === typeof input.work_dir) && (null !== input.entrypoint && (undefined === input.entrypoint || "string" === typeof input.entrypoint || Array.isArray(input.entrypoint) && input.entrypoint.every((elem, _index7) => "string" === typeof elem))) && (undefined === input.env || "object" === typeof input.env && null !== input.env && false === Array.isArray(input.env) && _io7(input.env, true && _exceptionable)) && (undefined === input.resources || Array.isArray(input.resources) && input.resources.every((elem, _index8) => null !== elem && undefined !== elem && ("__remove-if-empty__" === elem || "object" === typeof elem && null !== elem && _iu2(elem, true && _exceptionable)))) && (undefined === input.authentication || "object" === typeof input.authentication && null !== input.authentication && false === Array.isArray(input.authentication) && _io24(input.authentication, true && _exceptionable)) && (1 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
118
118
|
if (["image", "aliases", "cmd", "volumes", "expose", "gpu", "work_dir", "entrypoint", "env", "resources", "authentication"].some(prop => key === prop))
|
|
119
119
|
return true;
|
|
120
120
|
const value = input[key];
|
|
@@ -135,82 +135,108 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
135
135
|
if (undefined === value)
|
|
136
136
|
return true;
|
|
137
137
|
return false;
|
|
138
|
-
})); const _io13 = (input, _exceptionable = true) => "
|
|
138
|
+
})); const _io13 = (input, _exceptionable = true) => "number" === typeof input.port && (undefined === input.type || "api" === input.type || "web" === input.type || "websocket" === input.type || "webapi" === input.type || "none" === input.type) && (undefined === input.health_checks || Array.isArray(input.health_checks) && input.health_checks.every((elem, _index9) => "object" === typeof elem && null !== elem && _iu0(elem, true && _exceptionable))) && (1 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
139
|
+
if (["port", "type", "health_checks"].some(prop => key === prop))
|
|
140
|
+
return true;
|
|
141
|
+
const value = input[key];
|
|
142
|
+
if (undefined === value)
|
|
143
|
+
return true;
|
|
144
|
+
return false;
|
|
145
|
+
})); const _io14 = (input, _exceptionable = true) => "http" === input.type && "string" === typeof input.path && ("GET" === input.method || "POST" === input.method || "PUT" === input.method || "DELETE" === input.method) && "number" === typeof input.expected_status && (undefined === input.headers || "object" === typeof input.headers && null !== input.headers && false === Array.isArray(input.headers) && _io15(input.headers, true && _exceptionable)) && true && "boolean" === typeof input.continuous && (5 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
146
|
+
if (["type", "path", "method", "expected_status", "headers", "body", "continuous"].some(prop => key === prop))
|
|
147
|
+
return true;
|
|
148
|
+
const value = input[key];
|
|
149
|
+
if (undefined === value)
|
|
150
|
+
return true;
|
|
151
|
+
return false;
|
|
152
|
+
})); const _io15 = (input, _exceptionable = true) => Object.keys(input).every(key => {
|
|
153
|
+
const value = input[key];
|
|
154
|
+
if (undefined === value)
|
|
155
|
+
return true;
|
|
156
|
+
return "string" === typeof value;
|
|
157
|
+
}); const _io16 = (input, _exceptionable = true) => "websocket" === input.type && "string" === typeof input.expected_response && "boolean" === typeof input.continuous && (3 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
158
|
+
if (["type", "expected_response", "continuous"].some(prop => key === prop))
|
|
159
|
+
return true;
|
|
160
|
+
const value = input[key];
|
|
161
|
+
if (undefined === value)
|
|
162
|
+
return true;
|
|
163
|
+
return false;
|
|
164
|
+
})); const _io17 = (input, _exceptionable = true) => "S3" === input.type && "string" === typeof input.target && (undefined === input.url || "string" === typeof input.url) && (undefined === input.allowWrite || "boolean" === typeof input.allowWrite) && (undefined === input.files || Array.isArray(input.files) && input.files.every((elem, _index10) => "string" === typeof elem)) && (undefined === input.IAM || "object" === typeof input.IAM && null !== input.IAM && _io18(input.IAM, true && _exceptionable)) && (2 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
139
165
|
if (["type", "target", "url", "allowWrite", "files", "IAM"].some(prop => key === prop))
|
|
140
166
|
return true;
|
|
141
167
|
const value = input[key];
|
|
142
168
|
if (undefined === value)
|
|
143
169
|
return true;
|
|
144
170
|
return false;
|
|
145
|
-
})); const
|
|
171
|
+
})); const _io18 = (input, _exceptionable = true) => "string" === typeof input.REGION && "string" === typeof input.ACCESS_KEY_ID && "string" === typeof input.SECRET_ACCESS_KEY && (3 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
146
172
|
if (["REGION", "ACCESS_KEY_ID", "SECRET_ACCESS_KEY"].some(prop => key === prop))
|
|
147
173
|
return true;
|
|
148
174
|
const value = input[key];
|
|
149
175
|
if (undefined === value)
|
|
150
176
|
return true;
|
|
151
177
|
return false;
|
|
152
|
-
})); const
|
|
178
|
+
})); const _io19 = (input, _exceptionable = true) => "S3" === input.type && "string" === typeof input.target && "string" === typeof input.bucket && (undefined === input.url || "string" === typeof input.url) && (undefined === input.allowWrite || "boolean" === typeof input.allowWrite) && (undefined === input.IAM || "object" === typeof input.IAM && null !== input.IAM && _io18(input.IAM, true && _exceptionable)) && (3 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
153
179
|
if (["type", "target", "bucket", "url", "allowWrite", "IAM"].some(prop => key === prop))
|
|
154
180
|
return true;
|
|
155
181
|
const value = input[key];
|
|
156
182
|
if (undefined === value)
|
|
157
183
|
return true;
|
|
158
184
|
return false;
|
|
159
|
-
})); const
|
|
185
|
+
})); const _io20 = (input, _exceptionable = true) => "S3" === input.type && "string" === typeof input.target && (Array.isArray(input.buckets) && input.buckets.every((elem, _index11) => "object" === typeof elem && null !== elem && _io21(elem, true && _exceptionable))) && (undefined === input.url || "string" === typeof input.url) && (undefined === input.allowWrite || "boolean" === typeof input.allowWrite) && (undefined === input.IAM || "object" === typeof input.IAM && null !== input.IAM && _io18(input.IAM, true && _exceptionable)) && (3 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
160
186
|
if (["type", "target", "buckets", "url", "allowWrite", "IAM"].some(prop => key === prop))
|
|
161
187
|
return true;
|
|
162
188
|
const value = input[key];
|
|
163
189
|
if (undefined === value)
|
|
164
190
|
return true;
|
|
165
191
|
return false;
|
|
166
|
-
})); const
|
|
192
|
+
})); const _io21 = (input, _exceptionable = true) => "string" === typeof input.url && (undefined === input.files || Array.isArray(input.files) && input.files.every((elem, _index12) => "string" === typeof elem)) && (1 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
167
193
|
if (["url", "files"].some(prop => key === prop))
|
|
168
194
|
return true;
|
|
169
195
|
const value = input[key];
|
|
170
196
|
if (undefined === value)
|
|
171
197
|
return true;
|
|
172
198
|
return false;
|
|
173
|
-
})); const
|
|
199
|
+
})); const _io22 = (input, _exceptionable = true) => "HF" === input.type && "string" === typeof input.target && "string" === typeof input.repo && (undefined === input.revision || "string" === typeof input.revision) && (undefined === input.files || Array.isArray(input.files) && input.files.every((elem, _index13) => "string" === typeof elem)) && (undefined === input.accessToken || "string" === typeof input.accessToken) && (3 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
174
200
|
if (["type", "target", "repo", "revision", "files", "accessToken"].some(prop => key === prop))
|
|
175
201
|
return true;
|
|
176
202
|
const value = input[key];
|
|
177
203
|
if (undefined === value)
|
|
178
204
|
return true;
|
|
179
205
|
return false;
|
|
180
|
-
})); const
|
|
206
|
+
})); const _io23 = (input, _exceptionable = true) => "Ollama" === input.type && "string" === typeof input.model && (undefined === input.target || "string" === typeof input.target) && (2 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
181
207
|
if (["type", "model", "target"].some(prop => key === prop))
|
|
182
208
|
return true;
|
|
183
209
|
const value = input[key];
|
|
184
210
|
if (undefined === value)
|
|
185
211
|
return true;
|
|
186
212
|
return false;
|
|
187
|
-
})); const
|
|
213
|
+
})); const _io24 = (input, _exceptionable = true) => (undefined === input.docker || "object" === typeof input.docker && null !== input.docker && false === Array.isArray(input.docker) && _io25(input.docker, true && _exceptionable)) && (0 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
188
214
|
if (["docker"].some(prop => key === prop))
|
|
189
215
|
return true;
|
|
190
216
|
const value = input[key];
|
|
191
217
|
if (undefined === value)
|
|
192
218
|
return true;
|
|
193
219
|
return false;
|
|
194
|
-
})); const
|
|
220
|
+
})); const _io25 = (input, _exceptionable = true) => (undefined === input.username || "string" === typeof input.username) && (undefined === input.password || "string" === typeof input.password) && (undefined === input.email || "string" === typeof input.email) && (undefined === input.server || "string" === typeof input.server) && (0 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
195
221
|
if (["username", "password", "email", "server"].some(prop => key === prop))
|
|
196
222
|
return true;
|
|
197
223
|
const value = input[key];
|
|
198
224
|
if (undefined === value)
|
|
199
225
|
return true;
|
|
200
226
|
return false;
|
|
201
|
-
})); const
|
|
227
|
+
})); const _io26 = (input, _exceptionable = true) => "string" === typeof input.name && (1 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
202
228
|
if (["name"].some(prop => key === prop))
|
|
203
229
|
return true;
|
|
204
230
|
const value = input[key];
|
|
205
231
|
if (undefined === value)
|
|
206
232
|
return true;
|
|
207
233
|
return false;
|
|
208
|
-
})); const
|
|
234
|
+
})); const _io27 = (input, _exceptionable = true) => Object.keys(input).every(key => {
|
|
209
235
|
const value = input[key];
|
|
210
236
|
if (undefined === value)
|
|
211
237
|
return true;
|
|
212
|
-
return null !== value && undefined !== value && ("string" === typeof value || "object" === typeof value && null !== value &&
|
|
213
|
-
}); const
|
|
238
|
+
return null !== value && undefined !== value && ("string" === typeof value || "object" === typeof value && null !== value && _io28(value, true && _exceptionable));
|
|
239
|
+
}); const _io28 = (input, _exceptionable = true) => "string" === typeof input.regex && (Array.isArray(input.logType) && (Array.isArray(input.logType) && input.logType.length >= 1 && input.logType.length <= 4 && (() => {
|
|
214
240
|
const seen = new Set();
|
|
215
241
|
for (const v of input.logType) {
|
|
216
242
|
if (seen.has(v))
|
|
@@ -218,21 +244,21 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
218
244
|
seen.add(v);
|
|
219
245
|
}
|
|
220
246
|
return true;
|
|
221
|
-
})() && input.logType.every((elem,
|
|
247
|
+
})() && input.logType.every((elem, _index14) => "stdin" === elem || "stdout" === elem || "stderr" === elem || "nodeerr" === elem))) && (2 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
222
248
|
if (["regex", "logType"].some(prop => key === prop))
|
|
223
249
|
return true;
|
|
224
250
|
const value = input[key];
|
|
225
251
|
if (undefined === value)
|
|
226
252
|
return true;
|
|
227
253
|
return false;
|
|
228
|
-
})); const
|
|
254
|
+
})); const _io29 = (input, _exceptionable = true) => (undefined === input.group || "string" === typeof input.group) && (null !== input.depends_on && undefined === input.depends_on) && (null !== input.stop_if_dependent_stops && undefined === input.stop_if_dependent_stops) && (0 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
229
255
|
if (["group", "depends_on", "stop_if_dependent_stops"].some(prop => key === prop))
|
|
230
256
|
return true;
|
|
231
257
|
const value = input[key];
|
|
232
258
|
if (undefined === value)
|
|
233
259
|
return true;
|
|
234
260
|
return false;
|
|
235
|
-
})); const
|
|
261
|
+
})); const _io30 = (input, _exceptionable = true) => (undefined === input.group || "string" === typeof input.group) && (Array.isArray(input.depends_on) && input.depends_on.every((elem, _index15) => "string" === typeof elem)) && (undefined === input.stop_if_dependent_stops || "boolean" === typeof input.stop_if_dependent_stops) && (1 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
236
262
|
if (["group", "depends_on", "stop_if_dependent_stops"].some(prop => key === prop))
|
|
237
263
|
return true;
|
|
238
264
|
const value = input[key];
|
|
@@ -240,30 +266,44 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
240
266
|
return true;
|
|
241
267
|
return false;
|
|
242
268
|
})); const _iu0 = (input, _exceptionable = true) => (() => {
|
|
269
|
+
if ("http" === input.type)
|
|
270
|
+
return _io14(input, true && _exceptionable);
|
|
271
|
+
else if ("websocket" === input.type)
|
|
272
|
+
return _io16(input, true && _exceptionable);
|
|
273
|
+
else
|
|
274
|
+
return false;
|
|
275
|
+
})(); const _iu1 = (input, _exceptionable = true) => (() => {
|
|
276
|
+
if (undefined !== input.__spread__)
|
|
277
|
+
return _io12(input, true && _exceptionable);
|
|
278
|
+
else if (undefined !== input.port)
|
|
279
|
+
return _io13(input, true && _exceptionable);
|
|
280
|
+
else
|
|
281
|
+
return false;
|
|
282
|
+
})(); const _iu2 = (input, _exceptionable = true) => (() => {
|
|
243
283
|
if (undefined !== input.__spread__)
|
|
244
284
|
return _io12(input, true && _exceptionable);
|
|
245
285
|
else if (undefined !== input.bucket)
|
|
246
|
-
return
|
|
286
|
+
return _io19(input, true && _exceptionable);
|
|
247
287
|
else if (undefined !== input.buckets)
|
|
248
|
-
return
|
|
288
|
+
return _io20(input, true && _exceptionable);
|
|
249
289
|
else if ("HF" === input.type)
|
|
250
|
-
return
|
|
290
|
+
return _io22(input, true && _exceptionable);
|
|
251
291
|
else if ("Ollama" === input.type)
|
|
252
|
-
return
|
|
292
|
+
return _io23(input, true && _exceptionable);
|
|
253
293
|
else
|
|
254
|
-
return
|
|
255
|
-
})(); const
|
|
294
|
+
return _io17(input, true && _exceptionable);
|
|
295
|
+
})(); const _iu3 = (input, _exceptionable = true) => (() => {
|
|
256
296
|
if (undefined !== input.image)
|
|
257
297
|
return _io10(input, true && _exceptionable);
|
|
258
298
|
else if (undefined !== input.name)
|
|
259
|
-
return
|
|
299
|
+
return _io26(input, true && _exceptionable);
|
|
260
300
|
else
|
|
261
301
|
return false;
|
|
262
|
-
})(); const
|
|
263
|
-
if (Array.isArray(input.depends_on) && input.depends_on.every((elem,
|
|
264
|
-
return
|
|
302
|
+
})(); const _iu4 = (input, _exceptionable = true) => (() => {
|
|
303
|
+
if (Array.isArray(input.depends_on) && input.depends_on.every((elem, _index16) => "string" === typeof elem))
|
|
304
|
+
return _io30(input, true && _exceptionable);
|
|
265
305
|
else
|
|
266
|
-
return
|
|
306
|
+
return _io29(input, true && _exceptionable);
|
|
267
307
|
})(); const _vo0 = (input, _path, _exceptionable = true) => ["container" === input.type || _report(_exceptionable, {
|
|
268
308
|
path: _path + ".type",
|
|
269
309
|
expected: "\"container\"",
|
|
@@ -318,12 +358,12 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
318
358
|
path: _path + ".ops",
|
|
319
359
|
expected: "Array<> & UniqueById",
|
|
320
360
|
value: input.ops
|
|
321
|
-
})) && input.ops.map((elem,
|
|
322
|
-
path: _path + ".ops[" +
|
|
361
|
+
})) && input.ops.map((elem, _index17) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
362
|
+
path: _path + ".ops[" + _index17 + "]",
|
|
323
363
|
expected: "Operation<keyof OperationArgsMap>",
|
|
324
364
|
value: elem
|
|
325
|
-
})) && _vo9(elem, _path + ".ops[" +
|
|
326
|
-
path: _path + ".ops[" +
|
|
365
|
+
})) && _vo9(elem, _path + ".ops[" + _index17 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
366
|
+
path: _path + ".ops[" + _index17 + "]",
|
|
327
367
|
expected: "Operation<keyof OperationArgsMap>",
|
|
328
368
|
value: elem
|
|
329
369
|
})).every(flag => flag)) || _report(_exceptionable, {
|
|
@@ -444,11 +484,19 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
444
484
|
const value = input[key];
|
|
445
485
|
if (undefined === value)
|
|
446
486
|
return true;
|
|
447
|
-
return
|
|
487
|
+
return (null !== value || _report(_exceptionable, {
|
|
448
488
|
path: _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key),
|
|
449
|
-
expected: "(number | string)",
|
|
489
|
+
expected: "(Record<string, string | number> | number | string | undefined)",
|
|
450
490
|
value: value
|
|
451
|
-
})
|
|
491
|
+
})) && (undefined === value || "string" === typeof value || "number" === typeof value || ("object" === typeof value && null !== value && false === Array.isArray(value) || _report(_exceptionable, {
|
|
492
|
+
path: _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key),
|
|
493
|
+
expected: "(Record<string, string | number> | number | string | undefined)",
|
|
494
|
+
value: value
|
|
495
|
+
})) && _vo5(value, _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key), true && _exceptionable) || _report(_exceptionable, {
|
|
496
|
+
path: _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key),
|
|
497
|
+
expected: "(Record<string, string | number> | number | string | undefined)",
|
|
498
|
+
value: value
|
|
499
|
+
}));
|
|
452
500
|
}).every(flag => flag)].every(flag => flag); const _vo5 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
|
453
501
|
const value = input[key];
|
|
454
502
|
if (undefined === value)
|
|
@@ -474,8 +522,8 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
474
522
|
path: _path + ".entrypoint",
|
|
475
523
|
expected: "(CMDArray | string | undefined)",
|
|
476
524
|
value: input.entrypoint
|
|
477
|
-
})) && input.entrypoint.map((elem,
|
|
478
|
-
path: _path + ".entrypoint[" +
|
|
525
|
+
})) && input.entrypoint.map((elem, _index18) => "string" === typeof elem || _report(_exceptionable, {
|
|
526
|
+
path: _path + ".entrypoint[" + _index18 + "]",
|
|
479
527
|
expected: "string",
|
|
480
528
|
value: elem
|
|
481
529
|
})).every(flag => flag) || _report(_exceptionable, {
|
|
@@ -548,7 +596,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
548
596
|
path: _path + ".args",
|
|
549
597
|
expected: "(ContainerCreateVolume | ContainerRun)",
|
|
550
598
|
value: input.args
|
|
551
|
-
})) &&
|
|
599
|
+
})) && _vu3(input.args, _path + ".args", true && _exceptionable) || _report(_exceptionable, {
|
|
552
600
|
path: _path + ".args",
|
|
553
601
|
expected: "(ContainerCreateVolume | ContainerRun)",
|
|
554
602
|
value: input.args
|
|
@@ -556,7 +604,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
556
604
|
path: _path + ".results",
|
|
557
605
|
expected: "(OperationResults | undefined)",
|
|
558
606
|
value: input.results
|
|
559
|
-
})) &&
|
|
607
|
+
})) && _vo27(input.results, _path + ".results", true && _exceptionable) || _report(_exceptionable, {
|
|
560
608
|
path: _path + ".results",
|
|
561
609
|
expected: "(OperationResults | undefined)",
|
|
562
610
|
value: input.results
|
|
@@ -564,7 +612,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
564
612
|
path: _path + ".execution",
|
|
565
613
|
expected: "(undefined | { group?: string | undefined; } & { depends_on: string[]; stop_if_dependent_stops?: boolean | undefined; } | { group?: string | undefined; } & { depends_on?: undefined; stop_if_dependent_stops?: undefined; })",
|
|
566
614
|
value: input.execution
|
|
567
|
-
})) &&
|
|
615
|
+
})) && _vu4(input.execution, _path + ".execution", true && _exceptionable) || _report(_exceptionable, {
|
|
568
616
|
path: _path + ".execution",
|
|
569
617
|
expected: "(undefined | { group?: string | undefined; } & { depends_on: string[]; stop_if_dependent_stops?: boolean | undefined; } | { group?: string | undefined; } & { depends_on?: undefined; stop_if_dependent_stops?: undefined; })",
|
|
570
618
|
value: input.execution
|
|
@@ -596,8 +644,8 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
596
644
|
path: _path + ".aliases",
|
|
597
645
|
expected: "(Aliases | string | undefined)",
|
|
598
646
|
value: input.aliases
|
|
599
|
-
})) && input.aliases.map((elem,
|
|
600
|
-
path: _path + ".aliases[" +
|
|
647
|
+
})) && input.aliases.map((elem, _index19) => "string" === typeof elem || _report(_exceptionable, {
|
|
648
|
+
path: _path + ".aliases[" + _index19 + "]",
|
|
601
649
|
expected: "string",
|
|
602
650
|
value: elem
|
|
603
651
|
})).every(flag => flag) || _report(_exceptionable, {
|
|
@@ -612,8 +660,8 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
612
660
|
path: _path + ".cmd",
|
|
613
661
|
expected: "(CMDArray | string | undefined)",
|
|
614
662
|
value: input.cmd
|
|
615
|
-
})) && input.cmd.map((elem,
|
|
616
|
-
path: _path + ".cmd[" +
|
|
663
|
+
})) && input.cmd.map((elem, _index20) => "string" === typeof elem || _report(_exceptionable, {
|
|
664
|
+
path: _path + ".cmd[" + _index20 + "]",
|
|
617
665
|
expected: "string",
|
|
618
666
|
value: elem
|
|
619
667
|
})).every(flag => flag) || _report(_exceptionable, {
|
|
@@ -624,12 +672,12 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
624
672
|
path: _path + ".volumes",
|
|
625
673
|
expected: "(Array<Volume> | undefined)",
|
|
626
674
|
value: input.volumes
|
|
627
|
-
})) && input.volumes.map((elem,
|
|
628
|
-
path: _path + ".volumes[" +
|
|
675
|
+
})) && input.volumes.map((elem, _index21) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
676
|
+
path: _path + ".volumes[" + _index21 + "]",
|
|
629
677
|
expected: "Volume",
|
|
630
678
|
value: elem
|
|
631
|
-
})) && _vo11(elem, _path + ".volumes[" +
|
|
632
|
-
path: _path + ".volumes[" +
|
|
679
|
+
})) && _vo11(elem, _path + ".volumes[" + _index21 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
680
|
+
path: _path + ".volumes[" + _index21 + "]",
|
|
633
681
|
expected: "Volume",
|
|
634
682
|
value: elem
|
|
635
683
|
})).every(flag => flag) || _report(_exceptionable, {
|
|
@@ -638,7 +686,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
638
686
|
value: input.volumes
|
|
639
687
|
}), (null !== input.expose || _report(_exceptionable, {
|
|
640
688
|
path: _path + ".expose",
|
|
641
|
-
expected: "((Array<ExposeBase> & TagBase<__type>) | (__type & TagBase<__type>) | (string & TagBase<__type>) | number | undefined)",
|
|
689
|
+
expected: "((Array<ExposeBase> & TagBase<__type>) | (__type & TagBase<__type>) | (string & TagBase<__type>) | ExposedPort | number | undefined)",
|
|
642
690
|
value: input.expose
|
|
643
691
|
})) && (undefined === input.expose || "number" === typeof input.expose || "string" === typeof input.expose && (typeof input.expose === "string" && /^%%(ops|global).[^%]+%%$/.test(input.expose) || _report(_exceptionable, {
|
|
644
692
|
path: _path + ".expose",
|
|
@@ -683,33 +731,33 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
683
731
|
path: _path + ".expose",
|
|
684
732
|
expected: "Array<> & TagBase<__type>",
|
|
685
733
|
value: input.expose
|
|
686
|
-
})) && input.expose.map((elem,
|
|
687
|
-
path: _path + ".expose[" +
|
|
688
|
-
expected: "((__type & TagBase<__type>) | (string & TagBase<__type>) | number)",
|
|
734
|
+
})) && input.expose.map((elem, _index22) => (null !== elem || _report(_exceptionable, {
|
|
735
|
+
path: _path + ".expose[" + _index22 + "]",
|
|
736
|
+
expected: "((__type & TagBase<__type>) | (string & TagBase<__type>) | ExposedPort | number)",
|
|
689
737
|
value: elem
|
|
690
738
|
})) && (undefined !== elem || _report(_exceptionable, {
|
|
691
|
-
path: _path + ".expose[" +
|
|
692
|
-
expected: "((__type & TagBase<__type>) | (string & TagBase<__type>) | number)",
|
|
739
|
+
path: _path + ".expose[" + _index22 + "]",
|
|
740
|
+
expected: "((__type & TagBase<__type>) | (string & TagBase<__type>) | ExposedPort | number)",
|
|
693
741
|
value: elem
|
|
694
742
|
})) && ("number" === typeof elem || "string" === typeof elem && (typeof elem === "string" && /^%%(ops|global).[^%]+%%$/.test(elem) || _report(_exceptionable, {
|
|
695
|
-
path: _path + ".expose[" +
|
|
743
|
+
path: _path + ".expose[" + _index22 + "]",
|
|
696
744
|
expected: "string & TagBase<__type>",
|
|
697
745
|
value: elem
|
|
698
746
|
})) || ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
699
|
-
path: _path + ".expose[" +
|
|
700
|
-
expected: "((__type & TagBase<__type>) | (string & TagBase<__type>) | number)",
|
|
747
|
+
path: _path + ".expose[" + _index22 + "]",
|
|
748
|
+
expected: "((__type & TagBase<__type>) | (string & TagBase<__type>) | ExposedPort | number)",
|
|
701
749
|
value: elem
|
|
702
|
-
})) &&
|
|
703
|
-
path: _path + ".expose[" +
|
|
704
|
-
expected: "((__type & TagBase<__type>) | (string & TagBase<__type>) | number)",
|
|
750
|
+
})) && _vu1(elem, _path + ".expose[" + _index22 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
751
|
+
path: _path + ".expose[" + _index22 + "]",
|
|
752
|
+
expected: "((__type & TagBase<__type>) | (string & TagBase<__type>) | ExposedPort | number)",
|
|
705
753
|
value: elem
|
|
706
|
-
}))).every(flag => flag)) || "object" === typeof input.expose && null !== input.expose &&
|
|
754
|
+
}))).every(flag => flag)) || "object" === typeof input.expose && null !== input.expose && _vu1(input.expose, _path + ".expose", true && _exceptionable) || _report(_exceptionable, {
|
|
707
755
|
path: _path + ".expose",
|
|
708
|
-
expected: "((Array<ExposeBase> & TagBase<__type>) | (__type & TagBase<__type>) | (string & TagBase<__type>) | number | undefined)",
|
|
756
|
+
expected: "((Array<ExposeBase> & TagBase<__type>) | (__type & TagBase<__type>) | (string & TagBase<__type>) | ExposedPort | number | undefined)",
|
|
709
757
|
value: input.expose
|
|
710
758
|
})) || _report(_exceptionable, {
|
|
711
759
|
path: _path + ".expose",
|
|
712
|
-
expected: "((Array<ExposeBase> & TagBase<__type>) | (__type & TagBase<__type>) | (string & TagBase<__type>) | number | undefined)",
|
|
760
|
+
expected: "((Array<ExposeBase> & TagBase<__type>) | (__type & TagBase<__type>) | (string & TagBase<__type>) | ExposedPort | number | undefined)",
|
|
713
761
|
value: input.expose
|
|
714
762
|
})), undefined === input.gpu || "boolean" === typeof input.gpu || _report(_exceptionable, {
|
|
715
763
|
path: _path + ".gpu",
|
|
@@ -727,8 +775,8 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
727
775
|
path: _path + ".entrypoint",
|
|
728
776
|
expected: "(CMDArray | string | undefined)",
|
|
729
777
|
value: input.entrypoint
|
|
730
|
-
})) && input.entrypoint.map((elem,
|
|
731
|
-
path: _path + ".entrypoint[" +
|
|
778
|
+
})) && input.entrypoint.map((elem, _index23) => "string" === typeof elem || _report(_exceptionable, {
|
|
779
|
+
path: _path + ".entrypoint[" + _index23 + "]",
|
|
732
780
|
expected: "string",
|
|
733
781
|
value: elem
|
|
734
782
|
})).every(flag => flag) || _report(_exceptionable, {
|
|
@@ -747,20 +795,20 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
747
795
|
path: _path + ".resources",
|
|
748
796
|
expected: "(Resources | undefined)",
|
|
749
797
|
value: input.resources
|
|
750
|
-
})) && input.resources.map((elem,
|
|
751
|
-
path: _path + ".resources[" +
|
|
798
|
+
})) && input.resources.map((elem, _index24) => (null !== elem || _report(_exceptionable, {
|
|
799
|
+
path: _path + ".resources[" + _index24 + "]",
|
|
752
800
|
expected: "(\"__remove-if-empty__\" | (__type & TagBase<__type>) | HFResource | OllamaResource | S3Base | S3WithBucket | S3WithBuckets)",
|
|
753
801
|
value: elem
|
|
754
802
|
})) && (undefined !== elem || _report(_exceptionable, {
|
|
755
|
-
path: _path + ".resources[" +
|
|
803
|
+
path: _path + ".resources[" + _index24 + "]",
|
|
756
804
|
expected: "(\"__remove-if-empty__\" | (__type & TagBase<__type>) | HFResource | OllamaResource | S3Base | S3WithBucket | S3WithBuckets)",
|
|
757
805
|
value: elem
|
|
758
806
|
})) && ("__remove-if-empty__" === elem || ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
759
|
-
path: _path + ".resources[" +
|
|
807
|
+
path: _path + ".resources[" + _index24 + "]",
|
|
760
808
|
expected: "(\"__remove-if-empty__\" | (__type & TagBase<__type>) | HFResource | OllamaResource | S3Base | S3WithBucket | S3WithBuckets)",
|
|
761
809
|
value: elem
|
|
762
|
-
})) &&
|
|
763
|
-
path: _path + ".resources[" +
|
|
810
|
+
})) && _vu2(elem, _path + ".resources[" + _index24 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
811
|
+
path: _path + ".resources[" + _index24 + "]",
|
|
764
812
|
expected: "(\"__remove-if-empty__\" | (__type & TagBase<__type>) | HFResource | OllamaResource | S3Base | S3WithBucket | S3WithBuckets)",
|
|
765
813
|
value: elem
|
|
766
814
|
}))).every(flag => flag) || _report(_exceptionable, {
|
|
@@ -771,7 +819,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
771
819
|
path: _path + ".authentication",
|
|
772
820
|
expected: "(Authentication | undefined)",
|
|
773
821
|
value: input.authentication
|
|
774
|
-
})) &&
|
|
822
|
+
})) && _vo24(input.authentication, _path + ".authentication", true && _exceptionable) || _report(_exceptionable, {
|
|
775
823
|
path: _path + ".authentication",
|
|
776
824
|
expected: "(Authentication | undefined)",
|
|
777
825
|
value: input.authentication
|
|
@@ -839,7 +887,128 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
839
887
|
"Please remove the property next time."
|
|
840
888
|
].join("\n")
|
|
841
889
|
});
|
|
842
|
-
}).every(flag => flag))].every(flag => flag); const _vo13 = (input, _path, _exceptionable = true) => ["
|
|
890
|
+
}).every(flag => flag))].every(flag => flag); const _vo13 = (input, _path, _exceptionable = true) => ["number" === typeof input.port || _report(_exceptionable, {
|
|
891
|
+
path: _path + ".port",
|
|
892
|
+
expected: "number",
|
|
893
|
+
value: input.port
|
|
894
|
+
}), undefined === input.type || "api" === input.type || "web" === input.type || "websocket" === input.type || "webapi" === input.type || "none" === input.type || _report(_exceptionable, {
|
|
895
|
+
path: _path + ".type",
|
|
896
|
+
expected: "(\"api\" | \"none\" | \"web\" | \"webapi\" | \"websocket\" | undefined)",
|
|
897
|
+
value: input.type
|
|
898
|
+
}), undefined === input.health_checks || (Array.isArray(input.health_checks) || _report(_exceptionable, {
|
|
899
|
+
path: _path + ".health_checks",
|
|
900
|
+
expected: "(Array<HealthCheck> | undefined)",
|
|
901
|
+
value: input.health_checks
|
|
902
|
+
})) && input.health_checks.map((elem, _index25) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
903
|
+
path: _path + ".health_checks[" + _index25 + "]",
|
|
904
|
+
expected: "(HttpHealthCheck | WebSocketHealthCheck)",
|
|
905
|
+
value: elem
|
|
906
|
+
})) && _vu0(elem, _path + ".health_checks[" + _index25 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
907
|
+
path: _path + ".health_checks[" + _index25 + "]",
|
|
908
|
+
expected: "(HttpHealthCheck | WebSocketHealthCheck)",
|
|
909
|
+
value: elem
|
|
910
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
911
|
+
path: _path + ".health_checks",
|
|
912
|
+
expected: "(Array<HealthCheck> | undefined)",
|
|
913
|
+
value: input.health_checks
|
|
914
|
+
}), 1 === Object.keys(input).length || (false === _exceptionable || Object.keys(input).map(key => {
|
|
915
|
+
if (["port", "type", "health_checks"].some(prop => key === prop))
|
|
916
|
+
return true;
|
|
917
|
+
const value = input[key];
|
|
918
|
+
if (undefined === value)
|
|
919
|
+
return true;
|
|
920
|
+
return _report(_exceptionable, {
|
|
921
|
+
path: _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key),
|
|
922
|
+
expected: "undefined",
|
|
923
|
+
value: value,
|
|
924
|
+
description: [
|
|
925
|
+
`The property \`${key}\` is not defined in the object type.`,
|
|
926
|
+
"",
|
|
927
|
+
"Please remove the property next time."
|
|
928
|
+
].join("\n")
|
|
929
|
+
});
|
|
930
|
+
}).every(flag => flag))].every(flag => flag); const _vo14 = (input, _path, _exceptionable = true) => ["http" === input.type || _report(_exceptionable, {
|
|
931
|
+
path: _path + ".type",
|
|
932
|
+
expected: "\"http\"",
|
|
933
|
+
value: input.type
|
|
934
|
+
}), "string" === typeof input.path || _report(_exceptionable, {
|
|
935
|
+
path: _path + ".path",
|
|
936
|
+
expected: "string",
|
|
937
|
+
value: input.path
|
|
938
|
+
}), "GET" === input.method || "POST" === input.method || "PUT" === input.method || "DELETE" === input.method || _report(_exceptionable, {
|
|
939
|
+
path: _path + ".method",
|
|
940
|
+
expected: "(\"DELETE\" | \"GET\" | \"POST\" | \"PUT\")",
|
|
941
|
+
value: input.method
|
|
942
|
+
}), "number" === typeof input.expected_status || _report(_exceptionable, {
|
|
943
|
+
path: _path + ".expected_status",
|
|
944
|
+
expected: "number",
|
|
945
|
+
value: input.expected_status
|
|
946
|
+
}), undefined === input.headers || ("object" === typeof input.headers && null !== input.headers && false === Array.isArray(input.headers) || _report(_exceptionable, {
|
|
947
|
+
path: _path + ".headers",
|
|
948
|
+
expected: "(Record<string, string> | undefined)",
|
|
949
|
+
value: input.headers
|
|
950
|
+
})) && _vo15(input.headers, _path + ".headers", true && _exceptionable) || _report(_exceptionable, {
|
|
951
|
+
path: _path + ".headers",
|
|
952
|
+
expected: "(Record<string, string> | undefined)",
|
|
953
|
+
value: input.headers
|
|
954
|
+
}), true, "boolean" === typeof input.continuous || _report(_exceptionable, {
|
|
955
|
+
path: _path + ".continuous",
|
|
956
|
+
expected: "boolean",
|
|
957
|
+
value: input.continuous
|
|
958
|
+
}), 5 === Object.keys(input).length || (false === _exceptionable || Object.keys(input).map(key => {
|
|
959
|
+
if (["type", "path", "method", "expected_status", "headers", "body", "continuous"].some(prop => key === prop))
|
|
960
|
+
return true;
|
|
961
|
+
const value = input[key];
|
|
962
|
+
if (undefined === value)
|
|
963
|
+
return true;
|
|
964
|
+
return _report(_exceptionable, {
|
|
965
|
+
path: _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key),
|
|
966
|
+
expected: "undefined",
|
|
967
|
+
value: value,
|
|
968
|
+
description: [
|
|
969
|
+
`The property \`${key}\` is not defined in the object type.`,
|
|
970
|
+
"",
|
|
971
|
+
"Please remove the property next time."
|
|
972
|
+
].join("\n")
|
|
973
|
+
});
|
|
974
|
+
}).every(flag => flag))].every(flag => flag); const _vo15 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
|
975
|
+
const value = input[key];
|
|
976
|
+
if (undefined === value)
|
|
977
|
+
return true;
|
|
978
|
+
return "string" === typeof value || _report(_exceptionable, {
|
|
979
|
+
path: _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key),
|
|
980
|
+
expected: "string",
|
|
981
|
+
value: value
|
|
982
|
+
});
|
|
983
|
+
}).every(flag => flag)].every(flag => flag); const _vo16 = (input, _path, _exceptionable = true) => ["websocket" === input.type || _report(_exceptionable, {
|
|
984
|
+
path: _path + ".type",
|
|
985
|
+
expected: "\"websocket\"",
|
|
986
|
+
value: input.type
|
|
987
|
+
}), "string" === typeof input.expected_response || _report(_exceptionable, {
|
|
988
|
+
path: _path + ".expected_response",
|
|
989
|
+
expected: "string",
|
|
990
|
+
value: input.expected_response
|
|
991
|
+
}), "boolean" === typeof input.continuous || _report(_exceptionable, {
|
|
992
|
+
path: _path + ".continuous",
|
|
993
|
+
expected: "boolean",
|
|
994
|
+
value: input.continuous
|
|
995
|
+
}), 3 === Object.keys(input).length || (false === _exceptionable || Object.keys(input).map(key => {
|
|
996
|
+
if (["type", "expected_response", "continuous"].some(prop => key === prop))
|
|
997
|
+
return true;
|
|
998
|
+
const value = input[key];
|
|
999
|
+
if (undefined === value)
|
|
1000
|
+
return true;
|
|
1001
|
+
return _report(_exceptionable, {
|
|
1002
|
+
path: _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key),
|
|
1003
|
+
expected: "undefined",
|
|
1004
|
+
value: value,
|
|
1005
|
+
description: [
|
|
1006
|
+
`The property \`${key}\` is not defined in the object type.`,
|
|
1007
|
+
"",
|
|
1008
|
+
"Please remove the property next time."
|
|
1009
|
+
].join("\n")
|
|
1010
|
+
});
|
|
1011
|
+
}).every(flag => flag))].every(flag => flag); const _vo17 = (input, _path, _exceptionable = true) => ["S3" === input.type || _report(_exceptionable, {
|
|
843
1012
|
path: _path + ".type",
|
|
844
1013
|
expected: "\"S3\"",
|
|
845
1014
|
value: input.type
|
|
@@ -859,8 +1028,8 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
859
1028
|
path: _path + ".files",
|
|
860
1029
|
expected: "(Array<string> | undefined)",
|
|
861
1030
|
value: input.files
|
|
862
|
-
})) && input.files.map((elem,
|
|
863
|
-
path: _path + ".files[" +
|
|
1031
|
+
})) && input.files.map((elem, _index26) => "string" === typeof elem || _report(_exceptionable, {
|
|
1032
|
+
path: _path + ".files[" + _index26 + "]",
|
|
864
1033
|
expected: "string",
|
|
865
1034
|
value: elem
|
|
866
1035
|
})).every(flag => flag) || _report(_exceptionable, {
|
|
@@ -871,7 +1040,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
871
1040
|
path: _path + ".IAM",
|
|
872
1041
|
expected: "(S3Auth | undefined)",
|
|
873
1042
|
value: input.IAM
|
|
874
|
-
})) &&
|
|
1043
|
+
})) && _vo18(input.IAM, _path + ".IAM", true && _exceptionable) || _report(_exceptionable, {
|
|
875
1044
|
path: _path + ".IAM",
|
|
876
1045
|
expected: "(S3Auth | undefined)",
|
|
877
1046
|
value: input.IAM
|
|
@@ -891,7 +1060,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
891
1060
|
"Please remove the property next time."
|
|
892
1061
|
].join("\n")
|
|
893
1062
|
});
|
|
894
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1063
|
+
}).every(flag => flag))].every(flag => flag); const _vo18 = (input, _path, _exceptionable = true) => ["string" === typeof input.REGION || _report(_exceptionable, {
|
|
895
1064
|
path: _path + ".REGION",
|
|
896
1065
|
expected: "string",
|
|
897
1066
|
value: input.REGION
|
|
@@ -919,7 +1088,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
919
1088
|
"Please remove the property next time."
|
|
920
1089
|
].join("\n")
|
|
921
1090
|
});
|
|
922
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1091
|
+
}).every(flag => flag))].every(flag => flag); const _vo19 = (input, _path, _exceptionable = true) => ["S3" === input.type || _report(_exceptionable, {
|
|
923
1092
|
path: _path + ".type",
|
|
924
1093
|
expected: "\"S3\"",
|
|
925
1094
|
value: input.type
|
|
@@ -943,7 +1112,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
943
1112
|
path: _path + ".IAM",
|
|
944
1113
|
expected: "(S3Auth | undefined)",
|
|
945
1114
|
value: input.IAM
|
|
946
|
-
})) &&
|
|
1115
|
+
})) && _vo18(input.IAM, _path + ".IAM", true && _exceptionable) || _report(_exceptionable, {
|
|
947
1116
|
path: _path + ".IAM",
|
|
948
1117
|
expected: "(S3Auth | undefined)",
|
|
949
1118
|
value: input.IAM
|
|
@@ -963,7 +1132,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
963
1132
|
"Please remove the property next time."
|
|
964
1133
|
].join("\n")
|
|
965
1134
|
});
|
|
966
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1135
|
+
}).every(flag => flag))].every(flag => flag); const _vo20 = (input, _path, _exceptionable = true) => ["S3" === input.type || _report(_exceptionable, {
|
|
967
1136
|
path: _path + ".type",
|
|
968
1137
|
expected: "\"S3\"",
|
|
969
1138
|
value: input.type
|
|
@@ -975,12 +1144,12 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
975
1144
|
path: _path + ".buckets",
|
|
976
1145
|
expected: "Array<__type>",
|
|
977
1146
|
value: input.buckets
|
|
978
|
-
})) && input.buckets.map((elem,
|
|
979
|
-
path: _path + ".buckets[" +
|
|
1147
|
+
})) && input.buckets.map((elem, _index27) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
1148
|
+
path: _path + ".buckets[" + _index27 + "]",
|
|
980
1149
|
expected: "__type.o4",
|
|
981
1150
|
value: elem
|
|
982
|
-
})) &&
|
|
983
|
-
path: _path + ".buckets[" +
|
|
1151
|
+
})) && _vo21(elem, _path + ".buckets[" + _index27 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
1152
|
+
path: _path + ".buckets[" + _index27 + "]",
|
|
984
1153
|
expected: "__type.o4",
|
|
985
1154
|
value: elem
|
|
986
1155
|
})).every(flag => flag) || _report(_exceptionable, {
|
|
@@ -999,7 +1168,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
999
1168
|
path: _path + ".IAM",
|
|
1000
1169
|
expected: "(S3Auth | undefined)",
|
|
1001
1170
|
value: input.IAM
|
|
1002
|
-
})) &&
|
|
1171
|
+
})) && _vo18(input.IAM, _path + ".IAM", true && _exceptionable) || _report(_exceptionable, {
|
|
1003
1172
|
path: _path + ".IAM",
|
|
1004
1173
|
expected: "(S3Auth | undefined)",
|
|
1005
1174
|
value: input.IAM
|
|
@@ -1019,7 +1188,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1019
1188
|
"Please remove the property next time."
|
|
1020
1189
|
].join("\n")
|
|
1021
1190
|
});
|
|
1022
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1191
|
+
}).every(flag => flag))].every(flag => flag); const _vo21 = (input, _path, _exceptionable = true) => ["string" === typeof input.url || _report(_exceptionable, {
|
|
1023
1192
|
path: _path + ".url",
|
|
1024
1193
|
expected: "string",
|
|
1025
1194
|
value: input.url
|
|
@@ -1027,8 +1196,8 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1027
1196
|
path: _path + ".files",
|
|
1028
1197
|
expected: "(Array<string> | undefined)",
|
|
1029
1198
|
value: input.files
|
|
1030
|
-
})) && input.files.map((elem,
|
|
1031
|
-
path: _path + ".files[" +
|
|
1199
|
+
})) && input.files.map((elem, _index28) => "string" === typeof elem || _report(_exceptionable, {
|
|
1200
|
+
path: _path + ".files[" + _index28 + "]",
|
|
1032
1201
|
expected: "string",
|
|
1033
1202
|
value: elem
|
|
1034
1203
|
})).every(flag => flag) || _report(_exceptionable, {
|
|
@@ -1051,7 +1220,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1051
1220
|
"Please remove the property next time."
|
|
1052
1221
|
].join("\n")
|
|
1053
1222
|
});
|
|
1054
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1223
|
+
}).every(flag => flag))].every(flag => flag); const _vo22 = (input, _path, _exceptionable = true) => ["HF" === input.type || _report(_exceptionable, {
|
|
1055
1224
|
path: _path + ".type",
|
|
1056
1225
|
expected: "\"HF\"",
|
|
1057
1226
|
value: input.type
|
|
@@ -1071,8 +1240,8 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1071
1240
|
path: _path + ".files",
|
|
1072
1241
|
expected: "(Array<string> | undefined)",
|
|
1073
1242
|
value: input.files
|
|
1074
|
-
})) && input.files.map((elem,
|
|
1075
|
-
path: _path + ".files[" +
|
|
1243
|
+
})) && input.files.map((elem, _index29) => "string" === typeof elem || _report(_exceptionable, {
|
|
1244
|
+
path: _path + ".files[" + _index29 + "]",
|
|
1076
1245
|
expected: "string",
|
|
1077
1246
|
value: elem
|
|
1078
1247
|
})).every(flag => flag) || _report(_exceptionable, {
|
|
@@ -1099,7 +1268,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1099
1268
|
"Please remove the property next time."
|
|
1100
1269
|
].join("\n")
|
|
1101
1270
|
});
|
|
1102
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1271
|
+
}).every(flag => flag))].every(flag => flag); const _vo23 = (input, _path, _exceptionable = true) => ["Ollama" === input.type || _report(_exceptionable, {
|
|
1103
1272
|
path: _path + ".type",
|
|
1104
1273
|
expected: "\"Ollama\"",
|
|
1105
1274
|
value: input.type
|
|
@@ -1127,11 +1296,11 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1127
1296
|
"Please remove the property next time."
|
|
1128
1297
|
].join("\n")
|
|
1129
1298
|
});
|
|
1130
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1299
|
+
}).every(flag => flag))].every(flag => flag); const _vo24 = (input, _path, _exceptionable = true) => [undefined === input.docker || ("object" === typeof input.docker && null !== input.docker && false === Array.isArray(input.docker) || _report(_exceptionable, {
|
|
1131
1300
|
path: _path + ".docker",
|
|
1132
1301
|
expected: "(DockerAuth | undefined)",
|
|
1133
1302
|
value: input.docker
|
|
1134
|
-
})) &&
|
|
1303
|
+
})) && _vo25(input.docker, _path + ".docker", true && _exceptionable) || _report(_exceptionable, {
|
|
1135
1304
|
path: _path + ".docker",
|
|
1136
1305
|
expected: "(DockerAuth | undefined)",
|
|
1137
1306
|
value: input.docker
|
|
@@ -1151,7 +1320,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1151
1320
|
"Please remove the property next time."
|
|
1152
1321
|
].join("\n")
|
|
1153
1322
|
});
|
|
1154
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1323
|
+
}).every(flag => flag))].every(flag => flag); const _vo25 = (input, _path, _exceptionable = true) => [undefined === input.username || "string" === typeof input.username || _report(_exceptionable, {
|
|
1155
1324
|
path: _path + ".username",
|
|
1156
1325
|
expected: "(string | undefined)",
|
|
1157
1326
|
value: input.username
|
|
@@ -1183,7 +1352,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1183
1352
|
"Please remove the property next time."
|
|
1184
1353
|
].join("\n")
|
|
1185
1354
|
});
|
|
1186
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1355
|
+
}).every(flag => flag))].every(flag => flag); const _vo26 = (input, _path, _exceptionable = true) => ["string" === typeof input.name || _report(_exceptionable, {
|
|
1187
1356
|
path: _path + ".name",
|
|
1188
1357
|
expected: "string",
|
|
1189
1358
|
value: input.name
|
|
@@ -1203,7 +1372,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1203
1372
|
"Please remove the property next time."
|
|
1204
1373
|
].join("\n")
|
|
1205
1374
|
});
|
|
1206
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1375
|
+
}).every(flag => flag))].every(flag => flag); const _vo27 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
|
1207
1376
|
const value = input[key];
|
|
1208
1377
|
if (undefined === value)
|
|
1209
1378
|
return true;
|
|
@@ -1219,12 +1388,12 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1219
1388
|
path: _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key),
|
|
1220
1389
|
expected: "(OperationResult | string)",
|
|
1221
1390
|
value: value
|
|
1222
|
-
})) &&
|
|
1391
|
+
})) && _vo28(value, _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key), true && _exceptionable) || _report(_exceptionable, {
|
|
1223
1392
|
path: _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key),
|
|
1224
1393
|
expected: "(OperationResult | string)",
|
|
1225
1394
|
value: value
|
|
1226
1395
|
}));
|
|
1227
|
-
}).every(flag => flag)].every(flag => flag); const
|
|
1396
|
+
}).every(flag => flag)].every(flag => flag); const _vo28 = (input, _path, _exceptionable = true) => ["string" === typeof input.regex || _report(_exceptionable, {
|
|
1228
1397
|
path: _path + ".regex",
|
|
1229
1398
|
expected: "string",
|
|
1230
1399
|
value: input.regex
|
|
@@ -1244,8 +1413,8 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1244
1413
|
path: _path + ".logType",
|
|
1245
1414
|
expected: "Array<> & UniqueLogTypeTag",
|
|
1246
1415
|
value: input.logType
|
|
1247
|
-
})) && input.logType.map((elem,
|
|
1248
|
-
path: _path + ".logType[" +
|
|
1416
|
+
})) && input.logType.map((elem, _index30) => "stdin" === elem || "stdout" === elem || "stderr" === elem || "nodeerr" === elem || _report(_exceptionable, {
|
|
1417
|
+
path: _path + ".logType[" + _index30 + "]",
|
|
1249
1418
|
expected: "(\"nodeerr\" | \"stderr\" | \"stdin\" | \"stdout\")",
|
|
1250
1419
|
value: elem
|
|
1251
1420
|
})).every(flag => flag)) || _report(_exceptionable, {
|
|
@@ -1268,7 +1437,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1268
1437
|
"Please remove the property next time."
|
|
1269
1438
|
].join("\n")
|
|
1270
1439
|
});
|
|
1271
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1440
|
+
}).every(flag => flag))].every(flag => flag); const _vo29 = (input, _path, _exceptionable = true) => [undefined === input.group || "string" === typeof input.group || _report(_exceptionable, {
|
|
1272
1441
|
path: _path + ".group",
|
|
1273
1442
|
expected: "(string | undefined)",
|
|
1274
1443
|
value: input.group
|
|
@@ -1304,7 +1473,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1304
1473
|
"Please remove the property next time."
|
|
1305
1474
|
].join("\n")
|
|
1306
1475
|
});
|
|
1307
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1476
|
+
}).every(flag => flag))].every(flag => flag); const _vo30 = (input, _path, _exceptionable = true) => [undefined === input.group || "string" === typeof input.group || _report(_exceptionable, {
|
|
1308
1477
|
path: _path + ".group",
|
|
1309
1478
|
expected: "(string | undefined)",
|
|
1310
1479
|
value: input.group
|
|
@@ -1312,8 +1481,8 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1312
1481
|
path: _path + ".depends_on",
|
|
1313
1482
|
expected: "Array<string>",
|
|
1314
1483
|
value: input.depends_on
|
|
1315
|
-
})) && input.depends_on.map((elem,
|
|
1316
|
-
path: _path + ".depends_on[" +
|
|
1484
|
+
})) && input.depends_on.map((elem, _index31) => "string" === typeof elem || _report(_exceptionable, {
|
|
1485
|
+
path: _path + ".depends_on[" + _index31 + "]",
|
|
1317
1486
|
expected: "string",
|
|
1318
1487
|
value: elem
|
|
1319
1488
|
})).every(flag => flag) || _report(_exceptionable, {
|
|
@@ -1341,34 +1510,56 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1341
1510
|
].join("\n")
|
|
1342
1511
|
});
|
|
1343
1512
|
}).every(flag => flag))].every(flag => flag); const _vu0 = (input, _path, _exceptionable = true) => (() => {
|
|
1513
|
+
if ("http" === input.type)
|
|
1514
|
+
return _vo14(input, _path, true && _exceptionable);
|
|
1515
|
+
else if ("websocket" === input.type)
|
|
1516
|
+
return _vo16(input, _path, true && _exceptionable);
|
|
1517
|
+
else
|
|
1518
|
+
return _report(_exceptionable, {
|
|
1519
|
+
path: _path,
|
|
1520
|
+
expected: "(HttpHealthCheck | WebSocketHealthCheck)",
|
|
1521
|
+
value: input
|
|
1522
|
+
});
|
|
1523
|
+
})(); const _vu1 = (input, _path, _exceptionable = true) => (() => {
|
|
1524
|
+
if (undefined !== input.__spread__)
|
|
1525
|
+
return _vo12(input, _path, true && _exceptionable);
|
|
1526
|
+
else if (undefined !== input.port)
|
|
1527
|
+
return _vo13(input, _path, true && _exceptionable);
|
|
1528
|
+
else
|
|
1529
|
+
return _report(_exceptionable, {
|
|
1530
|
+
path: _path,
|
|
1531
|
+
expected: "(__type | ExposedPort)",
|
|
1532
|
+
value: input
|
|
1533
|
+
});
|
|
1534
|
+
})(); const _vu2 = (input, _path, _exceptionable = true) => (() => {
|
|
1344
1535
|
if (undefined !== input.__spread__)
|
|
1345
1536
|
return _vo12(input, _path, true && _exceptionable);
|
|
1346
1537
|
else if (undefined !== input.bucket)
|
|
1347
|
-
return
|
|
1538
|
+
return _vo19(input, _path, true && _exceptionable);
|
|
1348
1539
|
else if (undefined !== input.buckets)
|
|
1349
|
-
return
|
|
1540
|
+
return _vo20(input, _path, true && _exceptionable);
|
|
1350
1541
|
else if ("HF" === input.type)
|
|
1351
|
-
return
|
|
1542
|
+
return _vo22(input, _path, true && _exceptionable);
|
|
1352
1543
|
else if ("Ollama" === input.type)
|
|
1353
|
-
return
|
|
1544
|
+
return _vo23(input, _path, true && _exceptionable);
|
|
1354
1545
|
else
|
|
1355
|
-
return
|
|
1356
|
-
})(); const
|
|
1546
|
+
return _vo17(input, _path, true && _exceptionable);
|
|
1547
|
+
})(); const _vu3 = (input, _path, _exceptionable = true) => (() => {
|
|
1357
1548
|
if (undefined !== input.image)
|
|
1358
1549
|
return _vo10(input, _path, true && _exceptionable);
|
|
1359
1550
|
else if (undefined !== input.name)
|
|
1360
|
-
return
|
|
1551
|
+
return _vo26(input, _path, true && _exceptionable);
|
|
1361
1552
|
else
|
|
1362
1553
|
return _report(_exceptionable, {
|
|
1363
1554
|
path: _path,
|
|
1364
1555
|
expected: "(ContainerRun | ContainerCreateVolume)",
|
|
1365
1556
|
value: input
|
|
1366
1557
|
});
|
|
1367
|
-
})(); const
|
|
1368
|
-
if (Array.isArray(input.depends_on) && input.depends_on.map((elem,
|
|
1369
|
-
return
|
|
1558
|
+
})(); const _vu4 = (input, _path, _exceptionable = true) => (() => {
|
|
1559
|
+
if (Array.isArray(input.depends_on) && input.depends_on.map((elem, _index32) => "string" === typeof elem).every(flag => flag))
|
|
1560
|
+
return _vo30(input, _path, true && _exceptionable);
|
|
1370
1561
|
else
|
|
1371
|
-
return
|
|
1562
|
+
return _vo29(input, _path, true && _exceptionable);
|
|
1372
1563
|
})(); const __is = (input, _exceptionable = true) => "object" === typeof input && null !== input && _io0(input, true); let errors; let _report; return __typia_transform__createStandardSchema._createStandardSchema(input => {
|
|
1373
1564
|
if (false === __is(input)) {
|
|
1374
1565
|
errors = [];
|
package/dist/Jobs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/Jobs/index.ts"],"names":[],"mappings":";;;AAAA,OAAO,KAAe,MAAM,OAAO,CAAC;AAGpC,cAAc,kBAAkB,CAAA;AAChC,cAAc,0BAA0B,CAAA;AACxC,cAAc,iBAAiB,CAAA;AAwB/B,MAAM,CAAC,MAAM,qBAAqB,yvBA7BD,EAAE;;;qBAGV,EAAE;;;;;IAIT,CAAC;;AACP,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;04BARH,EAAG;;;;;;;;;;4CAgBJ,CAAE,SAAQ,CAAE;;;;;QAOrB,CAAC;;;;;;;;;YAMwR,CAAC;;QAAoD,CAAC;IAAW,CAAC;;;;;QAA0J,CAAC;IAAW,CAAC;;AAA8B,CAAC
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/Jobs/index.ts"],"names":[],"mappings":";;;AAAA,OAAO,KAAe,MAAM,OAAO,CAAC;AAGpC,cAAc,kBAAkB,CAAA;AAChC,cAAc,0BAA0B,CAAA;AACxC,cAAc,iBAAiB,CAAA;AAwB/B,MAAM,CAAC,MAAM,qBAAqB,yvBA7BD,EAAE;;;qBAGV,EAAE;;;;;IAIT,CAAC;;AACP,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;04BARH,EAAG;;;;;;;;;;4CAgBJ,CAAE,SAAQ,CAAE;;;;;QAOrB,CAAC;;;;;;;;;YAMwR,CAAC;;QAAoD,CAAC;IAAW,CAAC;;;;;QAA0J,CAAC;IAAW,CAAC;;AAA8B,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;uNA5B7e,EAAG;;;;;;IAM1C,CAAC;;AACN,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6CARwB,EAAE;;;yBAGV,EAAE;;;;;QAIT,CAAC;;IACP,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iDARH,EAAG;;;;;;;;;;gDAgBJ,CAAE,SAAQ,CAAE;;;;;YAOrB,CAAC;;;;;;;;;gBAMwR,CAAC;;YAAoD,CAAC;QAAW,CAAC;;;;;YAA0J,CAAC;QAAW,CAAC;;IAA8B,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2GA5B7e,EAAG;;;;;;QAM1C,CAAC;;IACN,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAqB+E,CAAC"}
|
package/dist/Schemas/job.js
CHANGED
|
@@ -106,6 +106,9 @@ export const jobSchemas = {
|
|
|
106
106
|
},
|
|
107
107
|
{
|
|
108
108
|
type: "number"
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
$ref: "#/components/schemas/Recordstringstringnumber"
|
|
109
112
|
}
|
|
110
113
|
]
|
|
111
114
|
}
|
|
@@ -279,6 +282,9 @@ export const jobSchemas = {
|
|
|
279
282
|
"__spread__"
|
|
280
283
|
]
|
|
281
284
|
},
|
|
285
|
+
{
|
|
286
|
+
$ref: "#/components/schemas/ExposedPort"
|
|
287
|
+
},
|
|
282
288
|
{
|
|
283
289
|
$ref: "#/components/schemas/UniqueExposedPorts"
|
|
284
290
|
}
|
|
@@ -338,6 +344,114 @@ export const jobSchemas = {
|
|
|
338
344
|
LiteralString: {
|
|
339
345
|
type: "string"
|
|
340
346
|
},
|
|
347
|
+
ExposedPort: {
|
|
348
|
+
type: "object",
|
|
349
|
+
properties: {
|
|
350
|
+
port: {
|
|
351
|
+
type: "number"
|
|
352
|
+
},
|
|
353
|
+
type: {
|
|
354
|
+
type: "string",
|
|
355
|
+
"enum": [
|
|
356
|
+
"api",
|
|
357
|
+
"web",
|
|
358
|
+
"websocket",
|
|
359
|
+
"webapi",
|
|
360
|
+
"none"
|
|
361
|
+
]
|
|
362
|
+
},
|
|
363
|
+
health_checks: {
|
|
364
|
+
type: "array",
|
|
365
|
+
items: {
|
|
366
|
+
$ref: "#/components/schemas/HealthCheck"
|
|
367
|
+
}
|
|
368
|
+
}
|
|
369
|
+
},
|
|
370
|
+
required: [
|
|
371
|
+
"port"
|
|
372
|
+
]
|
|
373
|
+
},
|
|
374
|
+
HealthCheck: {
|
|
375
|
+
oneOf: [
|
|
376
|
+
{
|
|
377
|
+
$ref: "#/components/schemas/HttpHealthCheck"
|
|
378
|
+
},
|
|
379
|
+
{
|
|
380
|
+
$ref: "#/components/schemas/WebSocketHealthCheck"
|
|
381
|
+
}
|
|
382
|
+
]
|
|
383
|
+
},
|
|
384
|
+
HttpHealthCheck: {
|
|
385
|
+
type: "object",
|
|
386
|
+
properties: {
|
|
387
|
+
type: {
|
|
388
|
+
type: "string",
|
|
389
|
+
"enum": [
|
|
390
|
+
"http"
|
|
391
|
+
]
|
|
392
|
+
},
|
|
393
|
+
path: {
|
|
394
|
+
type: "string"
|
|
395
|
+
},
|
|
396
|
+
method: {
|
|
397
|
+
type: "string",
|
|
398
|
+
"enum": [
|
|
399
|
+
"GET",
|
|
400
|
+
"POST",
|
|
401
|
+
"PUT",
|
|
402
|
+
"DELETE"
|
|
403
|
+
]
|
|
404
|
+
},
|
|
405
|
+
expected_status: {
|
|
406
|
+
type: "number"
|
|
407
|
+
},
|
|
408
|
+
headers: {
|
|
409
|
+
$ref: "#/components/schemas/Recordstringstring"
|
|
410
|
+
},
|
|
411
|
+
body: {},
|
|
412
|
+
continuous: {
|
|
413
|
+
type: "boolean"
|
|
414
|
+
}
|
|
415
|
+
},
|
|
416
|
+
required: [
|
|
417
|
+
"type",
|
|
418
|
+
"path",
|
|
419
|
+
"method",
|
|
420
|
+
"expected_status",
|
|
421
|
+
"continuous"
|
|
422
|
+
]
|
|
423
|
+
},
|
|
424
|
+
Recordstringstring: {
|
|
425
|
+
type: "object",
|
|
426
|
+
properties: {},
|
|
427
|
+
required: [],
|
|
428
|
+
description: "Construct a type with a set of properties K of type T",
|
|
429
|
+
additionalProperties: {
|
|
430
|
+
type: "string"
|
|
431
|
+
}
|
|
432
|
+
},
|
|
433
|
+
WebSocketHealthCheck: {
|
|
434
|
+
type: "object",
|
|
435
|
+
properties: {
|
|
436
|
+
type: {
|
|
437
|
+
type: "string",
|
|
438
|
+
"enum": [
|
|
439
|
+
"websocket"
|
|
440
|
+
]
|
|
441
|
+
},
|
|
442
|
+
expected_response: {
|
|
443
|
+
type: "string"
|
|
444
|
+
},
|
|
445
|
+
continuous: {
|
|
446
|
+
type: "boolean"
|
|
447
|
+
}
|
|
448
|
+
},
|
|
449
|
+
required: [
|
|
450
|
+
"type",
|
|
451
|
+
"expected_response",
|
|
452
|
+
"continuous"
|
|
453
|
+
]
|
|
454
|
+
},
|
|
341
455
|
UniqueExposedPorts: {
|
|
342
456
|
type: "array",
|
|
343
457
|
items: {
|
|
@@ -362,6 +476,9 @@ export const jobSchemas = {
|
|
|
362
476
|
required: [
|
|
363
477
|
"__spread__"
|
|
364
478
|
]
|
|
479
|
+
},
|
|
480
|
+
{
|
|
481
|
+
$ref: "#/components/schemas/ExposedPort"
|
|
365
482
|
}
|
|
366
483
|
]
|
|
367
484
|
},
|
package/dist/Schemas/job.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"job.js","sourceRoot":"","sources":["../../src/Schemas/job.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,MAAM,CAAC,MAAM,UAAU
|
|
1
|
+
{"version":3,"file":"job.js","sourceRoot":"","sources":["../../src/Schemas/job.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,MAAM,CAAC,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAA0D,CAAC"}
|
package/package.json
CHANGED