@zgeoff/imp-client 0.10.0 → 0.12.0
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/index.d.ts +525 -39
- package/dist/index.js +3 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -67,6 +67,13 @@ declare const ImpEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
67
67
|
port: z.ZodInt;
|
|
68
68
|
httpPort: z.ZodInt;
|
|
69
69
|
url: z.ZodURL;
|
|
70
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
71
|
+
auth: z.ZodEnum<{
|
|
72
|
+
basic: "basic";
|
|
73
|
+
none: "none";
|
|
74
|
+
token: "token";
|
|
75
|
+
}>;
|
|
76
|
+
}, z.core.$strip>>;
|
|
70
77
|
createdAt: z.ZodDate;
|
|
71
78
|
lastActiveAt: z.ZodDate;
|
|
72
79
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -76,10 +83,12 @@ declare const ImpEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
76
83
|
error: z.ZodOptional<z.ZodString>;
|
|
77
84
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
78
85
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
86
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
79
87
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
80
88
|
agent: "agent";
|
|
81
89
|
firecracker: "firecracker";
|
|
82
90
|
impd: "impd";
|
|
91
|
+
ipv6: "ipv6";
|
|
83
92
|
kernel: "kernel";
|
|
84
93
|
}>>>>;
|
|
85
94
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -106,6 +115,7 @@ declare const ImpEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
106
115
|
reason: z.ZodEnum<{
|
|
107
116
|
adopted: "adopted";
|
|
108
117
|
booted: "booted";
|
|
118
|
+
exposed: "exposed";
|
|
109
119
|
failed: "failed";
|
|
110
120
|
held: "held";
|
|
111
121
|
repaired: "repaired";
|
|
@@ -142,6 +152,13 @@ declare const ImpEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
142
152
|
port: z.ZodInt;
|
|
143
153
|
httpPort: z.ZodInt;
|
|
144
154
|
url: z.ZodURL;
|
|
155
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
156
|
+
auth: z.ZodEnum<{
|
|
157
|
+
basic: "basic";
|
|
158
|
+
none: "none";
|
|
159
|
+
token: "token";
|
|
160
|
+
}>;
|
|
161
|
+
}, z.core.$strip>>;
|
|
145
162
|
createdAt: z.ZodDate;
|
|
146
163
|
lastActiveAt: z.ZodDate;
|
|
147
164
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -151,10 +168,12 @@ declare const ImpEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
151
168
|
error: z.ZodOptional<z.ZodString>;
|
|
152
169
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
153
170
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
171
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
154
172
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
155
173
|
agent: "agent";
|
|
156
174
|
firecracker: "firecracker";
|
|
157
175
|
impd: "impd";
|
|
176
|
+
ipv6: "ipv6";
|
|
158
177
|
kernel: "kernel";
|
|
159
178
|
}>>>>;
|
|
160
179
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -210,6 +229,13 @@ declare const ImpEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
210
229
|
port: z.ZodInt;
|
|
211
230
|
httpPort: z.ZodInt;
|
|
212
231
|
url: z.ZodURL;
|
|
232
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
233
|
+
auth: z.ZodEnum<{
|
|
234
|
+
basic: "basic";
|
|
235
|
+
none: "none";
|
|
236
|
+
token: "token";
|
|
237
|
+
}>;
|
|
238
|
+
}, z.core.$strip>>;
|
|
213
239
|
createdAt: z.ZodDate;
|
|
214
240
|
lastActiveAt: z.ZodDate;
|
|
215
241
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -219,10 +245,12 @@ declare const ImpEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
219
245
|
error: z.ZodOptional<z.ZodString>;
|
|
220
246
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
221
247
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
248
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
222
249
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
223
250
|
agent: "agent";
|
|
224
251
|
firecracker: "firecracker";
|
|
225
252
|
impd: "impd";
|
|
253
|
+
ipv6: "ipv6";
|
|
226
254
|
kernel: "kernel";
|
|
227
255
|
}>>>>;
|
|
228
256
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -289,6 +317,10 @@ declare const ImageSchema: z.ZodObject<{
|
|
|
289
317
|
name: z.ZodString;
|
|
290
318
|
ref: z.ZodString;
|
|
291
319
|
digest: z.ZodString;
|
|
320
|
+
source: z.ZodEnum<{
|
|
321
|
+
imp: "imp";
|
|
322
|
+
oci: "oci";
|
|
323
|
+
}>;
|
|
292
324
|
createdAt: z.ZodDate;
|
|
293
325
|
sizeBytes: z.ZodInt;
|
|
294
326
|
}, z.core.$strip>;
|
|
@@ -340,6 +372,13 @@ declare const impContract: {
|
|
|
340
372
|
port: z.ZodInt;
|
|
341
373
|
httpPort: z.ZodInt;
|
|
342
374
|
url: z.ZodURL;
|
|
375
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
376
|
+
auth: z.ZodEnum<{
|
|
377
|
+
basic: "basic";
|
|
378
|
+
none: "none";
|
|
379
|
+
token: "token";
|
|
380
|
+
}>;
|
|
381
|
+
}, z.core.$strip>>;
|
|
343
382
|
createdAt: z.ZodDate;
|
|
344
383
|
lastActiveAt: z.ZodDate;
|
|
345
384
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -349,10 +388,12 @@ declare const impContract: {
|
|
|
349
388
|
error: z.ZodOptional<z.ZodString>;
|
|
350
389
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
351
390
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
391
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
352
392
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
353
393
|
agent: "agent";
|
|
354
394
|
firecracker: "firecracker";
|
|
355
395
|
impd: "impd";
|
|
396
|
+
ipv6: "ipv6";
|
|
356
397
|
kernel: "kernel";
|
|
357
398
|
}>>>>;
|
|
358
399
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -486,6 +527,13 @@ declare const impContract: {
|
|
|
486
527
|
port: z.ZodInt;
|
|
487
528
|
httpPort: z.ZodInt;
|
|
488
529
|
url: z.ZodURL;
|
|
530
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
531
|
+
auth: z.ZodEnum<{
|
|
532
|
+
basic: "basic";
|
|
533
|
+
none: "none";
|
|
534
|
+
token: "token";
|
|
535
|
+
}>;
|
|
536
|
+
}, z.core.$strip>>;
|
|
489
537
|
createdAt: z.ZodDate;
|
|
490
538
|
lastActiveAt: z.ZodDate;
|
|
491
539
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -495,10 +543,12 @@ declare const impContract: {
|
|
|
495
543
|
error: z.ZodOptional<z.ZodString>;
|
|
496
544
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
497
545
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
546
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
498
547
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
499
548
|
agent: "agent";
|
|
500
549
|
firecracker: "firecracker";
|
|
501
550
|
impd: "impd";
|
|
551
|
+
ipv6: "ipv6";
|
|
502
552
|
kernel: "kernel";
|
|
503
553
|
}>>>>;
|
|
504
554
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -634,6 +684,13 @@ declare const impContract: {
|
|
|
634
684
|
port: z.ZodInt;
|
|
635
685
|
httpPort: z.ZodInt;
|
|
636
686
|
url: z.ZodURL;
|
|
687
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
688
|
+
auth: z.ZodEnum<{
|
|
689
|
+
basic: "basic";
|
|
690
|
+
none: "none";
|
|
691
|
+
token: "token";
|
|
692
|
+
}>;
|
|
693
|
+
}, z.core.$strip>>;
|
|
637
694
|
createdAt: z.ZodDate;
|
|
638
695
|
lastActiveAt: z.ZodDate;
|
|
639
696
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -643,10 +700,12 @@ declare const impContract: {
|
|
|
643
700
|
error: z.ZodOptional<z.ZodString>;
|
|
644
701
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
645
702
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
703
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
646
704
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
647
705
|
agent: "agent";
|
|
648
706
|
firecracker: "firecracker";
|
|
649
707
|
impd: "impd";
|
|
708
|
+
ipv6: "ipv6";
|
|
650
709
|
kernel: "kernel";
|
|
651
710
|
}>>>>;
|
|
652
711
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -873,6 +932,13 @@ declare const impContract: {
|
|
|
873
932
|
port: z.ZodInt;
|
|
874
933
|
httpPort: z.ZodInt;
|
|
875
934
|
url: z.ZodURL;
|
|
935
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
936
|
+
auth: z.ZodEnum<{
|
|
937
|
+
basic: "basic";
|
|
938
|
+
none: "none";
|
|
939
|
+
token: "token";
|
|
940
|
+
}>;
|
|
941
|
+
}, z.core.$strip>>;
|
|
876
942
|
createdAt: z.ZodDate;
|
|
877
943
|
lastActiveAt: z.ZodDate;
|
|
878
944
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -882,10 +948,12 @@ declare const impContract: {
|
|
|
882
948
|
error: z.ZodOptional<z.ZodString>;
|
|
883
949
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
884
950
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
951
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
885
952
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
886
953
|
agent: "agent";
|
|
887
954
|
firecracker: "firecracker";
|
|
888
955
|
impd: "impd";
|
|
956
|
+
ipv6: "ipv6";
|
|
889
957
|
kernel: "kernel";
|
|
890
958
|
}>>>>;
|
|
891
959
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -1021,6 +1089,13 @@ declare const impContract: {
|
|
|
1021
1089
|
port: z.ZodInt;
|
|
1022
1090
|
httpPort: z.ZodInt;
|
|
1023
1091
|
url: z.ZodURL;
|
|
1092
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
1093
|
+
auth: z.ZodEnum<{
|
|
1094
|
+
basic: "basic";
|
|
1095
|
+
none: "none";
|
|
1096
|
+
token: "token";
|
|
1097
|
+
}>;
|
|
1098
|
+
}, z.core.$strip>>;
|
|
1024
1099
|
createdAt: z.ZodDate;
|
|
1025
1100
|
lastActiveAt: z.ZodDate;
|
|
1026
1101
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -1030,10 +1105,12 @@ declare const impContract: {
|
|
|
1030
1105
|
error: z.ZodOptional<z.ZodString>;
|
|
1031
1106
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
1032
1107
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
1108
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
1033
1109
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
1034
1110
|
agent: "agent";
|
|
1035
1111
|
firecracker: "firecracker";
|
|
1036
1112
|
impd: "impd";
|
|
1113
|
+
ipv6: "ipv6";
|
|
1037
1114
|
kernel: "kernel";
|
|
1038
1115
|
}>>>>;
|
|
1039
1116
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -1169,6 +1246,13 @@ declare const impContract: {
|
|
|
1169
1246
|
port: z.ZodInt;
|
|
1170
1247
|
httpPort: z.ZodInt;
|
|
1171
1248
|
url: z.ZodURL;
|
|
1249
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
1250
|
+
auth: z.ZodEnum<{
|
|
1251
|
+
basic: "basic";
|
|
1252
|
+
none: "none";
|
|
1253
|
+
token: "token";
|
|
1254
|
+
}>;
|
|
1255
|
+
}, z.core.$strip>>;
|
|
1172
1256
|
createdAt: z.ZodDate;
|
|
1173
1257
|
lastActiveAt: z.ZodDate;
|
|
1174
1258
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -1178,10 +1262,12 @@ declare const impContract: {
|
|
|
1178
1262
|
error: z.ZodOptional<z.ZodString>;
|
|
1179
1263
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
1180
1264
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
1265
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
1181
1266
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
1182
1267
|
agent: "agent";
|
|
1183
1268
|
firecracker: "firecracker";
|
|
1184
1269
|
impd: "impd";
|
|
1270
|
+
ipv6: "ipv6";
|
|
1185
1271
|
kernel: "kernel";
|
|
1186
1272
|
}>>>>;
|
|
1187
1273
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -1318,6 +1404,13 @@ declare const impContract: {
|
|
|
1318
1404
|
port: z.ZodInt;
|
|
1319
1405
|
httpPort: z.ZodInt;
|
|
1320
1406
|
url: z.ZodURL;
|
|
1407
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
1408
|
+
auth: z.ZodEnum<{
|
|
1409
|
+
basic: "basic";
|
|
1410
|
+
none: "none";
|
|
1411
|
+
token: "token";
|
|
1412
|
+
}>;
|
|
1413
|
+
}, z.core.$strip>>;
|
|
1321
1414
|
createdAt: z.ZodDate;
|
|
1322
1415
|
lastActiveAt: z.ZodDate;
|
|
1323
1416
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -1327,10 +1420,12 @@ declare const impContract: {
|
|
|
1327
1420
|
error: z.ZodOptional<z.ZodString>;
|
|
1328
1421
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
1329
1422
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
1423
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
1330
1424
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
1331
1425
|
agent: "agent";
|
|
1332
1426
|
firecracker: "firecracker";
|
|
1333
1427
|
impd: "impd";
|
|
1428
|
+
ipv6: "ipv6";
|
|
1334
1429
|
kernel: "kernel";
|
|
1335
1430
|
}>>>>;
|
|
1336
1431
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -1467,6 +1562,13 @@ declare const impContract: {
|
|
|
1467
1562
|
port: z.ZodInt;
|
|
1468
1563
|
httpPort: z.ZodInt;
|
|
1469
1564
|
url: z.ZodURL;
|
|
1565
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
1566
|
+
auth: z.ZodEnum<{
|
|
1567
|
+
basic: "basic";
|
|
1568
|
+
none: "none";
|
|
1569
|
+
token: "token";
|
|
1570
|
+
}>;
|
|
1571
|
+
}, z.core.$strip>>;
|
|
1470
1572
|
createdAt: z.ZodDate;
|
|
1471
1573
|
lastActiveAt: z.ZodDate;
|
|
1472
1574
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -1476,10 +1578,12 @@ declare const impContract: {
|
|
|
1476
1578
|
error: z.ZodOptional<z.ZodString>;
|
|
1477
1579
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
1478
1580
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
1581
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
1479
1582
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
1480
1583
|
agent: "agent";
|
|
1481
1584
|
firecracker: "firecracker";
|
|
1482
1585
|
impd: "impd";
|
|
1586
|
+
ipv6: "ipv6";
|
|
1483
1587
|
kernel: "kernel";
|
|
1484
1588
|
}>>>>;
|
|
1485
1589
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -1616,6 +1720,13 @@ declare const impContract: {
|
|
|
1616
1720
|
port: z.ZodInt;
|
|
1617
1721
|
httpPort: z.ZodInt;
|
|
1618
1722
|
url: z.ZodURL;
|
|
1723
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
1724
|
+
auth: z.ZodEnum<{
|
|
1725
|
+
basic: "basic";
|
|
1726
|
+
none: "none";
|
|
1727
|
+
token: "token";
|
|
1728
|
+
}>;
|
|
1729
|
+
}, z.core.$strip>>;
|
|
1619
1730
|
createdAt: z.ZodDate;
|
|
1620
1731
|
lastActiveAt: z.ZodDate;
|
|
1621
1732
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -1625,10 +1736,12 @@ declare const impContract: {
|
|
|
1625
1736
|
error: z.ZodOptional<z.ZodString>;
|
|
1626
1737
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
1627
1738
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
1739
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
1628
1740
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
1629
1741
|
agent: "agent";
|
|
1630
1742
|
firecracker: "firecracker";
|
|
1631
1743
|
impd: "impd";
|
|
1744
|
+
ipv6: "ipv6";
|
|
1632
1745
|
kernel: "kernel";
|
|
1633
1746
|
}>>>>;
|
|
1634
1747
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -1741,6 +1854,7 @@ declare const impContract: {
|
|
|
1741
1854
|
}, z.core.$strip>, z.ZodObject<{
|
|
1742
1855
|
local: z.ZodURL;
|
|
1743
1856
|
https: z.ZodNullable<z.ZodURL>;
|
|
1857
|
+
public: z.ZodNullable<z.ZodURL>;
|
|
1744
1858
|
service: z.ZodNullable<z.ZodURL>;
|
|
1745
1859
|
tailnet: z.ZodNullable<z.ZodURL>;
|
|
1746
1860
|
}, z.core.$strip>, import("@orpc/contract").MergedErrorMap<Record<never, never>, {
|
|
@@ -2036,6 +2150,270 @@ declare const impContract: {
|
|
|
2036
2150
|
readonly status: 409;
|
|
2037
2151
|
};
|
|
2038
2152
|
}>, Record<never, never>>;
|
|
2153
|
+
expose: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<z.ZodObject<{
|
|
2154
|
+
name: z.ZodString;
|
|
2155
|
+
auth: z.ZodDefault<z.ZodEnum<{
|
|
2156
|
+
basic: "basic";
|
|
2157
|
+
none: "none";
|
|
2158
|
+
token: "token";
|
|
2159
|
+
}>>;
|
|
2160
|
+
user: z.ZodOptional<z.ZodString>;
|
|
2161
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2162
|
+
url: z.ZodURL;
|
|
2163
|
+
auth: z.ZodEnum<{
|
|
2164
|
+
basic: "basic";
|
|
2165
|
+
none: "none";
|
|
2166
|
+
token: "token";
|
|
2167
|
+
}>;
|
|
2168
|
+
user: z.ZodNullable<z.ZodString>;
|
|
2169
|
+
credential: z.ZodNullable<z.ZodString>;
|
|
2170
|
+
warning: z.ZodOptional<z.ZodString>;
|
|
2171
|
+
}, z.core.$strip>, import("@orpc/contract").MergedErrorMap<Record<never, never>, {
|
|
2172
|
+
NOT_FOUND: {
|
|
2173
|
+
readonly message: "Not found";
|
|
2174
|
+
readonly data: z.ZodObject<{
|
|
2175
|
+
kind: z.ZodEnum<{
|
|
2176
|
+
backup: "backup";
|
|
2177
|
+
checkpoint: "checkpoint";
|
|
2178
|
+
grant: "grant";
|
|
2179
|
+
image: "image";
|
|
2180
|
+
imp: "imp";
|
|
2181
|
+
secret: "secret";
|
|
2182
|
+
service: "service";
|
|
2183
|
+
session: "session";
|
|
2184
|
+
"ssh-key": "ssh-key";
|
|
2185
|
+
token: "token";
|
|
2186
|
+
}>;
|
|
2187
|
+
name: z.ZodString;
|
|
2188
|
+
}, z.core.$strip>;
|
|
2189
|
+
};
|
|
2190
|
+
CONFLICT: {
|
|
2191
|
+
readonly message: "Already exists";
|
|
2192
|
+
readonly data: z.ZodObject<{
|
|
2193
|
+
kind: z.ZodEnum<{
|
|
2194
|
+
backup: "backup";
|
|
2195
|
+
checkpoint: "checkpoint";
|
|
2196
|
+
grant: "grant";
|
|
2197
|
+
image: "image";
|
|
2198
|
+
imp: "imp";
|
|
2199
|
+
secret: "secret";
|
|
2200
|
+
service: "service";
|
|
2201
|
+
session: "session";
|
|
2202
|
+
"ssh-key": "ssh-key";
|
|
2203
|
+
token: "token";
|
|
2204
|
+
}>;
|
|
2205
|
+
name: z.ZodString;
|
|
2206
|
+
}, z.core.$strip>;
|
|
2207
|
+
};
|
|
2208
|
+
FORBIDDEN: {
|
|
2209
|
+
readonly message: "Not allowed";
|
|
2210
|
+
};
|
|
2211
|
+
PRECONDITION_FAILED: {
|
|
2212
|
+
readonly message: "Not possible on this host";
|
|
2213
|
+
};
|
|
2214
|
+
RAM_BUDGET_EXCEEDED: {
|
|
2215
|
+
readonly message: "Not enough RAM budget, even after sleeping idle imps";
|
|
2216
|
+
readonly status: 503;
|
|
2217
|
+
readonly data: z.ZodObject<{
|
|
2218
|
+
budgetMib: z.ZodInt;
|
|
2219
|
+
usedMib: z.ZodInt;
|
|
2220
|
+
requestedMib: z.ZodInt;
|
|
2221
|
+
}, z.core.$strip>;
|
|
2222
|
+
};
|
|
2223
|
+
SERVICE_UNAVAILABLE: {
|
|
2224
|
+
readonly message: "impd is stopping";
|
|
2225
|
+
};
|
|
2226
|
+
INVALID_STATE: {
|
|
2227
|
+
readonly message: "The imp is not in a state that allows this";
|
|
2228
|
+
readonly status: 409;
|
|
2229
|
+
readonly data: z.ZodObject<{
|
|
2230
|
+
state: z.ZodEnum<{
|
|
2231
|
+
creating: "creating";
|
|
2232
|
+
error: "error";
|
|
2233
|
+
running: "running";
|
|
2234
|
+
sleeping: "sleeping";
|
|
2235
|
+
stopped: "stopped";
|
|
2236
|
+
}>;
|
|
2237
|
+
allowed: z.ZodArray<z.ZodEnum<{
|
|
2238
|
+
creating: "creating";
|
|
2239
|
+
error: "error";
|
|
2240
|
+
running: "running";
|
|
2241
|
+
sleeping: "sleeping";
|
|
2242
|
+
stopped: "stopped";
|
|
2243
|
+
}>>;
|
|
2244
|
+
}, z.core.$strip>;
|
|
2245
|
+
};
|
|
2246
|
+
DISK_FULL: {
|
|
2247
|
+
readonly message: "Not enough free disk on the host";
|
|
2248
|
+
readonly status: 507;
|
|
2249
|
+
readonly data: z.ZodObject<{
|
|
2250
|
+
availableBytes: z.ZodInt;
|
|
2251
|
+
reserveBytes: z.ZodInt;
|
|
2252
|
+
requestedBytes: z.ZodInt;
|
|
2253
|
+
}, z.core.$strip>;
|
|
2254
|
+
};
|
|
2255
|
+
AGENT_OUTDATED: {
|
|
2256
|
+
readonly message: "The imp's agent is too old for this";
|
|
2257
|
+
readonly status: 409;
|
|
2258
|
+
};
|
|
2259
|
+
}>, Record<never, never>>;
|
|
2260
|
+
unexpose: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<z.ZodObject<{
|
|
2261
|
+
name: z.ZodString;
|
|
2262
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2263
|
+
id: z.ZodString;
|
|
2264
|
+
name: z.ZodString;
|
|
2265
|
+
image: z.ZodString;
|
|
2266
|
+
state: z.ZodEnum<{
|
|
2267
|
+
creating: "creating";
|
|
2268
|
+
error: "error";
|
|
2269
|
+
running: "running";
|
|
2270
|
+
sleeping: "sleeping";
|
|
2271
|
+
stopped: "stopped";
|
|
2272
|
+
}>;
|
|
2273
|
+
vcpus: z.ZodInt;
|
|
2274
|
+
memoryMib: z.ZodInt;
|
|
2275
|
+
diskMib: z.ZodInt;
|
|
2276
|
+
diskUsage: z.ZodOptional<z.ZodObject<{
|
|
2277
|
+
exclusiveBytes: z.ZodInt;
|
|
2278
|
+
sharedBytes: z.ZodInt;
|
|
2279
|
+
measuredAt: z.ZodDate;
|
|
2280
|
+
isPartial: z.ZodBoolean;
|
|
2281
|
+
isUpperBound: z.ZodBoolean;
|
|
2282
|
+
}, z.core.$strip>>;
|
|
2283
|
+
ip: z.ZodIPv4;
|
|
2284
|
+
slot: z.ZodInt;
|
|
2285
|
+
port: z.ZodInt;
|
|
2286
|
+
httpPort: z.ZodInt;
|
|
2287
|
+
url: z.ZodURL;
|
|
2288
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
2289
|
+
auth: z.ZodEnum<{
|
|
2290
|
+
basic: "basic";
|
|
2291
|
+
none: "none";
|
|
2292
|
+
token: "token";
|
|
2293
|
+
}>;
|
|
2294
|
+
}, z.core.$strip>>;
|
|
2295
|
+
createdAt: z.ZodDate;
|
|
2296
|
+
lastActiveAt: z.ZodDate;
|
|
2297
|
+
ramMib: z.ZodOptional<z.ZodInt>;
|
|
2298
|
+
rssMib: z.ZodOptional<z.ZodInt>;
|
|
2299
|
+
sleptAt: z.ZodOptional<z.ZodDate>;
|
|
2300
|
+
holdUntil: z.ZodOptional<z.ZodDate>;
|
|
2301
|
+
error: z.ZodOptional<z.ZodString>;
|
|
2302
|
+
sessions: z.ZodOptional<z.ZodInt>;
|
|
2303
|
+
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
2304
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
2305
|
+
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
2306
|
+
agent: "agent";
|
|
2307
|
+
firecracker: "firecracker";
|
|
2308
|
+
impd: "impd";
|
|
2309
|
+
ipv6: "ipv6";
|
|
2310
|
+
kernel: "kernel";
|
|
2311
|
+
}>>>>;
|
|
2312
|
+
cpu: z.ZodOptional<z.ZodObject<{
|
|
2313
|
+
limit: z.ZodNullable<z.ZodNumber>;
|
|
2314
|
+
weight: z.ZodInt;
|
|
2315
|
+
}, z.core.$strip>>;
|
|
2316
|
+
resources: z.ZodOptional<z.ZodObject<{
|
|
2317
|
+
wakeCount: z.ZodInt;
|
|
2318
|
+
awakeMs: z.ZodInt;
|
|
2319
|
+
sample: z.ZodOptional<z.ZodObject<{
|
|
2320
|
+
measuredAt: z.ZodDate;
|
|
2321
|
+
since: z.ZodDate;
|
|
2322
|
+
cpuPercent: z.ZodOptional<z.ZodNumber>;
|
|
2323
|
+
cpuThrottledMs: z.ZodInt;
|
|
2324
|
+
netRxBytes: z.ZodInt;
|
|
2325
|
+
netTxBytes: z.ZodInt;
|
|
2326
|
+
}, z.core.$strip>>;
|
|
2327
|
+
}, z.core.$strip>>;
|
|
2328
|
+
}, z.core.$strip>, import("@orpc/contract").MergedErrorMap<Record<never, never>, {
|
|
2329
|
+
NOT_FOUND: {
|
|
2330
|
+
readonly message: "Not found";
|
|
2331
|
+
readonly data: z.ZodObject<{
|
|
2332
|
+
kind: z.ZodEnum<{
|
|
2333
|
+
backup: "backup";
|
|
2334
|
+
checkpoint: "checkpoint";
|
|
2335
|
+
grant: "grant";
|
|
2336
|
+
image: "image";
|
|
2337
|
+
imp: "imp";
|
|
2338
|
+
secret: "secret";
|
|
2339
|
+
service: "service";
|
|
2340
|
+
session: "session";
|
|
2341
|
+
"ssh-key": "ssh-key";
|
|
2342
|
+
token: "token";
|
|
2343
|
+
}>;
|
|
2344
|
+
name: z.ZodString;
|
|
2345
|
+
}, z.core.$strip>;
|
|
2346
|
+
};
|
|
2347
|
+
CONFLICT: {
|
|
2348
|
+
readonly message: "Already exists";
|
|
2349
|
+
readonly data: z.ZodObject<{
|
|
2350
|
+
kind: z.ZodEnum<{
|
|
2351
|
+
backup: "backup";
|
|
2352
|
+
checkpoint: "checkpoint";
|
|
2353
|
+
grant: "grant";
|
|
2354
|
+
image: "image";
|
|
2355
|
+
imp: "imp";
|
|
2356
|
+
secret: "secret";
|
|
2357
|
+
service: "service";
|
|
2358
|
+
session: "session";
|
|
2359
|
+
"ssh-key": "ssh-key";
|
|
2360
|
+
token: "token";
|
|
2361
|
+
}>;
|
|
2362
|
+
name: z.ZodString;
|
|
2363
|
+
}, z.core.$strip>;
|
|
2364
|
+
};
|
|
2365
|
+
FORBIDDEN: {
|
|
2366
|
+
readonly message: "Not allowed";
|
|
2367
|
+
};
|
|
2368
|
+
PRECONDITION_FAILED: {
|
|
2369
|
+
readonly message: "Not possible on this host";
|
|
2370
|
+
};
|
|
2371
|
+
RAM_BUDGET_EXCEEDED: {
|
|
2372
|
+
readonly message: "Not enough RAM budget, even after sleeping idle imps";
|
|
2373
|
+
readonly status: 503;
|
|
2374
|
+
readonly data: z.ZodObject<{
|
|
2375
|
+
budgetMib: z.ZodInt;
|
|
2376
|
+
usedMib: z.ZodInt;
|
|
2377
|
+
requestedMib: z.ZodInt;
|
|
2378
|
+
}, z.core.$strip>;
|
|
2379
|
+
};
|
|
2380
|
+
SERVICE_UNAVAILABLE: {
|
|
2381
|
+
readonly message: "impd is stopping";
|
|
2382
|
+
};
|
|
2383
|
+
INVALID_STATE: {
|
|
2384
|
+
readonly message: "The imp is not in a state that allows this";
|
|
2385
|
+
readonly status: 409;
|
|
2386
|
+
readonly data: z.ZodObject<{
|
|
2387
|
+
state: z.ZodEnum<{
|
|
2388
|
+
creating: "creating";
|
|
2389
|
+
error: "error";
|
|
2390
|
+
running: "running";
|
|
2391
|
+
sleeping: "sleeping";
|
|
2392
|
+
stopped: "stopped";
|
|
2393
|
+
}>;
|
|
2394
|
+
allowed: z.ZodArray<z.ZodEnum<{
|
|
2395
|
+
creating: "creating";
|
|
2396
|
+
error: "error";
|
|
2397
|
+
running: "running";
|
|
2398
|
+
sleeping: "sleeping";
|
|
2399
|
+
stopped: "stopped";
|
|
2400
|
+
}>>;
|
|
2401
|
+
}, z.core.$strip>;
|
|
2402
|
+
};
|
|
2403
|
+
DISK_FULL: {
|
|
2404
|
+
readonly message: "Not enough free disk on the host";
|
|
2405
|
+
readonly status: 507;
|
|
2406
|
+
readonly data: z.ZodObject<{
|
|
2407
|
+
availableBytes: z.ZodInt;
|
|
2408
|
+
reserveBytes: z.ZodInt;
|
|
2409
|
+
requestedBytes: z.ZodInt;
|
|
2410
|
+
}, z.core.$strip>;
|
|
2411
|
+
};
|
|
2412
|
+
AGENT_OUTDATED: {
|
|
2413
|
+
readonly message: "The imp's agent is too old for this";
|
|
2414
|
+
readonly status: 409;
|
|
2415
|
+
};
|
|
2416
|
+
}>, Record<never, never>>;
|
|
2039
2417
|
fork: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<z.ZodObject<{
|
|
2040
2418
|
source: z.ZodString;
|
|
2041
2419
|
name: z.ZodString;
|
|
@@ -2066,6 +2444,13 @@ declare const impContract: {
|
|
|
2066
2444
|
port: z.ZodInt;
|
|
2067
2445
|
httpPort: z.ZodInt;
|
|
2068
2446
|
url: z.ZodURL;
|
|
2447
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
2448
|
+
auth: z.ZodEnum<{
|
|
2449
|
+
basic: "basic";
|
|
2450
|
+
none: "none";
|
|
2451
|
+
token: "token";
|
|
2452
|
+
}>;
|
|
2453
|
+
}, z.core.$strip>>;
|
|
2069
2454
|
createdAt: z.ZodDate;
|
|
2070
2455
|
lastActiveAt: z.ZodDate;
|
|
2071
2456
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -2075,10 +2460,12 @@ declare const impContract: {
|
|
|
2075
2460
|
error: z.ZodOptional<z.ZodString>;
|
|
2076
2461
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
2077
2462
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
2463
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
2078
2464
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
2079
2465
|
agent: "agent";
|
|
2080
2466
|
firecracker: "firecracker";
|
|
2081
2467
|
impd: "impd";
|
|
2468
|
+
ipv6: "ipv6";
|
|
2082
2469
|
kernel: "kernel";
|
|
2083
2470
|
}>>>>;
|
|
2084
2471
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -2191,6 +2578,7 @@ declare const impContract: {
|
|
|
2191
2578
|
cpuLimit: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
2192
2579
|
cpuWeight: z.ZodOptional<z.ZodInt>;
|
|
2193
2580
|
vcpus: z.ZodOptional<z.ZodInt>;
|
|
2581
|
+
httpPort: z.ZodOptional<z.ZodInt>;
|
|
2194
2582
|
}, z.core.$strip>, z.ZodObject<{
|
|
2195
2583
|
id: z.ZodString;
|
|
2196
2584
|
name: z.ZodString;
|
|
@@ -2217,6 +2605,13 @@ declare const impContract: {
|
|
|
2217
2605
|
port: z.ZodInt;
|
|
2218
2606
|
httpPort: z.ZodInt;
|
|
2219
2607
|
url: z.ZodURL;
|
|
2608
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
2609
|
+
auth: z.ZodEnum<{
|
|
2610
|
+
basic: "basic";
|
|
2611
|
+
none: "none";
|
|
2612
|
+
token: "token";
|
|
2613
|
+
}>;
|
|
2614
|
+
}, z.core.$strip>>;
|
|
2220
2615
|
createdAt: z.ZodDate;
|
|
2221
2616
|
lastActiveAt: z.ZodDate;
|
|
2222
2617
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -2226,10 +2621,12 @@ declare const impContract: {
|
|
|
2226
2621
|
error: z.ZodOptional<z.ZodString>;
|
|
2227
2622
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
2228
2623
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
2624
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
2229
2625
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
2230
2626
|
agent: "agent";
|
|
2231
2627
|
firecracker: "firecracker";
|
|
2232
2628
|
impd: "impd";
|
|
2629
|
+
ipv6: "ipv6";
|
|
2233
2630
|
kernel: "kernel";
|
|
2234
2631
|
}>>>>;
|
|
2235
2632
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -2563,6 +2960,13 @@ declare const impContract: {
|
|
|
2563
2960
|
port: z.ZodInt;
|
|
2564
2961
|
httpPort: z.ZodInt;
|
|
2565
2962
|
url: z.ZodURL;
|
|
2963
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
2964
|
+
auth: z.ZodEnum<{
|
|
2965
|
+
basic: "basic";
|
|
2966
|
+
none: "none";
|
|
2967
|
+
token: "token";
|
|
2968
|
+
}>;
|
|
2969
|
+
}, z.core.$strip>>;
|
|
2566
2970
|
createdAt: z.ZodDate;
|
|
2567
2971
|
lastActiveAt: z.ZodDate;
|
|
2568
2972
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -2572,10 +2976,12 @@ declare const impContract: {
|
|
|
2572
2976
|
error: z.ZodOptional<z.ZodString>;
|
|
2573
2977
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
2574
2978
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
2979
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
2575
2980
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
2576
2981
|
agent: "agent";
|
|
2577
2982
|
firecracker: "firecracker";
|
|
2578
2983
|
impd: "impd";
|
|
2984
|
+
ipv6: "ipv6";
|
|
2579
2985
|
kernel: "kernel";
|
|
2580
2986
|
}>>>>;
|
|
2581
2987
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -3009,6 +3415,13 @@ declare const impContract: {
|
|
|
3009
3415
|
port: z.ZodInt;
|
|
3010
3416
|
httpPort: z.ZodInt;
|
|
3011
3417
|
url: z.ZodURL;
|
|
3418
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
3419
|
+
auth: z.ZodEnum<{
|
|
3420
|
+
basic: "basic";
|
|
3421
|
+
none: "none";
|
|
3422
|
+
token: "token";
|
|
3423
|
+
}>;
|
|
3424
|
+
}, z.core.$strip>>;
|
|
3012
3425
|
createdAt: z.ZodDate;
|
|
3013
3426
|
lastActiveAt: z.ZodDate;
|
|
3014
3427
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -3018,10 +3431,12 @@ declare const impContract: {
|
|
|
3018
3431
|
error: z.ZodOptional<z.ZodString>;
|
|
3019
3432
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
3020
3433
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
3434
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
3021
3435
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
3022
3436
|
agent: "agent";
|
|
3023
3437
|
firecracker: "firecracker";
|
|
3024
3438
|
impd: "impd";
|
|
3439
|
+
ipv6: "ipv6";
|
|
3025
3440
|
kernel: "kernel";
|
|
3026
3441
|
}>>>>;
|
|
3027
3442
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -3233,6 +3648,10 @@ declare const impContract: {
|
|
|
3233
3648
|
name: z.ZodString;
|
|
3234
3649
|
ref: z.ZodString;
|
|
3235
3650
|
digest: z.ZodString;
|
|
3651
|
+
source: z.ZodEnum<{
|
|
3652
|
+
imp: "imp";
|
|
3653
|
+
oci: "oci";
|
|
3654
|
+
}>;
|
|
3236
3655
|
createdAt: z.ZodDate;
|
|
3237
3656
|
sizeBytes: z.ZodInt;
|
|
3238
3657
|
}, z.core.$strip>>, import("@orpc/contract").MergedErrorMap<Record<never, never>, {
|
|
@@ -3324,14 +3743,21 @@ declare const impContract: {
|
|
|
3324
3743
|
readonly status: 409;
|
|
3325
3744
|
};
|
|
3326
3745
|
}>, Record<never, never>>;
|
|
3327
|
-
add: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<z.ZodObject<{
|
|
3746
|
+
add: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<z.ZodUnion<readonly [z.ZodObject<{
|
|
3328
3747
|
ref: z.ZodString;
|
|
3329
3748
|
name: z.ZodOptional<z.ZodString>;
|
|
3330
3749
|
}, z.core.$strip>, z.ZodObject<{
|
|
3750
|
+
imp: z.ZodString;
|
|
3751
|
+
name: z.ZodString;
|
|
3752
|
+
}, z.core.$strip>]>, z.ZodObject<{
|
|
3331
3753
|
id: z.ZodString;
|
|
3332
3754
|
name: z.ZodString;
|
|
3333
3755
|
ref: z.ZodString;
|
|
3334
3756
|
digest: z.ZodString;
|
|
3757
|
+
source: z.ZodEnum<{
|
|
3758
|
+
imp: "imp";
|
|
3759
|
+
oci: "oci";
|
|
3760
|
+
}>;
|
|
3335
3761
|
createdAt: z.ZodDate;
|
|
3336
3762
|
sizeBytes: z.ZodInt;
|
|
3337
3763
|
}, z.core.$strip>, import("@orpc/contract").MergedErrorMap<Record<never, never>, {
|
|
@@ -3432,6 +3858,10 @@ declare const impContract: {
|
|
|
3432
3858
|
name: z.ZodString;
|
|
3433
3859
|
ref: z.ZodString;
|
|
3434
3860
|
digest: z.ZodString;
|
|
3861
|
+
source: z.ZodEnum<{
|
|
3862
|
+
imp: "imp";
|
|
3863
|
+
oci: "oci";
|
|
3864
|
+
}>;
|
|
3435
3865
|
createdAt: z.ZodDate;
|
|
3436
3866
|
sizeBytes: z.ZodInt;
|
|
3437
3867
|
}, z.core.$strip>, import("@orpc/contract").MergedErrorMap<Record<never, never>, {
|
|
@@ -3915,36 +4345,39 @@ declare const impContract: {
|
|
|
3915
4345
|
services: {
|
|
3916
4346
|
list: import("@orpc/contract").ContractProcedureBuilderWithInputOutput<z.ZodObject<{
|
|
3917
4347
|
name: z.ZodString;
|
|
3918
|
-
}, z.core.$strip>, z.
|
|
3919
|
-
|
|
3920
|
-
|
|
3921
|
-
|
|
3922
|
-
|
|
3923
|
-
|
|
3924
|
-
|
|
3925
|
-
|
|
3926
|
-
|
|
3927
|
-
|
|
3928
|
-
|
|
3929
|
-
|
|
3930
|
-
|
|
3931
|
-
|
|
3932
|
-
|
|
3933
|
-
|
|
3934
|
-
|
|
3935
|
-
|
|
3936
|
-
|
|
3937
|
-
|
|
3938
|
-
|
|
3939
|
-
|
|
3940
|
-
|
|
3941
|
-
|
|
3942
|
-
|
|
3943
|
-
|
|
3944
|
-
|
|
3945
|
-
|
|
3946
|
-
|
|
3947
|
-
|
|
4348
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
4349
|
+
services: z.ZodReadonly<z.ZodArray<z.ZodObject<{
|
|
4350
|
+
name: z.ZodString;
|
|
4351
|
+
state: z.ZodEnum<{
|
|
4352
|
+
backoff: "backoff";
|
|
4353
|
+
exited: "exited";
|
|
4354
|
+
running: "running";
|
|
4355
|
+
starting: "starting";
|
|
4356
|
+
stopped: "stopped";
|
|
4357
|
+
}>;
|
|
4358
|
+
pid: z.ZodNullable<z.ZodInt>;
|
|
4359
|
+
restarts: z.ZodInt;
|
|
4360
|
+
lastExit: z.ZodNullable<z.ZodObject<{
|
|
4361
|
+
code: z.ZodInt;
|
|
4362
|
+
signal: z.ZodNullable<z.ZodString>;
|
|
4363
|
+
}, z.core.$strip>>;
|
|
4364
|
+
argv: z.ZodReadonly<z.ZodArray<z.ZodString>>;
|
|
4365
|
+
envKeys: z.ZodReadonly<z.ZodArray<z.ZodString>>;
|
|
4366
|
+
cwd: z.ZodNullable<z.ZodString>;
|
|
4367
|
+
user: z.ZodNullable<z.ZodString>;
|
|
4368
|
+
restart: z.ZodEnum<{
|
|
4369
|
+
always: "always";
|
|
4370
|
+
never: "never";
|
|
4371
|
+
"on-failure": "on-failure";
|
|
4372
|
+
}>;
|
|
4373
|
+
source: z.ZodEnum<{
|
|
4374
|
+
api: "api";
|
|
4375
|
+
image: "image";
|
|
4376
|
+
}>;
|
|
4377
|
+
root: z.ZodBoolean;
|
|
4378
|
+
}, z.core.$strip>>>;
|
|
4379
|
+
recorded: z.ZodBoolean;
|
|
4380
|
+
}, z.core.$strip>, import("@orpc/contract").MergedErrorMap<Record<never, never>, {
|
|
3948
4381
|
NOT_FOUND: {
|
|
3949
4382
|
readonly message: "Not found";
|
|
3950
4383
|
readonly data: z.ZodObject<{
|
|
@@ -5282,6 +5715,9 @@ declare const impContract: {
|
|
|
5282
5715
|
port: number;
|
|
5283
5716
|
httpPort: number;
|
|
5284
5717
|
url: string;
|
|
5718
|
+
public?: {
|
|
5719
|
+
auth: "basic" | "none" | "token";
|
|
5720
|
+
} | undefined;
|
|
5285
5721
|
createdAt: Date;
|
|
5286
5722
|
lastActiveAt: Date;
|
|
5287
5723
|
ramMib?: number | undefined;
|
|
@@ -5291,7 +5727,8 @@ declare const impContract: {
|
|
|
5291
5727
|
error?: string | undefined;
|
|
5292
5728
|
sessions?: number | undefined;
|
|
5293
5729
|
coldBootReason?: string | undefined;
|
|
5294
|
-
|
|
5730
|
+
agentSilentSince?: Date | undefined;
|
|
5731
|
+
outdated?: readonly ("agent" | "firecracker" | "impd" | "ipv6" | "kernel")[] | undefined;
|
|
5295
5732
|
cpu?: {
|
|
5296
5733
|
limit: number | null;
|
|
5297
5734
|
weight: number;
|
|
@@ -5313,7 +5750,7 @@ declare const impContract: {
|
|
|
5313
5750
|
v: 1;
|
|
5314
5751
|
at: Date;
|
|
5315
5752
|
ev: "ImpChanged";
|
|
5316
|
-
reason: "adopted" | "booted" | "failed" | "held" | "repaired" | "resized" | "restored" | "slept" | "stopped" | "updated" | "woke";
|
|
5753
|
+
reason: "adopted" | "booted" | "exposed" | "failed" | "held" | "repaired" | "resized" | "restored" | "slept" | "stopped" | "updated" | "woke";
|
|
5317
5754
|
imp: {
|
|
5318
5755
|
id: string;
|
|
5319
5756
|
name: string;
|
|
@@ -5334,6 +5771,9 @@ declare const impContract: {
|
|
|
5334
5771
|
port: number;
|
|
5335
5772
|
httpPort: number;
|
|
5336
5773
|
url: string;
|
|
5774
|
+
public?: {
|
|
5775
|
+
auth: "basic" | "none" | "token";
|
|
5776
|
+
} | undefined;
|
|
5337
5777
|
createdAt: Date;
|
|
5338
5778
|
lastActiveAt: Date;
|
|
5339
5779
|
ramMib?: number | undefined;
|
|
@@ -5343,7 +5783,8 @@ declare const impContract: {
|
|
|
5343
5783
|
error?: string | undefined;
|
|
5344
5784
|
sessions?: number | undefined;
|
|
5345
5785
|
coldBootReason?: string | undefined;
|
|
5346
|
-
|
|
5786
|
+
agentSilentSince?: Date | undefined;
|
|
5787
|
+
outdated?: readonly ("agent" | "firecracker" | "impd" | "ipv6" | "kernel")[] | undefined;
|
|
5347
5788
|
cpu?: {
|
|
5348
5789
|
limit: number | null;
|
|
5349
5790
|
weight: number;
|
|
@@ -5391,6 +5832,9 @@ declare const impContract: {
|
|
|
5391
5832
|
port: number;
|
|
5392
5833
|
httpPort: number;
|
|
5393
5834
|
url: string;
|
|
5835
|
+
public?: {
|
|
5836
|
+
auth: "basic" | "none" | "token";
|
|
5837
|
+
} | undefined;
|
|
5394
5838
|
createdAt: Date;
|
|
5395
5839
|
lastActiveAt: Date;
|
|
5396
5840
|
ramMib?: number | undefined;
|
|
@@ -5400,7 +5844,8 @@ declare const impContract: {
|
|
|
5400
5844
|
error?: string | undefined;
|
|
5401
5845
|
sessions?: number | undefined;
|
|
5402
5846
|
coldBootReason?: string | undefined;
|
|
5403
|
-
|
|
5847
|
+
agentSilentSince?: Date | undefined;
|
|
5848
|
+
outdated?: readonly ("agent" | "firecracker" | "impd" | "ipv6" | "kernel")[] | undefined;
|
|
5404
5849
|
cpu?: {
|
|
5405
5850
|
limit: number | null;
|
|
5406
5851
|
weight: number;
|
|
@@ -5477,6 +5922,9 @@ declare const impContract: {
|
|
|
5477
5922
|
port: number;
|
|
5478
5923
|
httpPort: number;
|
|
5479
5924
|
url: string;
|
|
5925
|
+
public?: {
|
|
5926
|
+
auth: "basic" | "none" | "token";
|
|
5927
|
+
} | undefined;
|
|
5480
5928
|
createdAt: Date;
|
|
5481
5929
|
lastActiveAt: Date;
|
|
5482
5930
|
ramMib?: number | undefined;
|
|
@@ -5486,7 +5934,8 @@ declare const impContract: {
|
|
|
5486
5934
|
error?: string | undefined;
|
|
5487
5935
|
sessions?: number | undefined;
|
|
5488
5936
|
coldBootReason?: string | undefined;
|
|
5489
|
-
|
|
5937
|
+
agentSilentSince?: Date | undefined;
|
|
5938
|
+
outdated?: readonly ("agent" | "firecracker" | "impd" | "ipv6" | "kernel")[] | undefined;
|
|
5490
5939
|
cpu?: {
|
|
5491
5940
|
limit: number | null;
|
|
5492
5941
|
weight: number;
|
|
@@ -5508,7 +5957,7 @@ declare const impContract: {
|
|
|
5508
5957
|
v: 1;
|
|
5509
5958
|
at: Date;
|
|
5510
5959
|
ev: "ImpChanged";
|
|
5511
|
-
reason: "adopted" | "booted" | "failed" | "held" | "repaired" | "resized" | "restored" | "slept" | "stopped" | "updated" | "woke";
|
|
5960
|
+
reason: "adopted" | "booted" | "exposed" | "failed" | "held" | "repaired" | "resized" | "restored" | "slept" | "stopped" | "updated" | "woke";
|
|
5512
5961
|
imp: {
|
|
5513
5962
|
id: string;
|
|
5514
5963
|
name: string;
|
|
@@ -5529,6 +5978,9 @@ declare const impContract: {
|
|
|
5529
5978
|
port: number;
|
|
5530
5979
|
httpPort: number;
|
|
5531
5980
|
url: string;
|
|
5981
|
+
public?: {
|
|
5982
|
+
auth: "basic" | "none" | "token";
|
|
5983
|
+
} | undefined;
|
|
5532
5984
|
createdAt: Date;
|
|
5533
5985
|
lastActiveAt: Date;
|
|
5534
5986
|
ramMib?: number | undefined;
|
|
@@ -5538,7 +5990,8 @@ declare const impContract: {
|
|
|
5538
5990
|
error?: string | undefined;
|
|
5539
5991
|
sessions?: number | undefined;
|
|
5540
5992
|
coldBootReason?: string | undefined;
|
|
5541
|
-
|
|
5993
|
+
agentSilentSince?: Date | undefined;
|
|
5994
|
+
outdated?: readonly ("agent" | "firecracker" | "impd" | "ipv6" | "kernel")[] | undefined;
|
|
5542
5995
|
cpu?: {
|
|
5543
5996
|
limit: number | null;
|
|
5544
5997
|
weight: number;
|
|
@@ -5586,6 +6039,9 @@ declare const impContract: {
|
|
|
5586
6039
|
port: number;
|
|
5587
6040
|
httpPort: number;
|
|
5588
6041
|
url: string;
|
|
6042
|
+
public?: {
|
|
6043
|
+
auth: "basic" | "none" | "token";
|
|
6044
|
+
} | undefined;
|
|
5589
6045
|
createdAt: Date;
|
|
5590
6046
|
lastActiveAt: Date;
|
|
5591
6047
|
ramMib?: number | undefined;
|
|
@@ -5595,7 +6051,8 @@ declare const impContract: {
|
|
|
5595
6051
|
error?: string | undefined;
|
|
5596
6052
|
sessions?: number | undefined;
|
|
5597
6053
|
coldBootReason?: string | undefined;
|
|
5598
|
-
|
|
6054
|
+
agentSilentSince?: Date | undefined;
|
|
6055
|
+
outdated?: readonly ("agent" | "firecracker" | "impd" | "ipv6" | "kernel")[] | undefined;
|
|
5599
6056
|
cpu?: {
|
|
5600
6057
|
limit: number | null;
|
|
5601
6058
|
weight: number;
|
|
@@ -5753,6 +6210,7 @@ declare const impContract: {
|
|
|
5753
6210
|
firecracker: z.ZodInt;
|
|
5754
6211
|
kernel: z.ZodInt;
|
|
5755
6212
|
agent: z.ZodInt;
|
|
6213
|
+
ipv6: z.ZodOptional<z.ZodInt>;
|
|
5756
6214
|
}, z.core.$strip>;
|
|
5757
6215
|
}, z.core.$strip>;
|
|
5758
6216
|
firecrackerVersion: z.ZodNullable<z.ZodString>;
|
|
@@ -5792,6 +6250,15 @@ declare const impContract: {
|
|
|
5792
6250
|
hostCpus: z.ZodInt;
|
|
5793
6251
|
limitsEnforced: z.ZodBoolean;
|
|
5794
6252
|
}, z.core.$strip>>;
|
|
6253
|
+
public: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
6254
|
+
ip: z.ZodIPv4;
|
|
6255
|
+
imps: z.ZodInt;
|
|
6256
|
+
records: z.ZodNullable<z.ZodObject<{
|
|
6257
|
+
isOk: z.ZodBoolean;
|
|
6258
|
+
error: z.ZodNullable<z.ZodString>;
|
|
6259
|
+
at: z.ZodDate;
|
|
6260
|
+
}, z.core.$strip>>;
|
|
6261
|
+
}, z.core.$strip>>>;
|
|
5795
6262
|
}, z.core.$strip>, import("@orpc/contract").MergedErrorMap<Record<never, never>, {
|
|
5796
6263
|
NOT_FOUND: {
|
|
5797
6264
|
readonly message: "Not found";
|
|
@@ -6625,6 +7092,13 @@ declare const ImpSchema: z.ZodObject<{
|
|
|
6625
7092
|
port: z.ZodInt;
|
|
6626
7093
|
httpPort: z.ZodInt;
|
|
6627
7094
|
url: z.ZodURL;
|
|
7095
|
+
public: z.ZodOptional<z.ZodObject<{
|
|
7096
|
+
auth: z.ZodEnum<{
|
|
7097
|
+
basic: "basic";
|
|
7098
|
+
none: "none";
|
|
7099
|
+
token: "token";
|
|
7100
|
+
}>;
|
|
7101
|
+
}, z.core.$strip>>;
|
|
6628
7102
|
createdAt: z.ZodDate;
|
|
6629
7103
|
lastActiveAt: z.ZodDate;
|
|
6630
7104
|
ramMib: z.ZodOptional<z.ZodInt>;
|
|
@@ -6634,10 +7108,12 @@ declare const ImpSchema: z.ZodObject<{
|
|
|
6634
7108
|
error: z.ZodOptional<z.ZodString>;
|
|
6635
7109
|
sessions: z.ZodOptional<z.ZodInt>;
|
|
6636
7110
|
coldBootReason: z.ZodOptional<z.ZodString>;
|
|
7111
|
+
agentSilentSince: z.ZodOptional<z.ZodDate>;
|
|
6637
7112
|
outdated: z.ZodOptional<z.ZodReadonly<z.ZodArray<z.ZodEnum<{
|
|
6638
7113
|
agent: "agent";
|
|
6639
7114
|
firecracker: "firecracker";
|
|
6640
7115
|
impd: "impd";
|
|
7116
|
+
ipv6: "ipv6";
|
|
6641
7117
|
kernel: "kernel";
|
|
6642
7118
|
}>>>>;
|
|
6643
7119
|
cpu: z.ZodOptional<z.ZodObject<{
|
|
@@ -6698,6 +7174,7 @@ declare const SystemInfoSchema: z.ZodObject<{
|
|
|
6698
7174
|
firecracker: z.ZodInt;
|
|
6699
7175
|
kernel: z.ZodInt;
|
|
6700
7176
|
agent: z.ZodInt;
|
|
7177
|
+
ipv6: z.ZodOptional<z.ZodInt>;
|
|
6701
7178
|
}, z.core.$strip>;
|
|
6702
7179
|
}, z.core.$strip>;
|
|
6703
7180
|
firecrackerVersion: z.ZodNullable<z.ZodString>;
|
|
@@ -6737,6 +7214,15 @@ declare const SystemInfoSchema: z.ZodObject<{
|
|
|
6737
7214
|
hostCpus: z.ZodInt;
|
|
6738
7215
|
limitsEnforced: z.ZodBoolean;
|
|
6739
7216
|
}, z.core.$strip>>;
|
|
7217
|
+
public: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
7218
|
+
ip: z.ZodIPv4;
|
|
7219
|
+
imps: z.ZodInt;
|
|
7220
|
+
records: z.ZodNullable<z.ZodObject<{
|
|
7221
|
+
isOk: z.ZodBoolean;
|
|
7222
|
+
error: z.ZodNullable<z.ZodString>;
|
|
7223
|
+
at: z.ZodDate;
|
|
7224
|
+
}, z.core.$strip>>;
|
|
7225
|
+
}, z.core.$strip>>>;
|
|
6740
7226
|
}, z.core.$strip>;
|
|
6741
7227
|
type SystemInfo = z.infer<typeof SystemInfoSchema>;
|
|
6742
7228
|
//#endregion
|
package/dist/index.js
CHANGED
|
@@ -3,7 +3,7 @@ import { RPCLink } from "@orpc/client/fetch";
|
|
|
3
3
|
import * as z from "zod";
|
|
4
4
|
//#endregion
|
|
5
5
|
//#region src/check-server.ts
|
|
6
|
-
const CLIENT_VERSION = "0.
|
|
6
|
+
const CLIENT_VERSION = "0.12.0";
|
|
7
7
|
async function checkServer(rpc) {
|
|
8
8
|
const info = await rpc.system.info();
|
|
9
9
|
return {
|
|
@@ -30,11 +30,13 @@ function parseVersion(version) {
|
|
|
30
30
|
const NameSchema = z.string().regex(/^[a-z][a-z0-9-]{0,30}$/, "must be a lowercase letter followed by up to 30 lowercase letters, digits or hyphens");
|
|
31
31
|
//#endregion
|
|
32
32
|
//#region ../api/src/image-schema.ts
|
|
33
|
+
const ImageSourceSchema = z.enum(["oci", "imp"]);
|
|
33
34
|
const ImageSchema = z.object({
|
|
34
35
|
id: z.string(),
|
|
35
36
|
name: NameSchema,
|
|
36
37
|
ref: z.string(),
|
|
37
38
|
digest: z.string(),
|
|
39
|
+
source: ImageSourceSchema,
|
|
38
40
|
createdAt: z.date(),
|
|
39
41
|
sizeBytes: z.int().nonnegative()
|
|
40
42
|
});
|