kurtosis-sdk 0.80.5 → 0.80.7
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/build/core/kurtosis_core_rpc_api_bindings/api_container_service_grpc_pb.d.ts +5 -10
- package/build/core/kurtosis_core_rpc_api_bindings/api_container_service_grpc_pb.js +0 -26
- package/build/core/kurtosis_core_rpc_api_bindings/api_container_service_grpc_web_pb.d.ts +0 -12
- package/build/core/kurtosis_core_rpc_api_bindings/api_container_service_grpc_web_pb.js +0 -61
- package/build/core/kurtosis_core_rpc_api_bindings/api_container_service_pb.d.ts +1 -25
- package/build/core/kurtosis_core_rpc_api_bindings/api_container_service_pb.js +1 -207
- package/build/core/lib/constructor_calls.d.ts +1 -2
- package/build/core/lib/constructor_calls.js +1 -11
- package/build/core/lib/enclaves/enclave_context.d.ts +1 -1
- package/build/core/lib/enclaves/enclave_context.js +1 -5
- package/build/core/lib/enclaves/files_artifact.d.ts +1 -0
- package/build/core/lib/enclaves/files_artifact.js +2 -0
- package/build/core/lib/enclaves/generic_api_container_client.d.ts +2 -2
- package/build/core/lib/enclaves/grpc_node_api_container_client.d.ts +2 -2
- package/build/core/lib/enclaves/grpc_node_api_container_client.js +21 -2
- package/build/index.d.ts +1 -2
- package/build/index.js +1 -3
- package/build/kurtosis_version/kurtosis_version.js +1 -1
- package/package.json +1 -1
- package/build/core/lib/services/container_config.d.ts +0 -39
- package/build/core/lib/services/container_config.js +0 -85
|
@@ -16,8 +16,7 @@ interface IApiContainerServiceService extends grpc.ServiceDefinition<grpc.Untype
|
|
|
16
16
|
execCommand: grpc.MethodDefinition<api_container_service_pb.ExecCommandArgs, api_container_service_pb.ExecCommandResponse>;
|
|
17
17
|
waitForHttpGetEndpointAvailability: grpc.MethodDefinition<api_container_service_pb.WaitForHttpGetEndpointAvailabilityArgs, google_protobuf_empty_pb.Empty>;
|
|
18
18
|
waitForHttpPostEndpointAvailability: grpc.MethodDefinition<api_container_service_pb.WaitForHttpPostEndpointAvailabilityArgs, google_protobuf_empty_pb.Empty>;
|
|
19
|
-
uploadFilesArtifact: grpc.MethodDefinition<api_container_service_pb.
|
|
20
|
-
uploadFilesArtifactV2: grpc.MethodDefinition<api_container_service_pb.StreamedDataChunk, api_container_service_pb.UploadFilesArtifactResponse>;
|
|
19
|
+
uploadFilesArtifact: grpc.MethodDefinition<api_container_service_pb.StreamedDataChunk, api_container_service_pb.UploadFilesArtifactResponse>;
|
|
21
20
|
downloadFilesArtifact: grpc.MethodDefinition<api_container_service_pb.DownloadFilesArtifactArgs, api_container_service_pb.StreamedDataChunk>;
|
|
22
21
|
storeWebFilesArtifact: grpc.MethodDefinition<api_container_service_pb.StoreWebFilesArtifactArgs, api_container_service_pb.StoreWebFilesArtifactResponse>;
|
|
23
22
|
storeFilesArtifactFromService: grpc.MethodDefinition<api_container_service_pb.StoreFilesArtifactFromServiceArgs, api_container_service_pb.StoreFilesArtifactFromServiceResponse>;
|
|
@@ -35,8 +34,7 @@ export interface IApiContainerServiceServer extends grpc.UntypedServiceImplement
|
|
|
35
34
|
execCommand: grpc.handleUnaryCall<api_container_service_pb.ExecCommandArgs, api_container_service_pb.ExecCommandResponse>;
|
|
36
35
|
waitForHttpGetEndpointAvailability: grpc.handleUnaryCall<api_container_service_pb.WaitForHttpGetEndpointAvailabilityArgs, google_protobuf_empty_pb.Empty>;
|
|
37
36
|
waitForHttpPostEndpointAvailability: grpc.handleUnaryCall<api_container_service_pb.WaitForHttpPostEndpointAvailabilityArgs, google_protobuf_empty_pb.Empty>;
|
|
38
|
-
uploadFilesArtifact: grpc.
|
|
39
|
-
uploadFilesArtifactV2: grpc.handleClientStreamingCall<api_container_service_pb.StreamedDataChunk, api_container_service_pb.UploadFilesArtifactResponse>;
|
|
37
|
+
uploadFilesArtifact: grpc.handleClientStreamingCall<api_container_service_pb.StreamedDataChunk, api_container_service_pb.UploadFilesArtifactResponse>;
|
|
40
38
|
downloadFilesArtifact: grpc.handleServerStreamingCall<api_container_service_pb.DownloadFilesArtifactArgs, api_container_service_pb.StreamedDataChunk>;
|
|
41
39
|
storeWebFilesArtifact: grpc.handleUnaryCall<api_container_service_pb.StoreWebFilesArtifactArgs, api_container_service_pb.StoreWebFilesArtifactResponse>;
|
|
42
40
|
storeFilesArtifactFromService: grpc.handleUnaryCall<api_container_service_pb.StoreFilesArtifactFromServiceArgs, api_container_service_pb.StoreFilesArtifactFromServiceResponse>;
|
|
@@ -67,12 +65,9 @@ export class ApiContainerServiceClient extends grpc.Client {
|
|
|
67
65
|
waitForHttpPostEndpointAvailability(argument: api_container_service_pb.WaitForHttpPostEndpointAvailabilityArgs, callback: grpc.requestCallback<google_protobuf_empty_pb.Empty>): grpc.ClientUnaryCall;
|
|
68
66
|
waitForHttpPostEndpointAvailability(argument: api_container_service_pb.WaitForHttpPostEndpointAvailabilityArgs, metadataOrOptions: grpc.Metadata | grpc.CallOptions | null, callback: grpc.requestCallback<google_protobuf_empty_pb.Empty>): grpc.ClientUnaryCall;
|
|
69
67
|
waitForHttpPostEndpointAvailability(argument: api_container_service_pb.WaitForHttpPostEndpointAvailabilityArgs, metadata: grpc.Metadata | null, options: grpc.CallOptions | null, callback: grpc.requestCallback<google_protobuf_empty_pb.Empty>): grpc.ClientUnaryCall;
|
|
70
|
-
uploadFilesArtifact(
|
|
71
|
-
uploadFilesArtifact(
|
|
72
|
-
uploadFilesArtifact(
|
|
73
|
-
uploadFilesArtifactV2(callback: grpc.requestCallback<api_container_service_pb.UploadFilesArtifactResponse>): grpc.ClientWritableStream<api_container_service_pb.StreamedDataChunk>;
|
|
74
|
-
uploadFilesArtifactV2(metadataOrOptions: grpc.Metadata | grpc.CallOptions | null, callback: grpc.requestCallback<api_container_service_pb.UploadFilesArtifactResponse>): grpc.ClientWritableStream<api_container_service_pb.StreamedDataChunk>;
|
|
75
|
-
uploadFilesArtifactV2(metadata: grpc.Metadata | null, options: grpc.CallOptions | null, callback: grpc.requestCallback<api_container_service_pb.UploadFilesArtifactResponse>): grpc.ClientWritableStream<api_container_service_pb.StreamedDataChunk>;
|
|
68
|
+
uploadFilesArtifact(callback: grpc.requestCallback<api_container_service_pb.UploadFilesArtifactResponse>): grpc.ClientWritableStream<api_container_service_pb.StreamedDataChunk>;
|
|
69
|
+
uploadFilesArtifact(metadataOrOptions: grpc.Metadata | grpc.CallOptions | null, callback: grpc.requestCallback<api_container_service_pb.UploadFilesArtifactResponse>): grpc.ClientWritableStream<api_container_service_pb.StreamedDataChunk>;
|
|
70
|
+
uploadFilesArtifact(metadata: grpc.Metadata | null, options: grpc.CallOptions | null, callback: grpc.requestCallback<api_container_service_pb.UploadFilesArtifactResponse>): grpc.ClientWritableStream<api_container_service_pb.StreamedDataChunk>;
|
|
76
71
|
downloadFilesArtifact(argument: api_container_service_pb.DownloadFilesArtifactArgs, metadataOrOptions?: grpc.Metadata | grpc.CallOptions | null): grpc.ClientReadableStream<api_container_service_pb.StreamedDataChunk>;
|
|
77
72
|
downloadFilesArtifact(argument: api_container_service_pb.DownloadFilesArtifactArgs, metadata?: grpc.Metadata | null, options?: grpc.CallOptions | null): grpc.ClientReadableStream<api_container_service_pb.StreamedDataChunk>;
|
|
78
73
|
storeWebFilesArtifact(argument: api_container_service_pb.StoreWebFilesArtifactArgs, callback: grpc.requestCallback<api_container_service_pb.StoreWebFilesArtifactResponse>): grpc.ClientUnaryCall;
|
|
@@ -170,17 +170,6 @@ function deserialize_api_container_api_StreamedDataChunk(buffer_arg) {
|
|
|
170
170
|
return api_container_service_pb.StreamedDataChunk.deserializeBinary(new Uint8Array(buffer_arg));
|
|
171
171
|
}
|
|
172
172
|
|
|
173
|
-
function serialize_api_container_api_UploadFilesArtifactArgs(arg) {
|
|
174
|
-
if (!(arg instanceof api_container_service_pb.UploadFilesArtifactArgs)) {
|
|
175
|
-
throw new Error('Expected argument of type api_container_api.UploadFilesArtifactArgs');
|
|
176
|
-
}
|
|
177
|
-
return Buffer.from(arg.serializeBinary());
|
|
178
|
-
}
|
|
179
|
-
|
|
180
|
-
function deserialize_api_container_api_UploadFilesArtifactArgs(buffer_arg) {
|
|
181
|
-
return api_container_service_pb.UploadFilesArtifactArgs.deserializeBinary(new Uint8Array(buffer_arg));
|
|
182
|
-
}
|
|
183
|
-
|
|
184
173
|
function serialize_api_container_api_UploadFilesArtifactResponse(arg) {
|
|
185
174
|
if (!(arg instanceof api_container_service_pb.UploadFilesArtifactResponse)) {
|
|
186
175
|
throw new Error('Expected argument of type api_container_api.UploadFilesArtifactResponse');
|
|
@@ -324,23 +313,8 @@ waitForHttpPostEndpointAvailability: {
|
|
|
324
313
|
responseDeserialize: deserialize_google_protobuf_Empty,
|
|
325
314
|
},
|
|
326
315
|
// Uploads a files artifact to the Kurtosis File System
|
|
327
|
-
// Deprecated: please use UploadFilesArtifactV2 to stream the data and not be blocked by the 4MB limit
|
|
328
316
|
uploadFilesArtifact: {
|
|
329
317
|
path: '/api_container_api.ApiContainerService/UploadFilesArtifact',
|
|
330
|
-
requestStream: false,
|
|
331
|
-
responseStream: false,
|
|
332
|
-
requestType: api_container_service_pb.UploadFilesArtifactArgs,
|
|
333
|
-
responseType: api_container_service_pb.UploadFilesArtifactResponse,
|
|
334
|
-
requestSerialize: serialize_api_container_api_UploadFilesArtifactArgs,
|
|
335
|
-
requestDeserialize: deserialize_api_container_api_UploadFilesArtifactArgs,
|
|
336
|
-
responseSerialize: serialize_api_container_api_UploadFilesArtifactResponse,
|
|
337
|
-
responseDeserialize: deserialize_api_container_api_UploadFilesArtifactResponse,
|
|
338
|
-
},
|
|
339
|
-
// Uploads a files artifact to the Kurtosis File System
|
|
340
|
-
// Can be deprecated once we do not use it anymore. For now, it is still used in the TS SDK as grp-file-transfer
|
|
341
|
-
// library is only implemented in Go
|
|
342
|
-
uploadFilesArtifactV2: {
|
|
343
|
-
path: '/api_container_api.ApiContainerService/UploadFilesArtifactV2',
|
|
344
318
|
requestStream: true,
|
|
345
319
|
responseStream: false,
|
|
346
320
|
requestType: api_container_service_pb.StreamedDataChunk,
|
|
@@ -54,13 +54,6 @@ export class ApiContainerServiceClient {
|
|
|
54
54
|
response: google_protobuf_empty_pb.Empty) => void
|
|
55
55
|
): grpcWeb.ClientReadableStream<google_protobuf_empty_pb.Empty>;
|
|
56
56
|
|
|
57
|
-
uploadFilesArtifact(
|
|
58
|
-
request: api_container_service_pb.UploadFilesArtifactArgs,
|
|
59
|
-
metadata: grpcWeb.Metadata | undefined,
|
|
60
|
-
callback: (err: grpcWeb.RpcError,
|
|
61
|
-
response: api_container_service_pb.UploadFilesArtifactResponse) => void
|
|
62
|
-
): grpcWeb.ClientReadableStream<api_container_service_pb.UploadFilesArtifactResponse>;
|
|
63
|
-
|
|
64
57
|
downloadFilesArtifact(
|
|
65
58
|
request: api_container_service_pb.DownloadFilesArtifactArgs,
|
|
66
59
|
metadata?: grpcWeb.Metadata
|
|
@@ -129,11 +122,6 @@ export class ApiContainerServicePromiseClient {
|
|
|
129
122
|
metadata?: grpcWeb.Metadata
|
|
130
123
|
): Promise<google_protobuf_empty_pb.Empty>;
|
|
131
124
|
|
|
132
|
-
uploadFilesArtifact(
|
|
133
|
-
request: api_container_service_pb.UploadFilesArtifactArgs,
|
|
134
|
-
metadata?: grpcWeb.Metadata
|
|
135
|
-
): Promise<api_container_service_pb.UploadFilesArtifactResponse>;
|
|
136
|
-
|
|
137
125
|
downloadFilesArtifact(
|
|
138
126
|
request: api_container_service_pb.DownloadFilesArtifactArgs,
|
|
139
127
|
metadata?: grpcWeb.Metadata
|
|
@@ -493,67 +493,6 @@ proto.api_container_api.ApiContainerServicePromiseClient.prototype.waitForHttpPo
|
|
|
493
493
|
};
|
|
494
494
|
|
|
495
495
|
|
|
496
|
-
/**
|
|
497
|
-
* @const
|
|
498
|
-
* @type {!grpc.web.MethodDescriptor<
|
|
499
|
-
* !proto.api_container_api.UploadFilesArtifactArgs,
|
|
500
|
-
* !proto.api_container_api.UploadFilesArtifactResponse>}
|
|
501
|
-
*/
|
|
502
|
-
const methodDescriptor_ApiContainerService_UploadFilesArtifact = new grpc.web.MethodDescriptor(
|
|
503
|
-
'/api_container_api.ApiContainerService/UploadFilesArtifact',
|
|
504
|
-
grpc.web.MethodType.UNARY,
|
|
505
|
-
proto.api_container_api.UploadFilesArtifactArgs,
|
|
506
|
-
proto.api_container_api.UploadFilesArtifactResponse,
|
|
507
|
-
/**
|
|
508
|
-
* @param {!proto.api_container_api.UploadFilesArtifactArgs} request
|
|
509
|
-
* @return {!Uint8Array}
|
|
510
|
-
*/
|
|
511
|
-
function(request) {
|
|
512
|
-
return request.serializeBinary();
|
|
513
|
-
},
|
|
514
|
-
proto.api_container_api.UploadFilesArtifactResponse.deserializeBinary
|
|
515
|
-
);
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
/**
|
|
519
|
-
* @param {!proto.api_container_api.UploadFilesArtifactArgs} request The
|
|
520
|
-
* request proto
|
|
521
|
-
* @param {?Object<string, string>} metadata User defined
|
|
522
|
-
* call metadata
|
|
523
|
-
* @param {function(?grpc.web.RpcError, ?proto.api_container_api.UploadFilesArtifactResponse)}
|
|
524
|
-
* callback The callback function(error, response)
|
|
525
|
-
* @return {!grpc.web.ClientReadableStream<!proto.api_container_api.UploadFilesArtifactResponse>|undefined}
|
|
526
|
-
* The XHR Node Readable Stream
|
|
527
|
-
*/
|
|
528
|
-
proto.api_container_api.ApiContainerServiceClient.prototype.uploadFilesArtifact =
|
|
529
|
-
function(request, metadata, callback) {
|
|
530
|
-
return this.client_.rpcCall(this.hostname_ +
|
|
531
|
-
'/api_container_api.ApiContainerService/UploadFilesArtifact',
|
|
532
|
-
request,
|
|
533
|
-
metadata || {},
|
|
534
|
-
methodDescriptor_ApiContainerService_UploadFilesArtifact,
|
|
535
|
-
callback);
|
|
536
|
-
};
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
/**
|
|
540
|
-
* @param {!proto.api_container_api.UploadFilesArtifactArgs} request The
|
|
541
|
-
* request proto
|
|
542
|
-
* @param {?Object<string, string>=} metadata User defined
|
|
543
|
-
* call metadata
|
|
544
|
-
* @return {!Promise<!proto.api_container_api.UploadFilesArtifactResponse>}
|
|
545
|
-
* Promise that resolves to the response
|
|
546
|
-
*/
|
|
547
|
-
proto.api_container_api.ApiContainerServicePromiseClient.prototype.uploadFilesArtifact =
|
|
548
|
-
function(request, metadata) {
|
|
549
|
-
return this.client_.unaryCall(this.hostname_ +
|
|
550
|
-
'/api_container_api.ApiContainerService/UploadFilesArtifact',
|
|
551
|
-
request,
|
|
552
|
-
metadata || {},
|
|
553
|
-
methodDescriptor_ApiContainerService_UploadFilesArtifact);
|
|
554
|
-
};
|
|
555
|
-
|
|
556
|
-
|
|
557
496
|
/**
|
|
558
497
|
* @const
|
|
559
498
|
* @type {!grpc.web.MethodDescriptor<
|
|
@@ -854,30 +854,6 @@ export namespace DataChunkMetadata {
|
|
|
854
854
|
}
|
|
855
855
|
}
|
|
856
856
|
|
|
857
|
-
export class UploadFilesArtifactArgs extends jspb.Message {
|
|
858
|
-
getData(): Uint8Array | string;
|
|
859
|
-
getData_asU8(): Uint8Array;
|
|
860
|
-
getData_asB64(): string;
|
|
861
|
-
setData(value: Uint8Array | string): UploadFilesArtifactArgs;
|
|
862
|
-
|
|
863
|
-
getName(): string;
|
|
864
|
-
setName(value: string): UploadFilesArtifactArgs;
|
|
865
|
-
|
|
866
|
-
serializeBinary(): Uint8Array;
|
|
867
|
-
toObject(includeInstance?: boolean): UploadFilesArtifactArgs.AsObject;
|
|
868
|
-
static toObject(includeInstance: boolean, msg: UploadFilesArtifactArgs): UploadFilesArtifactArgs.AsObject;
|
|
869
|
-
static serializeBinaryToWriter(message: UploadFilesArtifactArgs, writer: jspb.BinaryWriter): void;
|
|
870
|
-
static deserializeBinary(bytes: Uint8Array): UploadFilesArtifactArgs;
|
|
871
|
-
static deserializeBinaryFromReader(message: UploadFilesArtifactArgs, reader: jspb.BinaryReader): UploadFilesArtifactArgs;
|
|
872
|
-
}
|
|
873
|
-
|
|
874
|
-
export namespace UploadFilesArtifactArgs {
|
|
875
|
-
export type AsObject = {
|
|
876
|
-
data: Uint8Array | string,
|
|
877
|
-
name: string,
|
|
878
|
-
}
|
|
879
|
-
}
|
|
880
|
-
|
|
881
857
|
export class UploadFilesArtifactResponse extends jspb.Message {
|
|
882
858
|
getUuid(): string;
|
|
883
859
|
setUuid(value: string): UploadFilesArtifactResponse;
|
|
@@ -1045,5 +1021,5 @@ export namespace ListFilesArtifactNamesAndUuidsResponse {
|
|
|
1045
1021
|
}
|
|
1046
1022
|
|
|
1047
1023
|
export enum KurtosisFeatureFlag {
|
|
1048
|
-
|
|
1024
|
+
NO_INSTRUCTIONS_CACHING = 0,
|
|
1049
1025
|
}
|
|
@@ -60,7 +60,6 @@ goog.exportSymbol('proto.api_container_api.StoreWebFilesArtifactArgs', null, glo
|
|
|
60
60
|
goog.exportSymbol('proto.api_container_api.StoreWebFilesArtifactResponse', null, global);
|
|
61
61
|
goog.exportSymbol('proto.api_container_api.StreamedDataChunk', null, global);
|
|
62
62
|
goog.exportSymbol('proto.api_container_api.UpdateServiceConfig', null, global);
|
|
63
|
-
goog.exportSymbol('proto.api_container_api.UploadFilesArtifactArgs', null, global);
|
|
64
63
|
goog.exportSymbol('proto.api_container_api.UploadFilesArtifactResponse', null, global);
|
|
65
64
|
goog.exportSymbol('proto.api_container_api.WaitForHttpGetEndpointAvailabilityArgs', null, global);
|
|
66
65
|
goog.exportSymbol('proto.api_container_api.WaitForHttpPostEndpointAvailabilityArgs', null, global);
|
|
@@ -631,27 +630,6 @@ if (goog.DEBUG && !COMPILED) {
|
|
|
631
630
|
*/
|
|
632
631
|
proto.api_container_api.DataChunkMetadata.displayName = 'proto.api_container_api.DataChunkMetadata';
|
|
633
632
|
}
|
|
634
|
-
/**
|
|
635
|
-
* Generated by JsPbCodeGenerator.
|
|
636
|
-
* @param {Array=} opt_data Optional initial data array, typically from a
|
|
637
|
-
* server response, or constructed directly in Javascript. The array is used
|
|
638
|
-
* in place and becomes part of the constructed object. It is not cloned.
|
|
639
|
-
* If no data is provided, the constructed object will be empty, but still
|
|
640
|
-
* valid.
|
|
641
|
-
* @extends {jspb.Message}
|
|
642
|
-
* @constructor
|
|
643
|
-
*/
|
|
644
|
-
proto.api_container_api.UploadFilesArtifactArgs = function(opt_data) {
|
|
645
|
-
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
|
646
|
-
};
|
|
647
|
-
goog.inherits(proto.api_container_api.UploadFilesArtifactArgs, jspb.Message);
|
|
648
|
-
if (goog.DEBUG && !COMPILED) {
|
|
649
|
-
/**
|
|
650
|
-
* @public
|
|
651
|
-
* @override
|
|
652
|
-
*/
|
|
653
|
-
proto.api_container_api.UploadFilesArtifactArgs.displayName = 'proto.api_container_api.UploadFilesArtifactArgs';
|
|
654
|
-
}
|
|
655
633
|
/**
|
|
656
634
|
* Generated by JsPbCodeGenerator.
|
|
657
635
|
* @param {Array=} opt_data Optional initial data array, typically from a
|
|
@@ -6834,190 +6812,6 @@ proto.api_container_api.DataChunkMetadata.prototype.setName = function(value) {
|
|
|
6834
6812
|
|
|
6835
6813
|
|
|
6836
6814
|
|
|
6837
|
-
if (jspb.Message.GENERATE_TO_OBJECT) {
|
|
6838
|
-
/**
|
|
6839
|
-
* Creates an object representation of this proto.
|
|
6840
|
-
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
|
6841
|
-
* Optional fields that are not set will be set to undefined.
|
|
6842
|
-
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
|
6843
|
-
* For the list of reserved names please see:
|
|
6844
|
-
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
|
6845
|
-
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
|
6846
|
-
* JSPB instance for transitional soy proto support:
|
|
6847
|
-
* http://goto/soy-param-migration
|
|
6848
|
-
* @return {!Object}
|
|
6849
|
-
*/
|
|
6850
|
-
proto.api_container_api.UploadFilesArtifactArgs.prototype.toObject = function(opt_includeInstance) {
|
|
6851
|
-
return proto.api_container_api.UploadFilesArtifactArgs.toObject(opt_includeInstance, this);
|
|
6852
|
-
};
|
|
6853
|
-
|
|
6854
|
-
|
|
6855
|
-
/**
|
|
6856
|
-
* Static version of the {@see toObject} method.
|
|
6857
|
-
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
|
6858
|
-
* the JSPB instance for transitional soy proto support:
|
|
6859
|
-
* http://goto/soy-param-migration
|
|
6860
|
-
* @param {!proto.api_container_api.UploadFilesArtifactArgs} msg The msg instance to transform.
|
|
6861
|
-
* @return {!Object}
|
|
6862
|
-
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
6863
|
-
*/
|
|
6864
|
-
proto.api_container_api.UploadFilesArtifactArgs.toObject = function(includeInstance, msg) {
|
|
6865
|
-
var f, obj = {
|
|
6866
|
-
data: msg.getData_asB64(),
|
|
6867
|
-
name: jspb.Message.getFieldWithDefault(msg, 2, "")
|
|
6868
|
-
};
|
|
6869
|
-
|
|
6870
|
-
if (includeInstance) {
|
|
6871
|
-
obj.$jspbMessageInstance = msg;
|
|
6872
|
-
}
|
|
6873
|
-
return obj;
|
|
6874
|
-
};
|
|
6875
|
-
}
|
|
6876
|
-
|
|
6877
|
-
|
|
6878
|
-
/**
|
|
6879
|
-
* Deserializes binary data (in protobuf wire format).
|
|
6880
|
-
* @param {jspb.ByteSource} bytes The bytes to deserialize.
|
|
6881
|
-
* @return {!proto.api_container_api.UploadFilesArtifactArgs}
|
|
6882
|
-
*/
|
|
6883
|
-
proto.api_container_api.UploadFilesArtifactArgs.deserializeBinary = function(bytes) {
|
|
6884
|
-
var reader = new jspb.BinaryReader(bytes);
|
|
6885
|
-
var msg = new proto.api_container_api.UploadFilesArtifactArgs;
|
|
6886
|
-
return proto.api_container_api.UploadFilesArtifactArgs.deserializeBinaryFromReader(msg, reader);
|
|
6887
|
-
};
|
|
6888
|
-
|
|
6889
|
-
|
|
6890
|
-
/**
|
|
6891
|
-
* Deserializes binary data (in protobuf wire format) from the
|
|
6892
|
-
* given reader into the given message object.
|
|
6893
|
-
* @param {!proto.api_container_api.UploadFilesArtifactArgs} msg The message object to deserialize into.
|
|
6894
|
-
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
|
6895
|
-
* @return {!proto.api_container_api.UploadFilesArtifactArgs}
|
|
6896
|
-
*/
|
|
6897
|
-
proto.api_container_api.UploadFilesArtifactArgs.deserializeBinaryFromReader = function(msg, reader) {
|
|
6898
|
-
while (reader.nextField()) {
|
|
6899
|
-
if (reader.isEndGroup()) {
|
|
6900
|
-
break;
|
|
6901
|
-
}
|
|
6902
|
-
var field = reader.getFieldNumber();
|
|
6903
|
-
switch (field) {
|
|
6904
|
-
case 1:
|
|
6905
|
-
var value = /** @type {!Uint8Array} */ (reader.readBytes());
|
|
6906
|
-
msg.setData(value);
|
|
6907
|
-
break;
|
|
6908
|
-
case 2:
|
|
6909
|
-
var value = /** @type {string} */ (reader.readString());
|
|
6910
|
-
msg.setName(value);
|
|
6911
|
-
break;
|
|
6912
|
-
default:
|
|
6913
|
-
reader.skipField();
|
|
6914
|
-
break;
|
|
6915
|
-
}
|
|
6916
|
-
}
|
|
6917
|
-
return msg;
|
|
6918
|
-
};
|
|
6919
|
-
|
|
6920
|
-
|
|
6921
|
-
/**
|
|
6922
|
-
* Serializes the message to binary data (in protobuf wire format).
|
|
6923
|
-
* @return {!Uint8Array}
|
|
6924
|
-
*/
|
|
6925
|
-
proto.api_container_api.UploadFilesArtifactArgs.prototype.serializeBinary = function() {
|
|
6926
|
-
var writer = new jspb.BinaryWriter();
|
|
6927
|
-
proto.api_container_api.UploadFilesArtifactArgs.serializeBinaryToWriter(this, writer);
|
|
6928
|
-
return writer.getResultBuffer();
|
|
6929
|
-
};
|
|
6930
|
-
|
|
6931
|
-
|
|
6932
|
-
/**
|
|
6933
|
-
* Serializes the given message to binary data (in protobuf wire
|
|
6934
|
-
* format), writing to the given BinaryWriter.
|
|
6935
|
-
* @param {!proto.api_container_api.UploadFilesArtifactArgs} message
|
|
6936
|
-
* @param {!jspb.BinaryWriter} writer
|
|
6937
|
-
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
6938
|
-
*/
|
|
6939
|
-
proto.api_container_api.UploadFilesArtifactArgs.serializeBinaryToWriter = function(message, writer) {
|
|
6940
|
-
var f = undefined;
|
|
6941
|
-
f = message.getData_asU8();
|
|
6942
|
-
if (f.length > 0) {
|
|
6943
|
-
writer.writeBytes(
|
|
6944
|
-
1,
|
|
6945
|
-
f
|
|
6946
|
-
);
|
|
6947
|
-
}
|
|
6948
|
-
f = message.getName();
|
|
6949
|
-
if (f.length > 0) {
|
|
6950
|
-
writer.writeString(
|
|
6951
|
-
2,
|
|
6952
|
-
f
|
|
6953
|
-
);
|
|
6954
|
-
}
|
|
6955
|
-
};
|
|
6956
|
-
|
|
6957
|
-
|
|
6958
|
-
/**
|
|
6959
|
-
* optional bytes data = 1;
|
|
6960
|
-
* @return {string}
|
|
6961
|
-
*/
|
|
6962
|
-
proto.api_container_api.UploadFilesArtifactArgs.prototype.getData = function() {
|
|
6963
|
-
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
|
|
6964
|
-
};
|
|
6965
|
-
|
|
6966
|
-
|
|
6967
|
-
/**
|
|
6968
|
-
* optional bytes data = 1;
|
|
6969
|
-
* This is a type-conversion wrapper around `getData()`
|
|
6970
|
-
* @return {string}
|
|
6971
|
-
*/
|
|
6972
|
-
proto.api_container_api.UploadFilesArtifactArgs.prototype.getData_asB64 = function() {
|
|
6973
|
-
return /** @type {string} */ (jspb.Message.bytesAsB64(
|
|
6974
|
-
this.getData()));
|
|
6975
|
-
};
|
|
6976
|
-
|
|
6977
|
-
|
|
6978
|
-
/**
|
|
6979
|
-
* optional bytes data = 1;
|
|
6980
|
-
* Note that Uint8Array is not supported on all browsers.
|
|
6981
|
-
* @see http://caniuse.com/Uint8Array
|
|
6982
|
-
* This is a type-conversion wrapper around `getData()`
|
|
6983
|
-
* @return {!Uint8Array}
|
|
6984
|
-
*/
|
|
6985
|
-
proto.api_container_api.UploadFilesArtifactArgs.prototype.getData_asU8 = function() {
|
|
6986
|
-
return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
|
|
6987
|
-
this.getData()));
|
|
6988
|
-
};
|
|
6989
|
-
|
|
6990
|
-
|
|
6991
|
-
/**
|
|
6992
|
-
* @param {!(string|Uint8Array)} value
|
|
6993
|
-
* @return {!proto.api_container_api.UploadFilesArtifactArgs} returns this
|
|
6994
|
-
*/
|
|
6995
|
-
proto.api_container_api.UploadFilesArtifactArgs.prototype.setData = function(value) {
|
|
6996
|
-
return jspb.Message.setProto3BytesField(this, 1, value);
|
|
6997
|
-
};
|
|
6998
|
-
|
|
6999
|
-
|
|
7000
|
-
/**
|
|
7001
|
-
* optional string name = 2;
|
|
7002
|
-
* @return {string}
|
|
7003
|
-
*/
|
|
7004
|
-
proto.api_container_api.UploadFilesArtifactArgs.prototype.getName = function() {
|
|
7005
|
-
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
|
|
7006
|
-
};
|
|
7007
|
-
|
|
7008
|
-
|
|
7009
|
-
/**
|
|
7010
|
-
* @param {string} value
|
|
7011
|
-
* @return {!proto.api_container_api.UploadFilesArtifactArgs} returns this
|
|
7012
|
-
*/
|
|
7013
|
-
proto.api_container_api.UploadFilesArtifactArgs.prototype.setName = function(value) {
|
|
7014
|
-
return jspb.Message.setProto3StringField(this, 2, value);
|
|
7015
|
-
};
|
|
7016
|
-
|
|
7017
|
-
|
|
7018
|
-
|
|
7019
|
-
|
|
7020
|
-
|
|
7021
6815
|
if (jspb.Message.GENERATE_TO_OBJECT) {
|
|
7022
6816
|
/**
|
|
7023
6817
|
* Creates an object representation of this proto.
|
|
@@ -8239,7 +8033,7 @@ proto.api_container_api.ListFilesArtifactNamesAndUuidsResponse.prototype.clearFi
|
|
|
8239
8033
|
* @enum {number}
|
|
8240
8034
|
*/
|
|
8241
8035
|
proto.api_container_api.KurtosisFeatureFlag = {
|
|
8242
|
-
|
|
8036
|
+
NO_INSTRUCTIONS_CACHING: 0
|
|
8243
8037
|
};
|
|
8244
8038
|
|
|
8245
8039
|
goog.object.extend(exports, proto.api_container_api);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ExecCommandArgs, GetServicesArgs, WaitForHttpGetEndpointAvailabilityArgs, WaitForHttpPostEndpointAvailabilityArgs, Port, StoreWebFilesArtifactArgs,
|
|
1
|
+
import { ExecCommandArgs, GetServicesArgs, WaitForHttpGetEndpointAvailabilityArgs, WaitForHttpPostEndpointAvailabilityArgs, Port, StoreWebFilesArtifactArgs, ServiceInfo, GetServicesResponse, DownloadFilesArtifactArgs } from '../kurtosis_core_rpc_api_bindings/api_container_service_pb';
|
|
2
2
|
import { ServiceName } from './services/service';
|
|
3
3
|
export declare function newPort(number: number, transportProtocol: Port.TransportProtocol, maybeApplicationProtocol?: string): Port;
|
|
4
4
|
export declare function newGetServicesArgs(serviceIdentifiers: Map<string, boolean>): GetServicesArgs;
|
|
@@ -8,4 +8,3 @@ export declare function newWaitForHttpGetEndpointAvailabilityArgs(serviceIdentif
|
|
|
8
8
|
export declare function newWaitForHttpPostEndpointAvailabilityArgs(serviceIdentifier: string, port: number, path: string, requestBody: string, initialDelayMilliseconds: number, retries: number, retriesDelayMilliseconds: number, bodyText: string): WaitForHttpPostEndpointAvailabilityArgs;
|
|
9
9
|
export declare function newStoreWebFilesArtifactArgs(url: string, name: string): StoreWebFilesArtifactArgs;
|
|
10
10
|
export declare function newDownloadFilesArtifactArgs(identifier: string): DownloadFilesArtifactArgs;
|
|
11
|
-
export declare function newUploadFilesArtifactArgs(data: Uint8Array, name: string): UploadFilesArtifactArgs;
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* All Rights Reserved.
|
|
5
5
|
*/
|
|
6
6
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
-
exports.
|
|
7
|
+
exports.newDownloadFilesArtifactArgs = exports.newStoreWebFilesArtifactArgs = exports.newWaitForHttpPostEndpointAvailabilityArgs = exports.newWaitForHttpGetEndpointAvailabilityArgs = exports.newExecCommandArgs = exports.newGetServicesResponse = exports.newGetServicesArgs = exports.newPort = void 0;
|
|
8
8
|
const api_container_service_pb_1 = require("../kurtosis_core_rpc_api_bindings/api_container_service_pb");
|
|
9
9
|
// ==============================================================================================
|
|
10
10
|
// Shared Objects (Used By Multiple Endpoints)
|
|
@@ -100,13 +100,3 @@ function newDownloadFilesArtifactArgs(identifier) {
|
|
|
100
100
|
return result;
|
|
101
101
|
}
|
|
102
102
|
exports.newDownloadFilesArtifactArgs = newDownloadFilesArtifactArgs;
|
|
103
|
-
// ==============================================================================================
|
|
104
|
-
// Upload Files
|
|
105
|
-
// ==============================================================================================
|
|
106
|
-
function newUploadFilesArtifactArgs(data, name) {
|
|
107
|
-
const result = new api_container_service_pb_1.UploadFilesArtifactArgs();
|
|
108
|
-
result.setData(data);
|
|
109
|
-
result.setName(name);
|
|
110
|
-
return result;
|
|
111
|
-
}
|
|
112
|
-
exports.newUploadFilesArtifactArgs = newUploadFilesArtifactArgs;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import { Result } from "neverthrow";
|
|
3
|
-
import type { FilesArtifactUUID } from "
|
|
3
|
+
import type { FilesArtifactUUID } from "./files_artifact";
|
|
4
4
|
import type { ServiceName, ServiceUUID } from "../services/service";
|
|
5
5
|
import { ServiceContext } from "../services/service_context";
|
|
6
6
|
import { FilesArtifactNameAndUuid, KurtosisFeatureFlag } from "../../kurtosis_core_rpc_api_bindings/api_container_service_pb";
|
|
@@ -24,9 +24,6 @@ const path = require("path");
|
|
|
24
24
|
const kurtosis_yaml_1 = require("./kurtosis_yaml");
|
|
25
25
|
const starlark_run_blocking_1 = require("./starlark_run_blocking");
|
|
26
26
|
const service_identifiers_1 = require("../services/service_identifiers");
|
|
27
|
-
// This will always resolve to the default partition ID (regardless of whether such a partition exists in the enclave,
|
|
28
|
-
// or it was repartitioned away)
|
|
29
|
-
const DEFAULT_PARTITION_ID = "";
|
|
30
27
|
exports.KURTOSIS_YAML_FILENAME = "kurtosis.yml";
|
|
31
28
|
// Docs available at https://docs.kurtosis.com/sdk/#enclavecontext
|
|
32
29
|
class EnclaveContext {
|
|
@@ -204,8 +201,7 @@ class EnclaveContext {
|
|
|
204
201
|
if (archiverResponse.isErr()) {
|
|
205
202
|
return (0, neverthrow_1.err)(archiverResponse.error);
|
|
206
203
|
}
|
|
207
|
-
const
|
|
208
|
-
const uploadResult = yield this.backend.uploadFiles(args);
|
|
204
|
+
const uploadResult = yield this.backend.uploadFiles(name, archiverResponse.value);
|
|
209
205
|
if (uploadResult.isErr()) {
|
|
210
206
|
return (0, neverthrow_1.err)(uploadResult.error);
|
|
211
207
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type FilesArtifactUUID = string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import { Result } from "neverthrow";
|
|
3
|
-
import { DownloadFilesArtifactArgs, ExecCommandArgs, ExecCommandResponse, GetExistingAndHistoricalServiceIdentifiersResponse, GetServicesArgs, GetServicesResponse, ListFilesArtifactNamesAndUuidsResponse, RunStarlarkPackageArgs, RunStarlarkScriptArgs, StoreWebFilesArtifactArgs, StoreWebFilesArtifactResponse,
|
|
3
|
+
import { DownloadFilesArtifactArgs, ExecCommandArgs, ExecCommandResponse, GetExistingAndHistoricalServiceIdentifiersResponse, GetServicesArgs, GetServicesResponse, ListFilesArtifactNamesAndUuidsResponse, RunStarlarkPackageArgs, RunStarlarkScriptArgs, StoreWebFilesArtifactArgs, StoreWebFilesArtifactResponse, UploadFilesArtifactResponse, WaitForHttpGetEndpointAvailabilityArgs, WaitForHttpPostEndpointAvailabilityArgs } from "../../kurtosis_core_rpc_api_bindings/api_container_service_pb";
|
|
4
4
|
import { EnclaveUUID } from "./enclave_context";
|
|
5
5
|
import { Readable } from "stream";
|
|
6
6
|
export interface GenericApiContainerClient {
|
|
@@ -12,7 +12,7 @@ export interface GenericApiContainerClient {
|
|
|
12
12
|
waitForHttpPostEndpointAvailability(availabilityArgs: WaitForHttpPostEndpointAvailabilityArgs): Promise<Result<null, Error>>;
|
|
13
13
|
getServices(getServicesArgs: GetServicesArgs): Promise<Result<GetServicesResponse, Error>>;
|
|
14
14
|
execCommand(execCommandArgs: ExecCommandArgs): Promise<Result<ExecCommandResponse, Error>>;
|
|
15
|
-
uploadFiles(
|
|
15
|
+
uploadFiles(name: string, payload: Uint8Array): Promise<Result<UploadFilesArtifactResponse, Error>>;
|
|
16
16
|
storeWebFilesArtifact(storeWebFilesArtifactArgs: StoreWebFilesArtifactArgs): Promise<Result<StoreWebFilesArtifactResponse, Error>>;
|
|
17
17
|
downloadFilesArtifact(downloadFilesArtifactArgs: DownloadFilesArtifactArgs): Promise<Result<Uint8Array, Error>>;
|
|
18
18
|
getExistingAndHistoricalServiceIdentifiers(): Promise<Result<GetExistingAndHistoricalServiceIdentifiersResponse, Error>>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import { Result } from "neverthrow";
|
|
3
|
-
import {
|
|
3
|
+
import { DownloadFilesArtifactArgs, ExecCommandArgs, ExecCommandResponse, GetExistingAndHistoricalServiceIdentifiersResponse, GetServicesArgs, GetServicesResponse, ListFilesArtifactNamesAndUuidsResponse, RunStarlarkPackageArgs, RunStarlarkScriptArgs, StoreWebFilesArtifactArgs, StoreWebFilesArtifactResponse, UploadFilesArtifactResponse, WaitForHttpGetEndpointAvailabilityArgs, WaitForHttpPostEndpointAvailabilityArgs } from "../../kurtosis_core_rpc_api_bindings/api_container_service_pb";
|
|
4
4
|
import type { ApiContainerServiceClient as ApiContainerServiceClientNode } from "../../kurtosis_core_rpc_api_bindings/api_container_service_grpc_pb";
|
|
5
5
|
import { GenericApiContainerClient } from "./generic_api_container_client";
|
|
6
6
|
import { EnclaveUUID } from "./enclave_context";
|
|
@@ -18,7 +18,7 @@ export declare class GrpcNodeApiContainerClient implements GenericApiContainerCl
|
|
|
18
18
|
waitForHttpPostEndpointAvailability(availabilityArgs: WaitForHttpPostEndpointAvailabilityArgs): Promise<Result<null, Error>>;
|
|
19
19
|
getServices(getServicesArgs: GetServicesArgs): Promise<Result<GetServicesResponse, Error>>;
|
|
20
20
|
execCommand(execCommandArgs: ExecCommandArgs): Promise<Result<ExecCommandResponse, Error>>;
|
|
21
|
-
uploadFiles(
|
|
21
|
+
uploadFiles(name: string, payload: Uint8Array): Promise<Result<UploadFilesArtifactResponse, Error>>;
|
|
22
22
|
storeWebFilesArtifact(storeWebFilesArtifactArgs: StoreWebFilesArtifactArgs): Promise<Result<StoreWebFilesArtifactResponse, Error>>;
|
|
23
23
|
downloadFilesArtifact(downloadFilesArtifactArgs: DownloadFilesArtifactArgs): Promise<Result<Uint8Array, Error>>;
|
|
24
24
|
getExistingAndHistoricalServiceIdentifiers(): Promise<Result<GetExistingAndHistoricalServiceIdentifiersResponse, Error>>;
|
|
@@ -12,9 +12,11 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
12
12
|
exports.GrpcNodeApiContainerClient = void 0;
|
|
13
13
|
const neverthrow_1 = require("neverthrow");
|
|
14
14
|
const google_protobuf_empty_pb = require("google-protobuf/google/protobuf/empty_pb");
|
|
15
|
+
const api_container_service_pb_1 = require("../../kurtosis_core_rpc_api_bindings/api_container_service_pb");
|
|
15
16
|
const crypto = require("crypto");
|
|
16
17
|
const HASH_ALGORITHM = "sha1";
|
|
17
18
|
const HASH_ENCODING = "hex";
|
|
19
|
+
const DATA_STREAM_CHUNK_SIZE = 3 * 1024 * 1024; // 3MB
|
|
18
20
|
class GrpcNodeApiContainerClient {
|
|
19
21
|
constructor(client, enclaveUuid, enclaveName) {
|
|
20
22
|
this.client = client;
|
|
@@ -139,10 +141,10 @@ class GrpcNodeApiContainerClient {
|
|
|
139
141
|
return (0, neverthrow_1.ok)(execCommandResponse);
|
|
140
142
|
});
|
|
141
143
|
}
|
|
142
|
-
uploadFiles(
|
|
144
|
+
uploadFiles(name, payload) {
|
|
143
145
|
return __awaiter(this, void 0, void 0, function* () {
|
|
144
146
|
const uploadFilesArtifactPromise = new Promise((resolve, _unusedReject) => {
|
|
145
|
-
this.client.uploadFilesArtifact(
|
|
147
|
+
const clientStream = this.client.uploadFilesArtifact((error, response) => {
|
|
146
148
|
if (error === null) {
|
|
147
149
|
if (!response) {
|
|
148
150
|
resolve((0, neverthrow_1.err)(new Error("No error was encountered but the response was still falsy; this should never happen")));
|
|
@@ -155,6 +157,23 @@ class GrpcNodeApiContainerClient {
|
|
|
155
157
|
resolve((0, neverthrow_1.err)(error));
|
|
156
158
|
}
|
|
157
159
|
});
|
|
160
|
+
const constantChunkMetadata = new api_container_service_pb_1.DataChunkMetadata()
|
|
161
|
+
.setName(name);
|
|
162
|
+
let previousChunkHash = "";
|
|
163
|
+
for (let idx = 0; idx < payload.length; idx += DATA_STREAM_CHUNK_SIZE) {
|
|
164
|
+
const currentChunk = payload.subarray(idx, Math.min(idx + DATA_STREAM_CHUNK_SIZE, payload.length));
|
|
165
|
+
const dataChunk = new api_container_service_pb_1.StreamedDataChunk()
|
|
166
|
+
.setData(currentChunk)
|
|
167
|
+
.setPreviousChunkHash(previousChunkHash)
|
|
168
|
+
.setMetadata(constantChunkMetadata);
|
|
169
|
+
clientStream.write(dataChunk, (streamErr) => {
|
|
170
|
+
if (streamErr != undefined) {
|
|
171
|
+
resolve((0, neverthrow_1.err)(new Error(`An error occurred sending data through the stream:\n${streamErr.message}`)));
|
|
172
|
+
}
|
|
173
|
+
});
|
|
174
|
+
previousChunkHash = this.computeHexHash(currentChunk);
|
|
175
|
+
}
|
|
176
|
+
clientStream.end(); // close the stream, no more data will be sent
|
|
158
177
|
});
|
|
159
178
|
const uploadFilesArtifactResponseResult = yield uploadFilesArtifactPromise;
|
|
160
179
|
if (uploadFilesArtifactResponseResult.isErr()) {
|
package/build/index.d.ts
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
export { KURTOSIS_VERSION } from "./kurtosis_version/kurtosis_version";
|
|
2
|
-
export type { FilesArtifactUUID, ContainerConfig } from "./core/lib/services/container_config";
|
|
3
|
-
export { ContainerConfigBuilder } from "./core/lib/services/container_config";
|
|
4
2
|
export type { ServiceName, ServiceUUID } from "./core/lib/services/service";
|
|
5
3
|
export { ServiceContext } from "./core/lib/services/service_context";
|
|
6
4
|
export { PortSpec, TransportProtocol } from "./core/lib/services/port_spec";
|
|
7
5
|
export { EnclaveContext } from "./core/lib/enclaves/enclave_context";
|
|
8
6
|
export type { EnclaveUUID, PartitionID } from "./core/lib/enclaves/enclave_context";
|
|
7
|
+
export type { FilesArtifactUUID } from "./core/lib/enclaves/files_artifact";
|
|
9
8
|
export { newExecCommandArgs, newGetServicesArgs, newWaitForHttpGetEndpointAvailabilityArgs, newWaitForHttpPostEndpointAvailabilityArgs } from "./core/lib/constructor_calls";
|
|
10
9
|
export { KurtosisContext, DEFAULT_GRPC_ENGINE_SERVER_PORT_NUM } from "./engine/lib/kurtosis_context/kurtosis_context";
|
|
11
10
|
export { ServiceLogsStreamContent } from "./engine/lib/kurtosis_context/service_logs_stream_content";
|
package/build/index.js
CHANGED
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.EnclaveAPIContainerHostMachineInfo = exports.LogLineFilter = exports.ServiceLog = exports.ServiceLogsStreamContent = exports.DEFAULT_GRPC_ENGINE_SERVER_PORT_NUM = exports.KurtosisContext = exports.newWaitForHttpPostEndpointAvailabilityArgs = exports.newWaitForHttpGetEndpointAvailabilityArgs = exports.newGetServicesArgs = exports.newExecCommandArgs = exports.EnclaveContext = exports.TransportProtocol = exports.PortSpec = exports.ServiceContext = exports.
|
|
3
|
+
exports.EnclaveAPIContainerHostMachineInfo = exports.LogLineFilter = exports.ServiceLog = exports.ServiceLogsStreamContent = exports.DEFAULT_GRPC_ENGINE_SERVER_PORT_NUM = exports.KurtosisContext = exports.newWaitForHttpPostEndpointAvailabilityArgs = exports.newWaitForHttpGetEndpointAvailabilityArgs = exports.newGetServicesArgs = exports.newExecCommandArgs = exports.EnclaveContext = exports.TransportProtocol = exports.PortSpec = exports.ServiceContext = exports.KURTOSIS_VERSION = void 0;
|
|
4
4
|
// Own Version
|
|
5
5
|
var kurtosis_version_1 = require("./kurtosis_version/kurtosis_version");
|
|
6
6
|
Object.defineProperty(exports, "KURTOSIS_VERSION", { enumerable: true, get: function () { return kurtosis_version_1.KURTOSIS_VERSION; } });
|
|
7
|
-
var container_config_1 = require("./core/lib/services/container_config");
|
|
8
|
-
Object.defineProperty(exports, "ContainerConfigBuilder", { enumerable: true, get: function () { return container_config_1.ContainerConfigBuilder; } });
|
|
9
7
|
var service_context_1 = require("./core/lib/services/service_context");
|
|
10
8
|
Object.defineProperty(exports, "ServiceContext", { enumerable: true, get: function () { return service_context_1.ServiceContext; } });
|
|
11
9
|
var port_spec_1 = require("./core/lib/services/port_spec");
|
|
@@ -4,5 +4,5 @@ exports.KURTOSIS_VERSION = void 0;
|
|
|
4
4
|
// !!!!!!!!!!! DO NOT UPDATE! WILL BE MANUALLY UPDATED DURING THE RELEASE PROCESS !!!!!!!!!!!!!!!!!!!!!!
|
|
5
5
|
// This is necessary so that Kurt Core consumers (e.g. modules) will know if they're compatible with the currently-running
|
|
6
6
|
// API container
|
|
7
|
-
exports.KURTOSIS_VERSION = "0.80.
|
|
7
|
+
exports.KURTOSIS_VERSION = "0.80.7";
|
|
8
8
|
// !!!!!!!!!!! DO NOT UPDATE! WILL BE MANUALLY UPDATED DURING THE RELEASE PROCESS !!!!!!!!!!!!!!!!!!!!!!
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "kurtosis-sdk",
|
|
3
3
|
"//": "NOTE: DO NOT UPDATE THIS VERSION MANUALLY - IT WILL BE UPDATED DURING THE RELEASE PROCESS!",
|
|
4
|
-
"version": "0.80.
|
|
4
|
+
"version": "0.80.7",
|
|
5
5
|
"main": "./build/index",
|
|
6
6
|
"description": "This repo contains a Typescript client for communicating with the Kurtosis Engine server, which is responsible for creating, managing and destroying Kurtosis Enclaves.",
|
|
7
7
|
"types": "./build/index",
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import { PortSpec } from "./port_spec";
|
|
2
|
-
export type FilesArtifactUUID = string;
|
|
3
|
-
export declare class ContainerConfig {
|
|
4
|
-
readonly image: string;
|
|
5
|
-
readonly usedPorts: Map<string, PortSpec>;
|
|
6
|
-
readonly publicPorts: Map<string, PortSpec>;
|
|
7
|
-
readonly filesArtifactMountpoints: Map<string, FilesArtifactUUID>;
|
|
8
|
-
readonly entrypointOverrideArgs: string[];
|
|
9
|
-
readonly cmdOverrideArgs: string[];
|
|
10
|
-
readonly environmentVariableOverrides: Map<string, string>;
|
|
11
|
-
readonly cpuAllocationMillicpus: number;
|
|
12
|
-
readonly memoryAllocationMegabytes: number;
|
|
13
|
-
readonly privateIPAddrPlaceholder: string;
|
|
14
|
-
constructor(image: string, usedPorts: Map<string, PortSpec>, publicPorts: Map<string, PortSpec>, //TODO this is a huge hack to temporarily enable static ports for NEAR until we have a more productized solution
|
|
15
|
-
filesArtifactMountpoints: Map<string, FilesArtifactUUID>, entrypointOverrideArgs: string[], cmdOverrideArgs: string[], environmentVariableOverrides: Map<string, string>, cpuAllocationMillicpus: number, memoryAllocationMegabytes: number, privateIPAddrPlaceholder: string);
|
|
16
|
-
}
|
|
17
|
-
export declare class ContainerConfigBuilder {
|
|
18
|
-
private readonly image;
|
|
19
|
-
private usedPorts;
|
|
20
|
-
private publicPorts;
|
|
21
|
-
private filesArtifactMountpoints;
|
|
22
|
-
private entrypointOverrideArgs;
|
|
23
|
-
private cmdOverrideArgs;
|
|
24
|
-
private environmentVariableOverrides;
|
|
25
|
-
private cpuAllocationMillicpus;
|
|
26
|
-
private memoryAllocationMegabytes;
|
|
27
|
-
private privateIPAddrPlaceholder;
|
|
28
|
-
constructor(image: string);
|
|
29
|
-
withUsedPorts(usedPorts: Map<string, PortSpec>): ContainerConfigBuilder;
|
|
30
|
-
withFiles(filesArtifactMountpoints: Map<string, FilesArtifactUUID>): ContainerConfigBuilder;
|
|
31
|
-
withEntrypointOverride(args: string[]): ContainerConfigBuilder;
|
|
32
|
-
withCmdOverride(args: string[]): ContainerConfigBuilder;
|
|
33
|
-
withEnvironmentVariableOverrides(envVars: Map<string, string>): ContainerConfigBuilder;
|
|
34
|
-
withPublicPorts(publicPorts: Map<string, PortSpec>): ContainerConfigBuilder;
|
|
35
|
-
withCpuAllocationMillicpus(cpuAllocationMillicpus: number): ContainerConfigBuilder;
|
|
36
|
-
withMemoryAllocationMegabytes(memoryAllocationMegabytes: number): ContainerConfigBuilder;
|
|
37
|
-
withPrivateIPAddrPlaceholder(privateIPAddrPlaceholder: string): ContainerConfigBuilder;
|
|
38
|
-
build(): ContainerConfig;
|
|
39
|
-
}
|
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ContainerConfigBuilder = exports.ContainerConfig = void 0;
|
|
4
|
-
const DEFAULT_PRIVATE_IP_ADDR_PLACEHOLDER = "KURTOSIS_PRIVATE_IP_ADDR_PLACEHOLDER";
|
|
5
|
-
// ====================================================================================================
|
|
6
|
-
// Config Object
|
|
7
|
-
// ====================================================================================================
|
|
8
|
-
// TODO defensive copy when we're giving back complex objects?????
|
|
9
|
-
// Docs available at https://docs.kurtosis.com/sdk/#containerconfig
|
|
10
|
-
class ContainerConfig {
|
|
11
|
-
constructor(image, usedPorts, publicPorts, //TODO this is a huge hack to temporarily enable static ports for NEAR until we have a more productized solution
|
|
12
|
-
filesArtifactMountpoints, entrypointOverrideArgs, cmdOverrideArgs, environmentVariableOverrides, cpuAllocationMillicpus, memoryAllocationMegabytes, privateIPAddrPlaceholder) {
|
|
13
|
-
this.image = image;
|
|
14
|
-
this.usedPorts = usedPorts;
|
|
15
|
-
this.publicPorts = publicPorts;
|
|
16
|
-
this.filesArtifactMountpoints = filesArtifactMountpoints;
|
|
17
|
-
this.entrypointOverrideArgs = entrypointOverrideArgs;
|
|
18
|
-
this.cmdOverrideArgs = cmdOverrideArgs;
|
|
19
|
-
this.environmentVariableOverrides = environmentVariableOverrides;
|
|
20
|
-
this.cpuAllocationMillicpus = cpuAllocationMillicpus;
|
|
21
|
-
this.memoryAllocationMegabytes = memoryAllocationMegabytes;
|
|
22
|
-
this.privateIPAddrPlaceholder = privateIPAddrPlaceholder;
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
exports.ContainerConfig = ContainerConfig;
|
|
26
|
-
// ====================================================================================================
|
|
27
|
-
// Builder
|
|
28
|
-
// ====================================================================================================
|
|
29
|
-
// TODO Defensive copies on all these With... functions???
|
|
30
|
-
// Docs available at https://docs.kurtosis.com/sdk/#containerconfigbuilder
|
|
31
|
-
class ContainerConfigBuilder {
|
|
32
|
-
constructor(image) {
|
|
33
|
-
this.image = image;
|
|
34
|
-
this.usedPorts = new Map();
|
|
35
|
-
this.filesArtifactMountpoints = new Map();
|
|
36
|
-
this.entrypointOverrideArgs = [];
|
|
37
|
-
this.cmdOverrideArgs = [];
|
|
38
|
-
this.environmentVariableOverrides = new Map();
|
|
39
|
-
this.publicPorts = new Map(); //TODO this is a huge hack to temporarily enable static ports for NEAR until we have a more productized solution
|
|
40
|
-
this.cpuAllocationMillicpus = 0;
|
|
41
|
-
this.memoryAllocationMegabytes = 0;
|
|
42
|
-
this.privateIPAddrPlaceholder = DEFAULT_PRIVATE_IP_ADDR_PLACEHOLDER;
|
|
43
|
-
}
|
|
44
|
-
withUsedPorts(usedPorts) {
|
|
45
|
-
this.usedPorts = usedPorts;
|
|
46
|
-
return this;
|
|
47
|
-
}
|
|
48
|
-
withFiles(filesArtifactMountpoints) {
|
|
49
|
-
this.filesArtifactMountpoints = filesArtifactMountpoints;
|
|
50
|
-
return this;
|
|
51
|
-
}
|
|
52
|
-
withEntrypointOverride(args) {
|
|
53
|
-
this.entrypointOverrideArgs = args;
|
|
54
|
-
return this;
|
|
55
|
-
}
|
|
56
|
-
withCmdOverride(args) {
|
|
57
|
-
this.cmdOverrideArgs = args;
|
|
58
|
-
return this;
|
|
59
|
-
}
|
|
60
|
-
withEnvironmentVariableOverrides(envVars) {
|
|
61
|
-
this.environmentVariableOverrides = envVars;
|
|
62
|
-
return this;
|
|
63
|
-
}
|
|
64
|
-
//TODO this is a huge hack to temporarily enable static ports for NEAR until we have a more productized solution
|
|
65
|
-
withPublicPorts(publicPorts) {
|
|
66
|
-
this.publicPorts = publicPorts;
|
|
67
|
-
return this;
|
|
68
|
-
}
|
|
69
|
-
withCpuAllocationMillicpus(cpuAllocationMillicpus) {
|
|
70
|
-
this.cpuAllocationMillicpus = cpuAllocationMillicpus;
|
|
71
|
-
return this;
|
|
72
|
-
}
|
|
73
|
-
withMemoryAllocationMegabytes(memoryAllocationMegabytes) {
|
|
74
|
-
this.memoryAllocationMegabytes = memoryAllocationMegabytes;
|
|
75
|
-
return this;
|
|
76
|
-
}
|
|
77
|
-
withPrivateIPAddrPlaceholder(privateIPAddrPlaceholder) {
|
|
78
|
-
this.privateIPAddrPlaceholder = privateIPAddrPlaceholder;
|
|
79
|
-
return this;
|
|
80
|
-
}
|
|
81
|
-
build() {
|
|
82
|
-
return new ContainerConfig(this.image, this.usedPorts, this.publicPorts, this.filesArtifactMountpoints, this.entrypointOverrideArgs, this.cmdOverrideArgs, this.environmentVariableOverrides, this.cpuAllocationMillicpus, this.memoryAllocationMegabytes, this.privateIPAddrPlaceholder);
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
exports.ContainerConfigBuilder = ContainerConfigBuilder;
|