diff --git a/enclave-manager/api/golang/kurtosis_enclave_manager_api_bindings/kurtosis_enclave_manager_api.pb.go b/enclave-manager/api/golang/kurtosis_enclave_manager_api_bindings/kurtosis_enclave_manager_api.pb.go index d8d88d01fb..4398485a9e 100644 --- a/enclave-manager/api/golang/kurtosis_enclave_manager_api_bindings/kurtosis_enclave_manager_api.pb.go +++ b/enclave-manager/api/golang/kurtosis_enclave_manager_api_bindings/kurtosis_enclave_manager_api.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.31.0 -// protoc v4.24.4 +// protoc-gen-go v1.32.0 +// protoc v4.25.2 // source: kurtosis_enclave_manager_api.proto package kurtosis_enclave_manager_api_bindings @@ -824,6 +824,77 @@ func (x *AddAliasRequest) GetEnclaveShortUuid() string { return "" } +type PublishPackageRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + AuthCode string `protobuf:"bytes,1,opt,name=authCode,proto3" json:"authCode,omitempty"` + PackageName string `protobuf:"bytes,2,opt,name=packageName,proto3" json:"packageName,omitempty"` + SerializedStarlarkScript string `protobuf:"bytes,3,opt,name=serializedStarlarkScript,proto3" json:"serializedStarlarkScript,omitempty"` + SerializedPackageIcon []byte `protobuf:"bytes,4,opt,name=serializedPackageIcon,proto3" json:"serializedPackageIcon,omitempty"` +} + +func (x *PublishPackageRequest) Reset() { + *x = PublishPackageRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_kurtosis_enclave_manager_api_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *PublishPackageRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*PublishPackageRequest) ProtoMessage() {} + +func (x *PublishPackageRequest) ProtoReflect() protoreflect.Message { + mi := &file_kurtosis_enclave_manager_api_proto_msgTypes[13] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use PublishPackageRequest.ProtoReflect.Descriptor instead. +func (*PublishPackageRequest) Descriptor() ([]byte, []int) { + return file_kurtosis_enclave_manager_api_proto_rawDescGZIP(), []int{13} +} + +func (x *PublishPackageRequest) GetAuthCode() string { + if x != nil { + return x.AuthCode + } + return "" +} + +func (x *PublishPackageRequest) GetPackageName() string { + if x != nil { + return x.PackageName + } + return "" +} + +func (x *PublishPackageRequest) GetSerializedStarlarkScript() string { + if x != nil { + return x.SerializedStarlarkScript + } + return "" +} + +func (x *PublishPackageRequest) GetSerializedPackageIcon() []byte { + if x != nil { + return x.SerializedPackageIcon + } + return nil +} + // ============================================================================================== // // Get Starlark Plan Yaml @@ -842,7 +913,7 @@ type StarlarkScriptPlanYamlArgs struct { func (x *StarlarkScriptPlanYamlArgs) Reset() { *x = StarlarkScriptPlanYamlArgs{} if protoimpl.UnsafeEnabled { - mi := &file_kurtosis_enclave_manager_api_proto_msgTypes[13] + mi := &file_kurtosis_enclave_manager_api_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -855,7 +926,7 @@ func (x *StarlarkScriptPlanYamlArgs) String() string { func (*StarlarkScriptPlanYamlArgs) ProtoMessage() {} func (x *StarlarkScriptPlanYamlArgs) ProtoReflect() protoreflect.Message { - mi := &file_kurtosis_enclave_manager_api_proto_msgTypes[13] + mi := &file_kurtosis_enclave_manager_api_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -868,7 +939,7 @@ func (x *StarlarkScriptPlanYamlArgs) ProtoReflect() protoreflect.Message { // Deprecated: Use StarlarkScriptPlanYamlArgs.ProtoReflect.Descriptor instead. func (*StarlarkScriptPlanYamlArgs) Descriptor() ([]byte, []int) { - return file_kurtosis_enclave_manager_api_proto_rawDescGZIP(), []int{13} + return file_kurtosis_enclave_manager_api_proto_rawDescGZIP(), []int{14} } func (x *StarlarkScriptPlanYamlArgs) GetApicIpAddress() string { @@ -905,7 +976,7 @@ type StarlarkPackagePlanYamlArgs struct { func (x *StarlarkPackagePlanYamlArgs) Reset() { *x = StarlarkPackagePlanYamlArgs{} if protoimpl.UnsafeEnabled { - mi := &file_kurtosis_enclave_manager_api_proto_msgTypes[14] + mi := &file_kurtosis_enclave_manager_api_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -918,7 +989,7 @@ func (x *StarlarkPackagePlanYamlArgs) String() string { func (*StarlarkPackagePlanYamlArgs) ProtoMessage() {} func (x *StarlarkPackagePlanYamlArgs) ProtoReflect() protoreflect.Message { - mi := &file_kurtosis_enclave_manager_api_proto_msgTypes[14] + mi := &file_kurtosis_enclave_manager_api_proto_msgTypes[15] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -931,7 +1002,7 @@ func (x *StarlarkPackagePlanYamlArgs) ProtoReflect() protoreflect.Message { // Deprecated: Use StarlarkPackagePlanYamlArgs.ProtoReflect.Descriptor instead. func (*StarlarkPackagePlanYamlArgs) Descriptor() ([]byte, []int) { - return file_kurtosis_enclave_manager_api_proto_rawDescGZIP(), []int{14} + return file_kurtosis_enclave_manager_api_proto_rawDescGZIP(), []int{15} } func (x *StarlarkPackagePlanYamlArgs) GetApicIpAddress() string { @@ -1084,184 +1155,203 @@ var file_kurtosis_enclave_manager_api_proto_rawDesc = []byte{ 0x53, 0x68, 0x6f, 0x72, 0x74, 0x55, 0x75, 0x69, 0x64, 0x12, 0x2c, 0x0a, 0x12, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x73, 0x68, 0x6f, 0x72, 0x74, 0x5f, 0x75, 0x75, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x53, 0x68, - 0x6f, 0x72, 0x74, 0x55, 0x75, 0x69, 0x64, 0x22, 0xd4, 0x01, 0x0a, 0x1a, 0x53, 0x74, 0x61, 0x72, - 0x6c, 0x61, 0x72, 0x6b, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, - 0x6d, 0x6c, 0x41, 0x72, 0x67, 0x73, 0x12, 0x26, 0x0a, 0x0f, 0x61, 0x70, 0x69, 0x63, 0x5f, 0x69, - 0x70, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0d, 0x61, 0x70, 0x69, 0x63, 0x49, 0x70, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x1b, - 0x0a, 0x09, 0x61, 0x70, 0x69, 0x63, 0x5f, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x05, 0x52, 0x08, 0x61, 0x70, 0x69, 0x63, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x71, 0x0a, 0x1e, 0x73, - 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x5f, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x5f, 0x70, - 0x6c, 0x61, 0x6e, 0x5f, 0x79, 0x61, 0x6d, 0x6c, 0x5f, 0x61, 0x72, 0x67, 0x73, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, - 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, - 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x41, 0x72, - 0x67, 0x73, 0x52, 0x1a, 0x73, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x53, 0x63, 0x72, 0x69, - 0x70, 0x74, 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x41, 0x72, 0x67, 0x73, 0x22, 0xd8, - 0x01, 0x0a, 0x1b, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x50, 0x61, 0x63, 0x6b, 0x61, - 0x67, 0x65, 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x41, 0x72, 0x67, 0x73, 0x12, 0x26, - 0x0a, 0x0f, 0x61, 0x70, 0x69, 0x63, 0x5f, 0x69, 0x70, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, - 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x61, 0x70, 0x69, 0x63, 0x49, 0x70, 0x41, - 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x1b, 0x0a, 0x09, 0x61, 0x70, 0x69, 0x63, 0x5f, 0x70, - 0x6f, 0x72, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x61, 0x70, 0x69, 0x63, 0x50, - 0x6f, 0x72, 0x74, 0x12, 0x74, 0x0a, 0x1f, 0x73, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x5f, - 0x70, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x5f, 0x70, 0x6c, 0x61, 0x6e, 0x5f, 0x79, 0x61, 0x6d, - 0x6c, 0x5f, 0x61, 0x72, 0x67, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2e, 0x2e, 0x61, - 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, - 0x2e, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x50, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, - 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x41, 0x72, 0x67, 0x73, 0x52, 0x1b, 0x73, 0x74, - 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x50, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x50, 0x6c, 0x61, - 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x41, 0x72, 0x67, 0x73, 0x32, 0xe8, 0x11, 0x0a, 0x1c, 0x4b, 0x75, - 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x45, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x4d, 0x61, 0x6e, - 0x61, 0x67, 0x65, 0x72, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x12, 0x64, 0x0a, 0x05, 0x43, 0x68, - 0x65, 0x63, 0x6b, 0x12, 0x2c, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, - 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x48, - 0x65, 0x61, 0x6c, 0x74, 0x68, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x2d, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, - 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x48, 0x65, 0x61, - 0x6c, 0x74, 0x68, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x48, 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x45, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x73, 0x12, - 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, - 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x1f, 0x2e, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, - 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x47, 0x65, 0x74, 0x45, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x73, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x65, 0x0a, 0x0b, 0x47, 0x65, - 0x74, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x12, 0x2c, 0x2e, 0x6b, 0x75, 0x72, 0x74, - 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, - 0x61, 0x67, 0x65, 0x72, 0x2e, 0x47, 0x65, 0x74, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, - 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x47, 0x65, 0x74, 0x53, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x00, 0x12, 0x58, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x4c, - 0x6f, 0x67, 0x73, 0x12, 0x1e, 0x2e, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x5f, 0x61, 0x70, 0x69, - 0x2e, 0x47, 0x65, 0x74, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x4c, 0x6f, 0x67, 0x73, 0x41, - 0x72, 0x67, 0x73, 0x1a, 0x22, 0x2e, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x5f, 0x61, 0x70, 0x69, - 0x2e, 0x47, 0x65, 0x74, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x4c, 0x6f, 0x67, 0x73, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x30, 0x01, 0x12, 0xa1, 0x01, 0x0a, 0x1e, - 0x4c, 0x69, 0x73, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, - 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x73, 0x41, 0x6e, 0x64, 0x55, 0x75, 0x69, 0x64, 0x73, 0x12, 0x42, - 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, - 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x47, 0x65, 0x74, 0x4c, 0x69, 0x73, - 0x74, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, 0x4e, 0x61, - 0x6d, 0x65, 0x73, 0x41, 0x6e, 0x64, 0x55, 0x75, 0x69, 0x64, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x39, 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, - 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x73, + 0x6f, 0x72, 0x74, 0x55, 0x75, 0x69, 0x64, 0x22, 0xc7, 0x01, 0x0a, 0x15, 0x50, 0x75, 0x62, 0x6c, + 0x69, 0x73, 0x68, 0x50, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x61, 0x75, 0x74, 0x68, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x08, 0x61, 0x75, 0x74, 0x68, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x20, 0x0a, + 0x0b, 0x70, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0b, 0x70, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x12, + 0x3a, 0x0a, 0x18, 0x73, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x53, 0x74, 0x61, + 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x18, 0x73, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x53, 0x74, 0x61, + 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x12, 0x34, 0x0a, 0x15, 0x73, + 0x65, 0x72, 0x69, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x50, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, + 0x49, 0x63, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x15, 0x73, 0x65, 0x72, 0x69, + 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x50, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x49, 0x63, 0x6f, + 0x6e, 0x22, 0xd4, 0x01, 0x0a, 0x1a, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x53, 0x63, + 0x72, 0x69, 0x70, 0x74, 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x41, 0x72, 0x67, 0x73, + 0x12, 0x26, 0x0a, 0x0f, 0x61, 0x70, 0x69, 0x63, 0x5f, 0x69, 0x70, 0x5f, 0x61, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x61, 0x70, 0x69, 0x63, 0x49, + 0x70, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x1b, 0x0a, 0x09, 0x61, 0x70, 0x69, 0x63, + 0x5f, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x61, 0x70, 0x69, + 0x63, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x71, 0x0a, 0x1e, 0x73, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, + 0x6b, 0x5f, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x5f, 0x70, 0x6c, 0x61, 0x6e, 0x5f, 0x79, 0x61, + 0x6d, 0x6c, 0x5f, 0x61, 0x72, 0x67, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, + 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, + 0x69, 0x2e, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, + 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x41, 0x72, 0x67, 0x73, 0x52, 0x1a, 0x73, 0x74, + 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x50, 0x6c, 0x61, 0x6e, + 0x59, 0x61, 0x6d, 0x6c, 0x41, 0x72, 0x67, 0x73, 0x22, 0xd8, 0x01, 0x0a, 0x1b, 0x53, 0x74, 0x61, + 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x50, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x50, 0x6c, 0x61, 0x6e, + 0x59, 0x61, 0x6d, 0x6c, 0x41, 0x72, 0x67, 0x73, 0x12, 0x26, 0x0a, 0x0f, 0x61, 0x70, 0x69, 0x63, + 0x5f, 0x69, 0x70, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0d, 0x61, 0x70, 0x69, 0x63, 0x49, 0x70, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, + 0x12, 0x1b, 0x0a, 0x09, 0x61, 0x70, 0x69, 0x63, 0x5f, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x05, 0x52, 0x08, 0x61, 0x70, 0x69, 0x63, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x74, 0x0a, + 0x1f, 0x73, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x5f, 0x70, 0x61, 0x63, 0x6b, 0x61, 0x67, + 0x65, 0x5f, 0x70, 0x6c, 0x61, 0x6e, 0x5f, 0x79, 0x61, 0x6d, 0x6c, 0x5f, 0x61, 0x72, 0x67, 0x73, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2e, 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, + 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x53, 0x74, 0x61, 0x72, 0x6c, + 0x61, 0x72, 0x6b, 0x50, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, + 0x6d, 0x6c, 0x41, 0x72, 0x67, 0x73, 0x52, 0x1b, 0x73, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, + 0x50, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x41, + 0x72, 0x67, 0x73, 0x32, 0xcf, 0x12, 0x0a, 0x1c, 0x4b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, + 0x45, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x4d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x53, 0x65, + 0x72, 0x76, 0x65, 0x72, 0x12, 0x64, 0x0a, 0x05, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x12, 0x2c, 0x2e, + 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, + 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x48, 0x65, 0x61, 0x6c, 0x74, 0x68, 0x43, + 0x68, 0x65, 0x63, 0x6b, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2d, 0x2e, 0x6b, 0x75, + 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, + 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x48, 0x65, 0x61, 0x6c, 0x74, 0x68, 0x43, 0x68, 0x65, + 0x63, 0x6b, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x48, 0x0a, 0x0b, 0x47, 0x65, + 0x74, 0x45, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x73, 0x12, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, + 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, + 0x79, 0x1a, 0x1f, 0x2e, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x47, + 0x65, 0x74, 0x45, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x00, 0x12, 0x65, 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x53, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x73, 0x12, 0x2c, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, + 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x47, + 0x65, 0x74, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x26, 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, + 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x47, 0x65, 0x74, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x58, 0x0a, 0x0e, 0x47, + 0x65, 0x74, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x4c, 0x6f, 0x67, 0x73, 0x12, 0x1e, 0x2e, + 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x47, 0x65, 0x74, 0x53, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x4c, 0x6f, 0x67, 0x73, 0x41, 0x72, 0x67, 0x73, 0x1a, 0x22, 0x2e, + 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x47, 0x65, 0x74, 0x53, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x4c, 0x6f, 0x67, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x00, 0x30, 0x01, 0x12, 0xa1, 0x01, 0x0a, 0x1e, 0x4c, 0x69, 0x73, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x73, 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x73, + 0x41, 0x6e, 0x64, 0x55, 0x75, 0x69, 0x64, 0x73, 0x12, 0x42, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, + 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, + 0x67, 0x65, 0x72, 0x2e, 0x47, 0x65, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x73, 0x41, 0x6e, 0x64, - 0x55, 0x75, 0x69, 0x64, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, - 0x79, 0x0a, 0x12, 0x52, 0x75, 0x6e, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x50, 0x61, - 0x63, 0x6b, 0x61, 0x67, 0x65, 0x12, 0x33, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, - 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, - 0x2e, 0x52, 0x75, 0x6e, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x50, 0x61, 0x63, 0x6b, - 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2a, 0x2e, 0x61, 0x70, 0x69, - 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x53, - 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x52, 0x75, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x4c, 0x69, 0x6e, 0x65, 0x22, 0x00, 0x30, 0x01, 0x12, 0x77, 0x0a, 0x11, 0x52, 0x75, - 0x6e, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x12, - 0x32, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, + 0x55, 0x75, 0x69, 0x64, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x39, 0x2e, 0x61, + 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, + 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, + 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x73, 0x41, 0x6e, 0x64, 0x55, 0x75, 0x69, 0x64, 0x73, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x79, 0x0a, 0x12, 0x52, 0x75, 0x6e, + 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x50, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x12, + 0x33, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x52, 0x75, 0x6e, 0x53, 0x74, - 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x2a, 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, - 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, - 0x52, 0x75, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x4c, 0x69, 0x6e, 0x65, 0x22, - 0x00, 0x30, 0x01, 0x12, 0x53, 0x0a, 0x0d, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x45, 0x6e, 0x63, - 0x6c, 0x61, 0x76, 0x65, 0x12, 0x1d, 0x2e, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x5f, 0x61, 0x70, - 0x69, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x45, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x41, - 0x72, 0x67, 0x73, 0x1a, 0x21, 0x2e, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x5f, 0x61, 0x70, 0x69, - 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x45, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x98, 0x01, 0x0a, 0x1c, 0x49, 0x6e, 0x73, - 0x70, 0x65, 0x63, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, - 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x12, 0x3d, 0x2e, 0x6b, 0x75, 0x72, 0x74, + 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x50, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2a, 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, + 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, + 0x6b, 0x52, 0x75, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x4c, 0x69, 0x6e, 0x65, + 0x22, 0x00, 0x30, 0x01, 0x12, 0x77, 0x0a, 0x11, 0x52, 0x75, 0x6e, 0x53, 0x74, 0x61, 0x72, 0x6c, + 0x61, 0x72, 0x6b, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x12, 0x32, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, - 0x61, 0x67, 0x65, 0x72, 0x2e, 0x49, 0x6e, 0x73, 0x70, 0x65, 0x63, 0x74, 0x46, 0x69, 0x6c, 0x65, - 0x73, 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, - 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x37, 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, - 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x49, 0x6e, 0x73, - 0x70, 0x65, 0x63, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, - 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x00, 0x12, 0x79, 0x0a, 0x15, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, - 0x69, 0x6c, 0x65, 0x73, 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, 0x12, 0x36, 0x2e, 0x6b, - 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, - 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, - 0x46, 0x69, 0x6c, 0x65, 0x73, 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x24, 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, - 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x65, - 0x64, 0x44, 0x61, 0x74, 0x61, 0x43, 0x68, 0x75, 0x6e, 0x6b, 0x22, 0x00, 0x30, 0x01, 0x12, 0x4a, - 0x0a, 0x0e, 0x44, 0x65, 0x73, 0x74, 0x72, 0x6f, 0x79, 0x45, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, - 0x12, 0x1e, 0x2e, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x44, 0x65, - 0x73, 0x74, 0x72, 0x6f, 0x79, 0x45, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x41, 0x72, 0x67, 0x73, - 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x6e, 0x0a, 0x0e, 0x47, 0x65, - 0x74, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x52, 0x75, 0x6e, 0x12, 0x2f, 0x2e, 0x6b, - 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, - 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x72, 0x6c, - 0x61, 0x72, 0x6b, 0x52, 0x75, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, - 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, - 0x69, 0x2e, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x52, 0x75, 0x6e, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x70, 0x0a, 0x19, 0x47, 0x65, - 0x74, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x50, - 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x12, 0x34, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, - 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, - 0x65, 0x72, 0x2e, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x53, 0x63, 0x72, 0x69, 0x70, - 0x74, 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x41, 0x72, 0x67, 0x73, 0x1a, 0x1b, 0x2e, + 0x61, 0x67, 0x65, 0x72, 0x2e, 0x52, 0x75, 0x6e, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, + 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2a, 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, - 0x69, 0x2e, 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x22, 0x00, 0x12, 0x72, 0x0a, 0x1a, - 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x50, 0x61, 0x63, 0x6b, 0x61, - 0x67, 0x65, 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x12, 0x35, 0x2e, 0x6b, 0x75, 0x72, - 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, - 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x50, 0x61, - 0x63, 0x6b, 0x61, 0x67, 0x65, 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x41, 0x72, 0x67, - 0x73, 0x1a, 0x1b, 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, - 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x22, 0x00, - 0x12, 0x6d, 0x0a, 0x17, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x70, 0x6f, 0x73, 0x69, - 0x74, 0x6f, 0x72, 0x79, 0x57, 0x65, 0x62, 0x68, 0x6f, 0x6f, 0x6b, 0x12, 0x38, 0x2e, 0x6b, 0x75, + 0x69, 0x2e, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x52, 0x75, 0x6e, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x4c, 0x69, 0x6e, 0x65, 0x22, 0x00, 0x30, 0x01, 0x12, 0x53, 0x0a, + 0x0d, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x45, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x12, 0x1d, + 0x2e, 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x43, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x45, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x41, 0x72, 0x67, 0x73, 0x1a, 0x21, 0x2e, + 0x65, 0x6e, 0x67, 0x69, 0x6e, 0x65, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x45, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x00, 0x12, 0x98, 0x01, 0x0a, 0x1c, 0x49, 0x6e, 0x73, 0x70, 0x65, 0x63, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x73, 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, + 0x6e, 0x74, 0x73, 0x12, 0x3d, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, + 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x49, + 0x6e, 0x73, 0x70, 0x65, 0x63, 0x74, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x41, 0x72, 0x74, 0x69, 0x66, + 0x61, 0x63, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x37, 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, + 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x49, 0x6e, 0x73, 0x70, 0x65, 0x63, 0x74, 0x46, 0x69, + 0x6c, 0x65, 0x73, 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, + 0x6e, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x79, 0x0a, + 0x15, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x41, 0x72, + 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, 0x12, 0x36, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, + 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, + 0x72, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x41, + 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x24, + 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, + 0x70, 0x69, 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x65, 0x64, 0x44, 0x61, 0x74, 0x61, 0x43, + 0x68, 0x75, 0x6e, 0x6b, 0x22, 0x00, 0x30, 0x01, 0x12, 0x4a, 0x0a, 0x0e, 0x44, 0x65, 0x73, 0x74, + 0x72, 0x6f, 0x79, 0x45, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x12, 0x1e, 0x2e, 0x65, 0x6e, 0x67, + 0x69, 0x6e, 0x65, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x44, 0x65, 0x73, 0x74, 0x72, 0x6f, 0x79, 0x45, + 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x41, 0x72, 0x67, 0x73, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, + 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, + 0x74, 0x79, 0x22, 0x00, 0x12, 0x6e, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x72, 0x6c, + 0x61, 0x72, 0x6b, 0x52, 0x75, 0x6e, 0x12, 0x2f, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, + 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, + 0x72, 0x2e, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x52, 0x75, 0x6e, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, + 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x47, 0x65, 0x74, 0x53, + 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x52, 0x75, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x00, 0x12, 0x70, 0x0a, 0x19, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x72, 0x6c, + 0x61, 0x72, 0x6b, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, + 0x6c, 0x12, 0x34, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, + 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x53, 0x74, 0x61, + 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x50, 0x6c, 0x61, 0x6e, 0x59, + 0x61, 0x6d, 0x6c, 0x41, 0x72, 0x67, 0x73, 0x1a, 0x1b, 0x2e, 0x61, 0x70, 0x69, 0x5f, 0x63, 0x6f, + 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, 0x50, 0x6c, 0x61, 0x6e, + 0x59, 0x61, 0x6d, 0x6c, 0x22, 0x00, 0x12, 0x72, 0x0a, 0x1a, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, + 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x50, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x50, 0x6c, 0x61, 0x6e, + 0x59, 0x61, 0x6d, 0x6c, 0x12, 0x35, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, + 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, + 0x53, 0x74, 0x61, 0x72, 0x6c, 0x61, 0x72, 0x6b, 0x50, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, 0x50, + 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x41, 0x72, 0x67, 0x73, 0x1a, 0x1b, 0x2e, 0x61, 0x70, + 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x61, 0x70, 0x69, 0x2e, + 0x50, 0x6c, 0x61, 0x6e, 0x59, 0x61, 0x6d, 0x6c, 0x22, 0x00, 0x12, 0x6d, 0x0a, 0x17, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, 0x79, 0x57, 0x65, + 0x62, 0x68, 0x6f, 0x6f, 0x6b, 0x12, 0x38, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, + 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, + 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, + 0x79, 0x57, 0x65, 0x62, 0x68, 0x6f, 0x6f, 0x6b, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, + 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x83, 0x01, 0x0a, 0x16, 0x47, 0x65, + 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x43, 0x6f, + 0x6e, 0x66, 0x69, 0x67, 0x12, 0x37, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, + 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, + 0x47, 0x65, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, + 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2e, 0x2e, + 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x2e, 0x47, + 0x65, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x43, + 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, + 0x55, 0x0a, 0x08, 0x4c, 0x6f, 0x63, 0x6b, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x2f, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, - 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x70, - 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, 0x79, 0x57, 0x65, 0x62, 0x68, 0x6f, 0x6f, 0x6b, 0x52, 0x65, + 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x4c, 0x6f, 0x63, 0x6b, 0x55, 0x6e, 0x6c, 0x6f, 0x63, + 0x6b, 0x50, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, + 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, + 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x57, 0x0a, 0x0a, 0x55, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, + 0x50, 0x6f, 0x72, 0x74, 0x12, 0x2f, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, + 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, + 0x4c, 0x6f, 0x63, 0x6b, 0x55, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, 0x50, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, - 0x83, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x49, 0x6e, 0x73, 0x74, - 0x61, 0x6e, 0x63, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x37, 0x2e, 0x6b, 0x75, 0x72, - 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, - 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x49, 0x6e, - 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x2e, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x63, - 0x6c, 0x6f, 0x75, 0x64, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x49, 0x6e, 0x73, - 0x74, 0x61, 0x6e, 0x63, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x55, 0x0a, 0x08, 0x4c, 0x6f, 0x63, 0x6b, 0x50, 0x6f, 0x72, - 0x74, 0x12, 0x2f, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, - 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x4c, 0x6f, 0x63, - 0x6b, 0x55, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, 0x50, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x57, 0x0a, 0x0a, - 0x55, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x2f, 0x2e, 0x6b, 0x75, 0x72, + 0x4f, 0x0a, 0x08, 0x41, 0x64, 0x64, 0x41, 0x6c, 0x69, 0x61, 0x73, 0x12, 0x29, 0x2e, 0x6b, 0x75, + 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, + 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x41, 0x64, 0x64, 0x41, 0x6c, 0x69, 0x61, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, + 0x12, 0x70, 0x0a, 0x1d, 0x49, 0x73, 0x4e, 0x65, 0x77, 0x4b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, + 0x73, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x41, 0x76, 0x61, 0x69, 0x6c, 0x61, 0x62, 0x6c, + 0x65, 0x12, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x35, 0x2e, 0x6b, 0x75, 0x72, 0x74, + 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x2e, 0x49, 0x73, 0x4e, 0x65, 0x77, + 0x4b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x41, + 0x76, 0x61, 0x69, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x00, 0x12, 0x4a, 0x0a, 0x16, 0x55, 0x70, 0x67, 0x72, 0x61, 0x64, 0x65, 0x4b, 0x75, 0x72, + 0x74, 0x6f, 0x73, 0x69, 0x73, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x16, 0x2e, 0x67, + 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, + 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x65, + 0x0a, 0x18, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x73, 0x68, 0x50, 0x61, 0x63, 0x6b, 0x61, 0x67, 0x65, + 0x52, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, 0x79, 0x12, 0x2f, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, - 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x4c, 0x6f, 0x63, 0x6b, 0x55, 0x6e, 0x6c, 0x6f, 0x63, 0x6b, - 0x50, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f, + 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x73, 0x68, 0x50, 0x61, 0x63, + 0x6b, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, - 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x4f, 0x0a, 0x08, 0x41, 0x64, 0x64, 0x41, 0x6c, 0x69, 0x61, - 0x73, 0x12, 0x29, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, 0x63, - 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2e, 0x41, 0x64, 0x64, - 0x41, 0x6c, 0x69, 0x61, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, - 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, - 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x70, 0x0a, 0x1d, 0x49, 0x73, 0x4e, 0x65, 0x77, 0x4b, - 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x41, 0x76, - 0x61, 0x69, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x12, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, - 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, - 0x35, 0x2e, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x63, 0x6c, 0x6f, 0x75, 0x64, - 0x2e, 0x49, 0x73, 0x4e, 0x65, 0x77, 0x4b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x56, 0x65, - 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x41, 0x76, 0x61, 0x69, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4a, 0x0a, 0x16, 0x55, 0x70, 0x67, 0x72, - 0x61, 0x64, 0x65, 0x4b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x56, 0x65, 0x72, 0x73, 0x69, - 0x6f, 0x6e, 0x12, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, - 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, - 0x74, 0x79, 0x22, 0x00, 0x42, 0x64, 0x5a, 0x62, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, - 0x6f, 0x6d, 0x2f, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x2d, 0x74, 0x65, 0x63, 0x68, - 0x2f, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x2f, 0x65, 0x6e, 0x63, 0x6c, 0x61, 0x76, - 0x65, 0x2d, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x67, 0x6f, - 0x6c, 0x61, 0x6e, 0x67, 0x2f, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, 0x6e, - 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x5f, 0x61, 0x70, - 0x69, 0x5f, 0x62, 0x69, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x33, + 0x70, 0x74, 0x79, 0x22, 0x00, 0x42, 0x64, 0x5a, 0x62, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, + 0x63, 0x6f, 0x6d, 0x2f, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x2d, 0x74, 0x65, 0x63, + 0x68, 0x2f, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x2f, 0x65, 0x6e, 0x63, 0x6c, 0x61, + 0x76, 0x65, 0x2d, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x67, + 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2f, 0x6b, 0x75, 0x72, 0x74, 0x6f, 0x73, 0x69, 0x73, 0x5f, 0x65, + 0x6e, 0x63, 0x6c, 0x61, 0x76, 0x65, 0x5f, 0x6d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x72, 0x5f, 0x61, + 0x70, 0x69, 0x5f, 0x62, 0x69, 0x6e, 0x64, 0x69, 0x6e, 0x67, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x33, } var ( @@ -1277,7 +1367,7 @@ func file_kurtosis_enclave_manager_api_proto_rawDescGZIP() []byte { } var file_kurtosis_enclave_manager_api_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_kurtosis_enclave_manager_api_proto_msgTypes = make([]protoimpl.MessageInfo, 15) +var file_kurtosis_enclave_manager_api_proto_msgTypes = make([]protoimpl.MessageInfo, 16) var file_kurtosis_enclave_manager_api_proto_goTypes = []interface{}{ (HealthCheckResponse_ServingStatus)(0), // 0: kurtosis_enclave_manager.HealthCheckResponse.ServingStatus (*GetCloudInstanceConfigRequest)(nil), // 1: kurtosis_enclave_manager.GetCloudInstanceConfigRequest @@ -1293,83 +1383,86 @@ var file_kurtosis_enclave_manager_api_proto_goTypes = []interface{}{ (*CreateRepositoryWebhookRequest)(nil), // 11: kurtosis_enclave_manager.CreateRepositoryWebhookRequest (*LockUnlockPortRequest)(nil), // 12: kurtosis_enclave_manager.LockUnlockPortRequest (*AddAliasRequest)(nil), // 13: kurtosis_enclave_manager.AddAliasRequest - (*StarlarkScriptPlanYamlArgs)(nil), // 14: kurtosis_enclave_manager.StarlarkScriptPlanYamlArgs - (*StarlarkPackagePlanYamlArgs)(nil), // 15: kurtosis_enclave_manager.StarlarkPackagePlanYamlArgs - (*kurtosis_core_rpc_api_bindings.RunStarlarkPackageArgs)(nil), // 16: api_container_api.RunStarlarkPackageArgs - (*kurtosis_core_rpc_api_bindings.RunStarlarkScriptArgs)(nil), // 17: api_container_api.RunStarlarkScriptArgs - (*kurtosis_core_rpc_api_bindings.FilesArtifactNameAndUuid)(nil), // 18: api_container_api.FilesArtifactNameAndUuid - (*kurtosis_core_rpc_api_bindings.DownloadFilesArtifactArgs)(nil), // 19: api_container_api.DownloadFilesArtifactArgs - (*kurtosis_core_rpc_api_bindings.StarlarkScriptPlanYamlArgs)(nil), // 20: api_container_api.StarlarkScriptPlanYamlArgs - (*kurtosis_core_rpc_api_bindings.StarlarkPackagePlanYamlArgs)(nil), // 21: api_container_api.StarlarkPackagePlanYamlArgs - (*emptypb.Empty)(nil), // 22: google.protobuf.Empty - (*kurtosis_engine_rpc_api_bindings.GetServiceLogsArgs)(nil), // 23: engine_api.GetServiceLogsArgs - (*kurtosis_engine_rpc_api_bindings.CreateEnclaveArgs)(nil), // 24: engine_api.CreateEnclaveArgs - (*kurtosis_engine_rpc_api_bindings.DestroyEnclaveArgs)(nil), // 25: engine_api.DestroyEnclaveArgs - (*kurtosis_engine_rpc_api_bindings.GetEnclavesResponse)(nil), // 26: engine_api.GetEnclavesResponse - (*kurtosis_core_rpc_api_bindings.GetServicesResponse)(nil), // 27: api_container_api.GetServicesResponse - (*kurtosis_engine_rpc_api_bindings.GetServiceLogsResponse)(nil), // 28: engine_api.GetServiceLogsResponse - (*kurtosis_core_rpc_api_bindings.ListFilesArtifactNamesAndUuidsResponse)(nil), // 29: api_container_api.ListFilesArtifactNamesAndUuidsResponse - (*kurtosis_core_rpc_api_bindings.StarlarkRunResponseLine)(nil), // 30: api_container_api.StarlarkRunResponseLine - (*kurtosis_engine_rpc_api_bindings.CreateEnclaveResponse)(nil), // 31: engine_api.CreateEnclaveResponse - (*kurtosis_core_rpc_api_bindings.InspectFilesArtifactContentsResponse)(nil), // 32: api_container_api.InspectFilesArtifactContentsResponse - (*kurtosis_core_rpc_api_bindings.StreamedDataChunk)(nil), // 33: api_container_api.StreamedDataChunk - (*kurtosis_core_rpc_api_bindings.GetStarlarkRunResponse)(nil), // 34: api_container_api.GetStarlarkRunResponse - (*kurtosis_core_rpc_api_bindings.PlanYaml)(nil), // 35: api_container_api.PlanYaml - (*kurtosis_backend_server_rpc_api_bindings.GetCloudInstanceConfigResponse)(nil), // 36: kurtosis_cloud.GetCloudInstanceConfigResponse - (*kurtosis_backend_server_rpc_api_bindings.IsNewKurtosisVersionAvailableResponse)(nil), // 37: kurtosis_cloud.IsNewKurtosisVersionAvailableResponse + (*PublishPackageRequest)(nil), // 14: kurtosis_enclave_manager.PublishPackageRequest + (*StarlarkScriptPlanYamlArgs)(nil), // 15: kurtosis_enclave_manager.StarlarkScriptPlanYamlArgs + (*StarlarkPackagePlanYamlArgs)(nil), // 16: kurtosis_enclave_manager.StarlarkPackagePlanYamlArgs + (*kurtosis_core_rpc_api_bindings.RunStarlarkPackageArgs)(nil), // 17: api_container_api.RunStarlarkPackageArgs + (*kurtosis_core_rpc_api_bindings.RunStarlarkScriptArgs)(nil), // 18: api_container_api.RunStarlarkScriptArgs + (*kurtosis_core_rpc_api_bindings.FilesArtifactNameAndUuid)(nil), // 19: api_container_api.FilesArtifactNameAndUuid + (*kurtosis_core_rpc_api_bindings.DownloadFilesArtifactArgs)(nil), // 20: api_container_api.DownloadFilesArtifactArgs + (*kurtosis_core_rpc_api_bindings.StarlarkScriptPlanYamlArgs)(nil), // 21: api_container_api.StarlarkScriptPlanYamlArgs + (*kurtosis_core_rpc_api_bindings.StarlarkPackagePlanYamlArgs)(nil), // 22: api_container_api.StarlarkPackagePlanYamlArgs + (*emptypb.Empty)(nil), // 23: google.protobuf.Empty + (*kurtosis_engine_rpc_api_bindings.GetServiceLogsArgs)(nil), // 24: engine_api.GetServiceLogsArgs + (*kurtosis_engine_rpc_api_bindings.CreateEnclaveArgs)(nil), // 25: engine_api.CreateEnclaveArgs + (*kurtosis_engine_rpc_api_bindings.DestroyEnclaveArgs)(nil), // 26: engine_api.DestroyEnclaveArgs + (*kurtosis_engine_rpc_api_bindings.GetEnclavesResponse)(nil), // 27: engine_api.GetEnclavesResponse + (*kurtosis_core_rpc_api_bindings.GetServicesResponse)(nil), // 28: api_container_api.GetServicesResponse + (*kurtosis_engine_rpc_api_bindings.GetServiceLogsResponse)(nil), // 29: engine_api.GetServiceLogsResponse + (*kurtosis_core_rpc_api_bindings.ListFilesArtifactNamesAndUuidsResponse)(nil), // 30: api_container_api.ListFilesArtifactNamesAndUuidsResponse + (*kurtosis_core_rpc_api_bindings.StarlarkRunResponseLine)(nil), // 31: api_container_api.StarlarkRunResponseLine + (*kurtosis_engine_rpc_api_bindings.CreateEnclaveResponse)(nil), // 32: engine_api.CreateEnclaveResponse + (*kurtosis_core_rpc_api_bindings.InspectFilesArtifactContentsResponse)(nil), // 33: api_container_api.InspectFilesArtifactContentsResponse + (*kurtosis_core_rpc_api_bindings.StreamedDataChunk)(nil), // 34: api_container_api.StreamedDataChunk + (*kurtosis_core_rpc_api_bindings.GetStarlarkRunResponse)(nil), // 35: api_container_api.GetStarlarkRunResponse + (*kurtosis_core_rpc_api_bindings.PlanYaml)(nil), // 36: api_container_api.PlanYaml + (*kurtosis_backend_server_rpc_api_bindings.GetCloudInstanceConfigResponse)(nil), // 37: kurtosis_cloud.GetCloudInstanceConfigResponse + (*kurtosis_backend_server_rpc_api_bindings.IsNewKurtosisVersionAvailableResponse)(nil), // 38: kurtosis_cloud.IsNewKurtosisVersionAvailableResponse } var file_kurtosis_enclave_manager_api_proto_depIdxs = []int32{ 0, // 0: kurtosis_enclave_manager.HealthCheckResponse.status:type_name -> kurtosis_enclave_manager.HealthCheckResponse.ServingStatus - 16, // 1: kurtosis_enclave_manager.RunStarlarkPackageRequest.RunStarlarkPackageArgs:type_name -> api_container_api.RunStarlarkPackageArgs - 17, // 2: kurtosis_enclave_manager.RunStarlarkScriptRequest.RunStarlarkScriptArgs:type_name -> api_container_api.RunStarlarkScriptArgs - 18, // 3: kurtosis_enclave_manager.InspectFilesArtifactContentsRequest.file_names_and_uuid:type_name -> api_container_api.FilesArtifactNameAndUuid - 19, // 4: kurtosis_enclave_manager.DownloadFilesArtifactRequest.download_files_artifacts_args:type_name -> api_container_api.DownloadFilesArtifactArgs - 20, // 5: kurtosis_enclave_manager.StarlarkScriptPlanYamlArgs.starlark_script_plan_yaml_args:type_name -> api_container_api.StarlarkScriptPlanYamlArgs - 21, // 6: kurtosis_enclave_manager.StarlarkPackagePlanYamlArgs.starlark_package_plan_yaml_args:type_name -> api_container_api.StarlarkPackagePlanYamlArgs + 17, // 1: kurtosis_enclave_manager.RunStarlarkPackageRequest.RunStarlarkPackageArgs:type_name -> api_container_api.RunStarlarkPackageArgs + 18, // 2: kurtosis_enclave_manager.RunStarlarkScriptRequest.RunStarlarkScriptArgs:type_name -> api_container_api.RunStarlarkScriptArgs + 19, // 3: kurtosis_enclave_manager.InspectFilesArtifactContentsRequest.file_names_and_uuid:type_name -> api_container_api.FilesArtifactNameAndUuid + 20, // 4: kurtosis_enclave_manager.DownloadFilesArtifactRequest.download_files_artifacts_args:type_name -> api_container_api.DownloadFilesArtifactArgs + 21, // 5: kurtosis_enclave_manager.StarlarkScriptPlanYamlArgs.starlark_script_plan_yaml_args:type_name -> api_container_api.StarlarkScriptPlanYamlArgs + 22, // 6: kurtosis_enclave_manager.StarlarkPackagePlanYamlArgs.starlark_package_plan_yaml_args:type_name -> api_container_api.StarlarkPackagePlanYamlArgs 2, // 7: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.Check:input_type -> kurtosis_enclave_manager.HealthCheckRequest - 22, // 8: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetEnclaves:input_type -> google.protobuf.Empty + 23, // 8: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetEnclaves:input_type -> google.protobuf.Empty 4, // 9: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetServices:input_type -> kurtosis_enclave_manager.GetServicesRequest - 23, // 10: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetServiceLogs:input_type -> engine_api.GetServiceLogsArgs + 24, // 10: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetServiceLogs:input_type -> engine_api.GetServiceLogsArgs 5, // 11: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.ListFilesArtifactNamesAndUuids:input_type -> kurtosis_enclave_manager.GetListFilesArtifactNamesAndUuidsRequest 6, // 12: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.RunStarlarkPackage:input_type -> kurtosis_enclave_manager.RunStarlarkPackageRequest 7, // 13: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.RunStarlarkScript:input_type -> kurtosis_enclave_manager.RunStarlarkScriptRequest - 24, // 14: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.CreateEnclave:input_type -> engine_api.CreateEnclaveArgs + 25, // 14: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.CreateEnclave:input_type -> engine_api.CreateEnclaveArgs 8, // 15: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.InspectFilesArtifactContents:input_type -> kurtosis_enclave_manager.InspectFilesArtifactContentsRequest 9, // 16: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.DownloadFilesArtifact:input_type -> kurtosis_enclave_manager.DownloadFilesArtifactRequest - 25, // 17: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.DestroyEnclave:input_type -> engine_api.DestroyEnclaveArgs + 26, // 17: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.DestroyEnclave:input_type -> engine_api.DestroyEnclaveArgs 10, // 18: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetStarlarkRun:input_type -> kurtosis_enclave_manager.GetStarlarkRunRequest - 14, // 19: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetStarlarkScriptPlanYaml:input_type -> kurtosis_enclave_manager.StarlarkScriptPlanYamlArgs - 15, // 20: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetStarlarkPackagePlanYaml:input_type -> kurtosis_enclave_manager.StarlarkPackagePlanYamlArgs + 15, // 19: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetStarlarkScriptPlanYaml:input_type -> kurtosis_enclave_manager.StarlarkScriptPlanYamlArgs + 16, // 20: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetStarlarkPackagePlanYaml:input_type -> kurtosis_enclave_manager.StarlarkPackagePlanYamlArgs 11, // 21: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.CreateRepositoryWebhook:input_type -> kurtosis_enclave_manager.CreateRepositoryWebhookRequest 1, // 22: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetCloudInstanceConfig:input_type -> kurtosis_enclave_manager.GetCloudInstanceConfigRequest 12, // 23: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.LockPort:input_type -> kurtosis_enclave_manager.LockUnlockPortRequest 12, // 24: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.UnlockPort:input_type -> kurtosis_enclave_manager.LockUnlockPortRequest 13, // 25: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.AddAlias:input_type -> kurtosis_enclave_manager.AddAliasRequest - 22, // 26: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.IsNewKurtosisVersionAvailable:input_type -> google.protobuf.Empty - 22, // 27: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.UpgradeKurtosisVersion:input_type -> google.protobuf.Empty - 3, // 28: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.Check:output_type -> kurtosis_enclave_manager.HealthCheckResponse - 26, // 29: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetEnclaves:output_type -> engine_api.GetEnclavesResponse - 27, // 30: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetServices:output_type -> api_container_api.GetServicesResponse - 28, // 31: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetServiceLogs:output_type -> engine_api.GetServiceLogsResponse - 29, // 32: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.ListFilesArtifactNamesAndUuids:output_type -> api_container_api.ListFilesArtifactNamesAndUuidsResponse - 30, // 33: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.RunStarlarkPackage:output_type -> api_container_api.StarlarkRunResponseLine - 30, // 34: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.RunStarlarkScript:output_type -> api_container_api.StarlarkRunResponseLine - 31, // 35: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.CreateEnclave:output_type -> engine_api.CreateEnclaveResponse - 32, // 36: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.InspectFilesArtifactContents:output_type -> api_container_api.InspectFilesArtifactContentsResponse - 33, // 37: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.DownloadFilesArtifact:output_type -> api_container_api.StreamedDataChunk - 22, // 38: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.DestroyEnclave:output_type -> google.protobuf.Empty - 34, // 39: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetStarlarkRun:output_type -> api_container_api.GetStarlarkRunResponse - 35, // 40: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetStarlarkScriptPlanYaml:output_type -> api_container_api.PlanYaml - 35, // 41: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetStarlarkPackagePlanYaml:output_type -> api_container_api.PlanYaml - 22, // 42: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.CreateRepositoryWebhook:output_type -> google.protobuf.Empty - 36, // 43: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetCloudInstanceConfig:output_type -> kurtosis_cloud.GetCloudInstanceConfigResponse - 22, // 44: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.LockPort:output_type -> google.protobuf.Empty - 22, // 45: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.UnlockPort:output_type -> google.protobuf.Empty - 22, // 46: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.AddAlias:output_type -> google.protobuf.Empty - 37, // 47: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.IsNewKurtosisVersionAvailable:output_type -> kurtosis_cloud.IsNewKurtosisVersionAvailableResponse - 22, // 48: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.UpgradeKurtosisVersion:output_type -> google.protobuf.Empty - 28, // [28:49] is the sub-list for method output_type - 7, // [7:28] is the sub-list for method input_type + 23, // 26: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.IsNewKurtosisVersionAvailable:input_type -> google.protobuf.Empty + 23, // 27: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.UpgradeKurtosisVersion:input_type -> google.protobuf.Empty + 14, // 28: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.PublishPackageRepository:input_type -> kurtosis_enclave_manager.PublishPackageRequest + 3, // 29: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.Check:output_type -> kurtosis_enclave_manager.HealthCheckResponse + 27, // 30: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetEnclaves:output_type -> engine_api.GetEnclavesResponse + 28, // 31: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetServices:output_type -> api_container_api.GetServicesResponse + 29, // 32: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetServiceLogs:output_type -> engine_api.GetServiceLogsResponse + 30, // 33: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.ListFilesArtifactNamesAndUuids:output_type -> api_container_api.ListFilesArtifactNamesAndUuidsResponse + 31, // 34: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.RunStarlarkPackage:output_type -> api_container_api.StarlarkRunResponseLine + 31, // 35: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.RunStarlarkScript:output_type -> api_container_api.StarlarkRunResponseLine + 32, // 36: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.CreateEnclave:output_type -> engine_api.CreateEnclaveResponse + 33, // 37: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.InspectFilesArtifactContents:output_type -> api_container_api.InspectFilesArtifactContentsResponse + 34, // 38: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.DownloadFilesArtifact:output_type -> api_container_api.StreamedDataChunk + 23, // 39: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.DestroyEnclave:output_type -> google.protobuf.Empty + 35, // 40: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetStarlarkRun:output_type -> api_container_api.GetStarlarkRunResponse + 36, // 41: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetStarlarkScriptPlanYaml:output_type -> api_container_api.PlanYaml + 36, // 42: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetStarlarkPackagePlanYaml:output_type -> api_container_api.PlanYaml + 23, // 43: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.CreateRepositoryWebhook:output_type -> google.protobuf.Empty + 37, // 44: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.GetCloudInstanceConfig:output_type -> kurtosis_cloud.GetCloudInstanceConfigResponse + 23, // 45: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.LockPort:output_type -> google.protobuf.Empty + 23, // 46: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.UnlockPort:output_type -> google.protobuf.Empty + 23, // 47: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.AddAlias:output_type -> google.protobuf.Empty + 38, // 48: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.IsNewKurtosisVersionAvailable:output_type -> kurtosis_cloud.IsNewKurtosisVersionAvailableResponse + 23, // 49: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.UpgradeKurtosisVersion:output_type -> google.protobuf.Empty + 23, // 50: kurtosis_enclave_manager.KurtosisEnclaveManagerServer.PublishPackageRepository:output_type -> google.protobuf.Empty + 29, // [29:51] is the sub-list for method output_type + 7, // [7:29] is the sub-list for method input_type 7, // [7:7] is the sub-list for extension type_name 7, // [7:7] is the sub-list for extension extendee 0, // [0:7] is the sub-list for field type_name @@ -1538,7 +1631,7 @@ func file_kurtosis_enclave_manager_api_proto_init() { } } file_kurtosis_enclave_manager_api_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*StarlarkScriptPlanYamlArgs); i { + switch v := v.(*PublishPackageRequest); i { case 0: return &v.state case 1: @@ -1550,6 +1643,18 @@ func file_kurtosis_enclave_manager_api_proto_init() { } } file_kurtosis_enclave_manager_api_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*StarlarkScriptPlanYamlArgs); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_kurtosis_enclave_manager_api_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*StarlarkPackagePlanYamlArgs); i { case 0: return &v.state @@ -1568,7 +1673,7 @@ func file_kurtosis_enclave_manager_api_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_kurtosis_enclave_manager_api_proto_rawDesc, NumEnums: 1, - NumMessages: 15, + NumMessages: 16, NumExtensions: 0, NumServices: 1, }, diff --git a/enclave-manager/api/golang/kurtosis_enclave_manager_api_bindings/kurtosis_enclave_manager_api_bindingsconnect/kurtosis_enclave_manager_api.connect.go b/enclave-manager/api/golang/kurtosis_enclave_manager_api_bindings/kurtosis_enclave_manager_api_bindingsconnect/kurtosis_enclave_manager_api.connect.go index 01bd2c74d4..0a553fc5f0 100644 --- a/enclave-manager/api/golang/kurtosis_enclave_manager_api_bindings/kurtosis_enclave_manager_api_bindingsconnect/kurtosis_enclave_manager_api.connect.go +++ b/enclave-manager/api/golang/kurtosis_enclave_manager_api_bindings/kurtosis_enclave_manager_api_bindingsconnect/kurtosis_enclave_manager_api.connect.go @@ -101,6 +101,9 @@ const ( // KurtosisEnclaveManagerServerUpgradeKurtosisVersionProcedure is the fully-qualified name of the // KurtosisEnclaveManagerServer's UpgradeKurtosisVersion RPC. KurtosisEnclaveManagerServerUpgradeKurtosisVersionProcedure = "/kurtosis_enclave_manager.KurtosisEnclaveManagerServer/UpgradeKurtosisVersion" + // KurtosisEnclaveManagerServerPublishPackageRepositoryProcedure is the fully-qualified name of the + // KurtosisEnclaveManagerServer's PublishPackageRepository RPC. + KurtosisEnclaveManagerServerPublishPackageRepositoryProcedure = "/kurtosis_enclave_manager.KurtosisEnclaveManagerServer/PublishPackageRepository" ) // KurtosisEnclaveManagerServerClient is a client for the @@ -127,6 +130,7 @@ type KurtosisEnclaveManagerServerClient interface { AddAlias(context.Context, *connect.Request[kurtosis_enclave_manager_api_bindings.AddAliasRequest]) (*connect.Response[emptypb.Empty], error) IsNewKurtosisVersionAvailable(context.Context, *connect.Request[emptypb.Empty]) (*connect.Response[kurtosis_backend_server_rpc_api_bindings.IsNewKurtosisVersionAvailableResponse], error) UpgradeKurtosisVersion(context.Context, *connect.Request[emptypb.Empty]) (*connect.Response[emptypb.Empty], error) + PublishPackageRepository(context.Context, *connect.Request[kurtosis_enclave_manager_api_bindings.PublishPackageRequest]) (*connect.Response[emptypb.Empty], error) } // NewKurtosisEnclaveManagerServerClient constructs a client for the @@ -245,6 +249,11 @@ func NewKurtosisEnclaveManagerServerClient(httpClient connect.HTTPClient, baseUR baseURL+KurtosisEnclaveManagerServerUpgradeKurtosisVersionProcedure, opts..., ), + publishPackageRepository: connect.NewClient[kurtosis_enclave_manager_api_bindings.PublishPackageRequest, emptypb.Empty]( + httpClient, + baseURL+KurtosisEnclaveManagerServerPublishPackageRepositoryProcedure, + opts..., + ), } } @@ -271,6 +280,7 @@ type kurtosisEnclaveManagerServerClient struct { addAlias *connect.Client[kurtosis_enclave_manager_api_bindings.AddAliasRequest, emptypb.Empty] isNewKurtosisVersionAvailable *connect.Client[emptypb.Empty, kurtosis_backend_server_rpc_api_bindings.IsNewKurtosisVersionAvailableResponse] upgradeKurtosisVersion *connect.Client[emptypb.Empty, emptypb.Empty] + publishPackageRepository *connect.Client[kurtosis_enclave_manager_api_bindings.PublishPackageRequest, emptypb.Empty] } // Check calls kurtosis_enclave_manager.KurtosisEnclaveManagerServer.Check. @@ -388,6 +398,12 @@ func (c *kurtosisEnclaveManagerServerClient) UpgradeKurtosisVersion(ctx context. return c.upgradeKurtosisVersion.CallUnary(ctx, req) } +// PublishPackageRepository calls +// kurtosis_enclave_manager.KurtosisEnclaveManagerServer.PublishPackageRepository. +func (c *kurtosisEnclaveManagerServerClient) PublishPackageRepository(ctx context.Context, req *connect.Request[kurtosis_enclave_manager_api_bindings.PublishPackageRequest]) (*connect.Response[emptypb.Empty], error) { + return c.publishPackageRepository.CallUnary(ctx, req) +} + // KurtosisEnclaveManagerServerHandler is an implementation of the // kurtosis_enclave_manager.KurtosisEnclaveManagerServer service. type KurtosisEnclaveManagerServerHandler interface { @@ -412,6 +428,7 @@ type KurtosisEnclaveManagerServerHandler interface { AddAlias(context.Context, *connect.Request[kurtosis_enclave_manager_api_bindings.AddAliasRequest]) (*connect.Response[emptypb.Empty], error) IsNewKurtosisVersionAvailable(context.Context, *connect.Request[emptypb.Empty]) (*connect.Response[kurtosis_backend_server_rpc_api_bindings.IsNewKurtosisVersionAvailableResponse], error) UpgradeKurtosisVersion(context.Context, *connect.Request[emptypb.Empty]) (*connect.Response[emptypb.Empty], error) + PublishPackageRepository(context.Context, *connect.Request[kurtosis_enclave_manager_api_bindings.PublishPackageRequest]) (*connect.Response[emptypb.Empty], error) } // NewKurtosisEnclaveManagerServerHandler builds an HTTP handler from the service implementation. It @@ -525,6 +542,11 @@ func NewKurtosisEnclaveManagerServerHandler(svc KurtosisEnclaveManagerServerHand svc.UpgradeKurtosisVersion, opts..., ) + kurtosisEnclaveManagerServerPublishPackageRepositoryHandler := connect.NewUnaryHandler( + KurtosisEnclaveManagerServerPublishPackageRepositoryProcedure, + svc.PublishPackageRepository, + opts..., + ) return "/kurtosis_enclave_manager.KurtosisEnclaveManagerServer/", http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { switch r.URL.Path { case KurtosisEnclaveManagerServerCheckProcedure: @@ -569,6 +591,8 @@ func NewKurtosisEnclaveManagerServerHandler(svc KurtosisEnclaveManagerServerHand kurtosisEnclaveManagerServerIsNewKurtosisVersionAvailableHandler.ServeHTTP(w, r) case KurtosisEnclaveManagerServerUpgradeKurtosisVersionProcedure: kurtosisEnclaveManagerServerUpgradeKurtosisVersionHandler.ServeHTTP(w, r) + case KurtosisEnclaveManagerServerPublishPackageRepositoryProcedure: + kurtosisEnclaveManagerServerPublishPackageRepositoryHandler.ServeHTTP(w, r) default: http.NotFound(w, r) } @@ -661,3 +685,7 @@ func (UnimplementedKurtosisEnclaveManagerServerHandler) IsNewKurtosisVersionAvai func (UnimplementedKurtosisEnclaveManagerServerHandler) UpgradeKurtosisVersion(context.Context, *connect.Request[emptypb.Empty]) (*connect.Response[emptypb.Empty], error) { return nil, connect.NewError(connect.CodeUnimplemented, errors.New("kurtosis_enclave_manager.KurtosisEnclaveManagerServer.UpgradeKurtosisVersion is not implemented")) } + +func (UnimplementedKurtosisEnclaveManagerServerHandler) PublishPackageRepository(context.Context, *connect.Request[kurtosis_enclave_manager_api_bindings.PublishPackageRequest]) (*connect.Response[emptypb.Empty], error) { + return nil, connect.NewError(connect.CodeUnimplemented, errors.New("kurtosis_enclave_manager.KurtosisEnclaveManagerServer.PublishPackageRepository is not implemented")) +} diff --git a/enclave-manager/api/golang/kurtosis_enclave_manager_api_bindings/kurtosis_enclave_manager_api_grpc.pb.go b/enclave-manager/api/golang/kurtosis_enclave_manager_api_bindings/kurtosis_enclave_manager_api_grpc.pb.go index 097e8f6508..73b49148ac 100644 --- a/enclave-manager/api/golang/kurtosis_enclave_manager_api_bindings/kurtosis_enclave_manager_api_grpc.pb.go +++ b/enclave-manager/api/golang/kurtosis_enclave_manager_api_bindings/kurtosis_enclave_manager_api_grpc.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: // - protoc-gen-go-grpc v1.3.0 -// - protoc v4.24.4 +// - protoc v4.25.2 // source: kurtosis_enclave_manager_api.proto package kurtosis_enclave_manager_api_bindings @@ -44,6 +44,7 @@ const ( KurtosisEnclaveManagerServer_AddAlias_FullMethodName = "/kurtosis_enclave_manager.KurtosisEnclaveManagerServer/AddAlias" KurtosisEnclaveManagerServer_IsNewKurtosisVersionAvailable_FullMethodName = "/kurtosis_enclave_manager.KurtosisEnclaveManagerServer/IsNewKurtosisVersionAvailable" KurtosisEnclaveManagerServer_UpgradeKurtosisVersion_FullMethodName = "/kurtosis_enclave_manager.KurtosisEnclaveManagerServer/UpgradeKurtosisVersion" + KurtosisEnclaveManagerServer_PublishPackageRepository_FullMethodName = "/kurtosis_enclave_manager.KurtosisEnclaveManagerServer/PublishPackageRepository" ) // KurtosisEnclaveManagerServerClient is the client API for KurtosisEnclaveManagerServer service. @@ -71,6 +72,7 @@ type KurtosisEnclaveManagerServerClient interface { AddAlias(ctx context.Context, in *AddAliasRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) IsNewKurtosisVersionAvailable(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*kurtosis_backend_server_rpc_api_bindings.IsNewKurtosisVersionAvailableResponse, error) UpgradeKurtosisVersion(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*emptypb.Empty, error) + PublishPackageRepository(ctx context.Context, in *PublishPackageRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) } type kurtosisEnclaveManagerServerClient struct { @@ -362,6 +364,15 @@ func (c *kurtosisEnclaveManagerServerClient) UpgradeKurtosisVersion(ctx context. return out, nil } +func (c *kurtosisEnclaveManagerServerClient) PublishPackageRepository(ctx context.Context, in *PublishPackageRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { + out := new(emptypb.Empty) + err := c.cc.Invoke(ctx, KurtosisEnclaveManagerServer_PublishPackageRepository_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // KurtosisEnclaveManagerServerServer is the server API for KurtosisEnclaveManagerServer service. // All implementations should embed UnimplementedKurtosisEnclaveManagerServerServer // for forward compatibility @@ -387,6 +398,7 @@ type KurtosisEnclaveManagerServerServer interface { AddAlias(context.Context, *AddAliasRequest) (*emptypb.Empty, error) IsNewKurtosisVersionAvailable(context.Context, *emptypb.Empty) (*kurtosis_backend_server_rpc_api_bindings.IsNewKurtosisVersionAvailableResponse, error) UpgradeKurtosisVersion(context.Context, *emptypb.Empty) (*emptypb.Empty, error) + PublishPackageRepository(context.Context, *PublishPackageRequest) (*emptypb.Empty, error) } // UnimplementedKurtosisEnclaveManagerServerServer should be embedded to have forward compatible implementations. @@ -456,6 +468,9 @@ func (UnimplementedKurtosisEnclaveManagerServerServer) IsNewKurtosisVersionAvail func (UnimplementedKurtosisEnclaveManagerServerServer) UpgradeKurtosisVersion(context.Context, *emptypb.Empty) (*emptypb.Empty, error) { return nil, status.Errorf(codes.Unimplemented, "method UpgradeKurtosisVersion not implemented") } +func (UnimplementedKurtosisEnclaveManagerServerServer) PublishPackageRepository(context.Context, *PublishPackageRequest) (*emptypb.Empty, error) { + return nil, status.Errorf(codes.Unimplemented, "method PublishPackageRepository not implemented") +} // UnsafeKurtosisEnclaveManagerServerServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to KurtosisEnclaveManagerServerServer will @@ -858,6 +873,24 @@ func _KurtosisEnclaveManagerServer_UpgradeKurtosisVersion_Handler(srv interface{ return interceptor(ctx, in, info, handler) } +func _KurtosisEnclaveManagerServer_PublishPackageRepository_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(PublishPackageRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(KurtosisEnclaveManagerServerServer).PublishPackageRepository(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: KurtosisEnclaveManagerServer_PublishPackageRepository_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(KurtosisEnclaveManagerServerServer).PublishPackageRepository(ctx, req.(*PublishPackageRequest)) + } + return interceptor(ctx, in, info, handler) +} + // KurtosisEnclaveManagerServer_ServiceDesc is the grpc.ServiceDesc for KurtosisEnclaveManagerServer service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) @@ -933,6 +966,10 @@ var KurtosisEnclaveManagerServer_ServiceDesc = grpc.ServiceDesc{ MethodName: "UpgradeKurtosisVersion", Handler: _KurtosisEnclaveManagerServer_UpgradeKurtosisVersion_Handler, }, + { + MethodName: "PublishPackageRepository", + Handler: _KurtosisEnclaveManagerServer_PublishPackageRepository_Handler, + }, }, Streams: []grpc.StreamDesc{ { diff --git a/enclave-manager/api/protobuf/kurtosis_enclave_manager_api.proto b/enclave-manager/api/protobuf/kurtosis_enclave_manager_api.proto index 31c28b29c7..85bb0f461f 100644 --- a/enclave-manager/api/protobuf/kurtosis_enclave_manager_api.proto +++ b/enclave-manager/api/protobuf/kurtosis_enclave_manager_api.proto @@ -31,6 +31,7 @@ service KurtosisEnclaveManagerServer { rpc AddAlias(AddAliasRequest) returns(google.protobuf.Empty){} rpc IsNewKurtosisVersionAvailable(google.protobuf.Empty) returns(kurtosis_cloud.IsNewKurtosisVersionAvailableResponse){} rpc UpgradeKurtosisVersion(google.protobuf.Empty) returns(google.protobuf.Empty){}; + rpc PublishPackageRepository(PublishPackageRequest) returns(google.protobuf.Empty){}; } message GetCloudInstanceConfigRequest { @@ -109,6 +110,12 @@ message AddAliasRequest { string enclave_short_uuid=4; } +message PublishPackageRequest { + string authCode=1; + string packageName=2; + string serializedStarlarkScript=3; + optional string serializedPackageIcon=4; +} // ============================================================================================== // Get Starlark Plan Yaml diff --git a/enclave-manager/api/typescript/src/api_container_service_connect.d.ts b/enclave-manager/api/typescript/src/api_container_service_connect.d.ts new file mode 100644 index 0000000000..5f5713ba58 --- /dev/null +++ b/enclave-manager/api/typescript/src/api_container_service_connect.d.ts @@ -0,0 +1,211 @@ +// @generated by protoc-gen-connect-es v1.4.0 with parameter "target=js+dts" +// @generated from file api_container_service.proto (package api_container_api, syntax proto3) +/* eslint-disable */ +// @ts-nocheck + +import { ConnectServicesArgs, ConnectServicesResponse, DownloadFilesArtifactArgs, ExecCommandArgs, ExecCommandResponse, GetExistingAndHistoricalServiceIdentifiersResponse, GetServicesArgs, GetServicesResponse, GetStarlarkRunResponse, InspectFilesArtifactContentsRequest, InspectFilesArtifactContentsResponse, ListFilesArtifactNamesAndUuidsResponse, PlanYaml, RunStarlarkPackageArgs, RunStarlarkScriptArgs, StarlarkPackagePlanYamlArgs, StarlarkRunResponseLine, StarlarkScriptPlanYamlArgs, StoreFilesArtifactFromServiceArgs, StoreFilesArtifactFromServiceResponse, StoreWebFilesArtifactArgs, StoreWebFilesArtifactResponse, StreamedDataChunk, UploadFilesArtifactResponse, WaitForHttpGetEndpointAvailabilityArgs, WaitForHttpPostEndpointAvailabilityArgs } from "./api_container_service_pb.js"; +import { Empty, MethodKind } from "@bufbuild/protobuf"; + +/** + * @generated from service api_container_api.ApiContainerService + */ +export declare const ApiContainerService: { + readonly typeName: "api_container_api.ApiContainerService", + readonly methods: { + /** + * Executes a Starlark script on the user's behalf + * + * @generated from rpc api_container_api.ApiContainerService.RunStarlarkScript + */ + readonly runStarlarkScript: { + readonly name: "RunStarlarkScript", + readonly I: typeof RunStarlarkScriptArgs, + readonly O: typeof StarlarkRunResponseLine, + readonly kind: MethodKind.ServerStreaming, + }, + /** + * Uploads a Starlark package. This step is required before the package can be executed with RunStarlarkPackage + * + * @generated from rpc api_container_api.ApiContainerService.UploadStarlarkPackage + */ + readonly uploadStarlarkPackage: { + readonly name: "UploadStarlarkPackage", + readonly I: typeof StreamedDataChunk, + readonly O: typeof Empty, + readonly kind: MethodKind.ClientStreaming, + }, + /** + * Executes a Starlark script on the user's behalf + * + * @generated from rpc api_container_api.ApiContainerService.RunStarlarkPackage + */ + readonly runStarlarkPackage: { + readonly name: "RunStarlarkPackage", + readonly I: typeof RunStarlarkPackageArgs, + readonly O: typeof StarlarkRunResponseLine, + readonly kind: MethodKind.ServerStreaming, + }, + /** + * Returns the IDs of the current services in the enclave + * + * @generated from rpc api_container_api.ApiContainerService.GetServices + */ + readonly getServices: { + readonly name: "GetServices", + readonly I: typeof GetServicesArgs, + readonly O: typeof GetServicesResponse, + readonly kind: MethodKind.Unary, + }, + /** + * Returns information about all existing & historical services + * + * @generated from rpc api_container_api.ApiContainerService.GetExistingAndHistoricalServiceIdentifiers + */ + readonly getExistingAndHistoricalServiceIdentifiers: { + readonly name: "GetExistingAndHistoricalServiceIdentifiers", + readonly I: typeof Empty, + readonly O: typeof GetExistingAndHistoricalServiceIdentifiersResponse, + readonly kind: MethodKind.Unary, + }, + /** + * Executes the given command inside a running container + * + * @generated from rpc api_container_api.ApiContainerService.ExecCommand + */ + readonly execCommand: { + readonly name: "ExecCommand", + readonly I: typeof ExecCommandArgs, + readonly O: typeof ExecCommandResponse, + readonly kind: MethodKind.Unary, + }, + /** + * Block until the given HTTP endpoint returns available, calling it through a HTTP Get request + * + * @generated from rpc api_container_api.ApiContainerService.WaitForHttpGetEndpointAvailability + */ + readonly waitForHttpGetEndpointAvailability: { + readonly name: "WaitForHttpGetEndpointAvailability", + readonly I: typeof WaitForHttpGetEndpointAvailabilityArgs, + readonly O: typeof Empty, + readonly kind: MethodKind.Unary, + }, + /** + * Block until the given HTTP endpoint returns available, calling it through a HTTP Post request + * + * @generated from rpc api_container_api.ApiContainerService.WaitForHttpPostEndpointAvailability + */ + readonly waitForHttpPostEndpointAvailability: { + readonly name: "WaitForHttpPostEndpointAvailability", + readonly I: typeof WaitForHttpPostEndpointAvailabilityArgs, + readonly O: typeof Empty, + readonly kind: MethodKind.Unary, + }, + /** + * Uploads a files artifact to the Kurtosis File System + * + * @generated from rpc api_container_api.ApiContainerService.UploadFilesArtifact + */ + readonly uploadFilesArtifact: { + readonly name: "UploadFilesArtifact", + readonly I: typeof StreamedDataChunk, + readonly O: typeof UploadFilesArtifactResponse, + readonly kind: MethodKind.ClientStreaming, + }, + /** + * Downloads a files artifact from the Kurtosis File System + * + * @generated from rpc api_container_api.ApiContainerService.DownloadFilesArtifact + */ + readonly downloadFilesArtifact: { + readonly name: "DownloadFilesArtifact", + readonly I: typeof DownloadFilesArtifactArgs, + readonly O: typeof StreamedDataChunk, + readonly kind: MethodKind.ServerStreaming, + }, + /** + * Tells the API container to download a files artifact from the web to the Kurtosis File System + * + * @generated from rpc api_container_api.ApiContainerService.StoreWebFilesArtifact + */ + readonly storeWebFilesArtifact: { + readonly name: "StoreWebFilesArtifact", + readonly I: typeof StoreWebFilesArtifactArgs, + readonly O: typeof StoreWebFilesArtifactResponse, + readonly kind: MethodKind.Unary, + }, + /** + * Tells the API container to copy a files artifact from a service to the Kurtosis File System + * + * @generated from rpc api_container_api.ApiContainerService.StoreFilesArtifactFromService + */ + readonly storeFilesArtifactFromService: { + readonly name: "StoreFilesArtifactFromService", + readonly I: typeof StoreFilesArtifactFromServiceArgs, + readonly O: typeof StoreFilesArtifactFromServiceResponse, + readonly kind: MethodKind.Unary, + }, + /** + * @generated from rpc api_container_api.ApiContainerService.ListFilesArtifactNamesAndUuids + */ + readonly listFilesArtifactNamesAndUuids: { + readonly name: "ListFilesArtifactNamesAndUuids", + readonly I: typeof Empty, + readonly O: typeof ListFilesArtifactNamesAndUuidsResponse, + readonly kind: MethodKind.Unary, + }, + /** + * @generated from rpc api_container_api.ApiContainerService.InspectFilesArtifactContents + */ + readonly inspectFilesArtifactContents: { + readonly name: "InspectFilesArtifactContents", + readonly I: typeof InspectFilesArtifactContentsRequest, + readonly O: typeof InspectFilesArtifactContentsResponse, + readonly kind: MethodKind.Unary, + }, + /** + * User services port forwarding + * + * @generated from rpc api_container_api.ApiContainerService.ConnectServices + */ + readonly connectServices: { + readonly name: "ConnectServices", + readonly I: typeof ConnectServicesArgs, + readonly O: typeof ConnectServicesResponse, + readonly kind: MethodKind.Unary, + }, + /** + * Get last Starlark run + * + * @generated from rpc api_container_api.ApiContainerService.GetStarlarkRun + */ + readonly getStarlarkRun: { + readonly name: "GetStarlarkRun", + readonly I: typeof Empty, + readonly O: typeof GetStarlarkRunResponse, + readonly kind: MethodKind.Unary, + }, + /** + * Gets yaml representing the plan the script will execute in an enclave + * + * @generated from rpc api_container_api.ApiContainerService.GetStarlarkScriptPlanYaml + */ + readonly getStarlarkScriptPlanYaml: { + readonly name: "GetStarlarkScriptPlanYaml", + readonly I: typeof StarlarkScriptPlanYamlArgs, + readonly O: typeof PlanYaml, + readonly kind: MethodKind.Unary, + }, + /** + * Gets yaml representing the plan the package will execute in an enclave + * + * @generated from rpc api_container_api.ApiContainerService.GetStarlarkPackagePlanYaml + */ + readonly getStarlarkPackagePlanYaml: { + readonly name: "GetStarlarkPackagePlanYaml", + readonly I: typeof StarlarkPackagePlanYamlArgs, + readonly O: typeof PlanYaml, + readonly kind: MethodKind.Unary, + }, + } +}; + diff --git a/enclave-manager/api/typescript/src/api_container_service_connect.js b/enclave-manager/api/typescript/src/api_container_service_connect.js new file mode 100644 index 0000000000..efba43715c --- /dev/null +++ b/enclave-manager/api/typescript/src/api_container_service_connect.js @@ -0,0 +1,211 @@ +// @generated by protoc-gen-connect-es v1.4.0 with parameter "target=js+dts" +// @generated from file api_container_service.proto (package api_container_api, syntax proto3) +/* eslint-disable */ +// @ts-nocheck + +import { ConnectServicesArgs, ConnectServicesResponse, DownloadFilesArtifactArgs, ExecCommandArgs, ExecCommandResponse, GetExistingAndHistoricalServiceIdentifiersResponse, GetServicesArgs, GetServicesResponse, GetStarlarkRunResponse, InspectFilesArtifactContentsRequest, InspectFilesArtifactContentsResponse, ListFilesArtifactNamesAndUuidsResponse, PlanYaml, RunStarlarkPackageArgs, RunStarlarkScriptArgs, StarlarkPackagePlanYamlArgs, StarlarkRunResponseLine, StarlarkScriptPlanYamlArgs, StoreFilesArtifactFromServiceArgs, StoreFilesArtifactFromServiceResponse, StoreWebFilesArtifactArgs, StoreWebFilesArtifactResponse, StreamedDataChunk, UploadFilesArtifactResponse, WaitForHttpGetEndpointAvailabilityArgs, WaitForHttpPostEndpointAvailabilityArgs } from "./api_container_service_pb.js"; +import { Empty, MethodKind } from "@bufbuild/protobuf"; + +/** + * @generated from service api_container_api.ApiContainerService + */ +export const ApiContainerService = { + typeName: "api_container_api.ApiContainerService", + methods: { + /** + * Executes a Starlark script on the user's behalf + * + * @generated from rpc api_container_api.ApiContainerService.RunStarlarkScript + */ + runStarlarkScript: { + name: "RunStarlarkScript", + I: RunStarlarkScriptArgs, + O: StarlarkRunResponseLine, + kind: MethodKind.ServerStreaming, + }, + /** + * Uploads a Starlark package. This step is required before the package can be executed with RunStarlarkPackage + * + * @generated from rpc api_container_api.ApiContainerService.UploadStarlarkPackage + */ + uploadStarlarkPackage: { + name: "UploadStarlarkPackage", + I: StreamedDataChunk, + O: Empty, + kind: MethodKind.ClientStreaming, + }, + /** + * Executes a Starlark script on the user's behalf + * + * @generated from rpc api_container_api.ApiContainerService.RunStarlarkPackage + */ + runStarlarkPackage: { + name: "RunStarlarkPackage", + I: RunStarlarkPackageArgs, + O: StarlarkRunResponseLine, + kind: MethodKind.ServerStreaming, + }, + /** + * Returns the IDs of the current services in the enclave + * + * @generated from rpc api_container_api.ApiContainerService.GetServices + */ + getServices: { + name: "GetServices", + I: GetServicesArgs, + O: GetServicesResponse, + kind: MethodKind.Unary, + }, + /** + * Returns information about all existing & historical services + * + * @generated from rpc api_container_api.ApiContainerService.GetExistingAndHistoricalServiceIdentifiers + */ + getExistingAndHistoricalServiceIdentifiers: { + name: "GetExistingAndHistoricalServiceIdentifiers", + I: Empty, + O: GetExistingAndHistoricalServiceIdentifiersResponse, + kind: MethodKind.Unary, + }, + /** + * Executes the given command inside a running container + * + * @generated from rpc api_container_api.ApiContainerService.ExecCommand + */ + execCommand: { + name: "ExecCommand", + I: ExecCommandArgs, + O: ExecCommandResponse, + kind: MethodKind.Unary, + }, + /** + * Block until the given HTTP endpoint returns available, calling it through a HTTP Get request + * + * @generated from rpc api_container_api.ApiContainerService.WaitForHttpGetEndpointAvailability + */ + waitForHttpGetEndpointAvailability: { + name: "WaitForHttpGetEndpointAvailability", + I: WaitForHttpGetEndpointAvailabilityArgs, + O: Empty, + kind: MethodKind.Unary, + }, + /** + * Block until the given HTTP endpoint returns available, calling it through a HTTP Post request + * + * @generated from rpc api_container_api.ApiContainerService.WaitForHttpPostEndpointAvailability + */ + waitForHttpPostEndpointAvailability: { + name: "WaitForHttpPostEndpointAvailability", + I: WaitForHttpPostEndpointAvailabilityArgs, + O: Empty, + kind: MethodKind.Unary, + }, + /** + * Uploads a files artifact to the Kurtosis File System + * + * @generated from rpc api_container_api.ApiContainerService.UploadFilesArtifact + */ + uploadFilesArtifact: { + name: "UploadFilesArtifact", + I: StreamedDataChunk, + O: UploadFilesArtifactResponse, + kind: MethodKind.ClientStreaming, + }, + /** + * Downloads a files artifact from the Kurtosis File System + * + * @generated from rpc api_container_api.ApiContainerService.DownloadFilesArtifact + */ + downloadFilesArtifact: { + name: "DownloadFilesArtifact", + I: DownloadFilesArtifactArgs, + O: StreamedDataChunk, + kind: MethodKind.ServerStreaming, + }, + /** + * Tells the API container to download a files artifact from the web to the Kurtosis File System + * + * @generated from rpc api_container_api.ApiContainerService.StoreWebFilesArtifact + */ + storeWebFilesArtifact: { + name: "StoreWebFilesArtifact", + I: StoreWebFilesArtifactArgs, + O: StoreWebFilesArtifactResponse, + kind: MethodKind.Unary, + }, + /** + * Tells the API container to copy a files artifact from a service to the Kurtosis File System + * + * @generated from rpc api_container_api.ApiContainerService.StoreFilesArtifactFromService + */ + storeFilesArtifactFromService: { + name: "StoreFilesArtifactFromService", + I: StoreFilesArtifactFromServiceArgs, + O: StoreFilesArtifactFromServiceResponse, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc api_container_api.ApiContainerService.ListFilesArtifactNamesAndUuids + */ + listFilesArtifactNamesAndUuids: { + name: "ListFilesArtifactNamesAndUuids", + I: Empty, + O: ListFilesArtifactNamesAndUuidsResponse, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc api_container_api.ApiContainerService.InspectFilesArtifactContents + */ + inspectFilesArtifactContents: { + name: "InspectFilesArtifactContents", + I: InspectFilesArtifactContentsRequest, + O: InspectFilesArtifactContentsResponse, + kind: MethodKind.Unary, + }, + /** + * User services port forwarding + * + * @generated from rpc api_container_api.ApiContainerService.ConnectServices + */ + connectServices: { + name: "ConnectServices", + I: ConnectServicesArgs, + O: ConnectServicesResponse, + kind: MethodKind.Unary, + }, + /** + * Get last Starlark run + * + * @generated from rpc api_container_api.ApiContainerService.GetStarlarkRun + */ + getStarlarkRun: { + name: "GetStarlarkRun", + I: Empty, + O: GetStarlarkRunResponse, + kind: MethodKind.Unary, + }, + /** + * Gets yaml representing the plan the script will execute in an enclave + * + * @generated from rpc api_container_api.ApiContainerService.GetStarlarkScriptPlanYaml + */ + getStarlarkScriptPlanYaml: { + name: "GetStarlarkScriptPlanYaml", + I: StarlarkScriptPlanYamlArgs, + O: PlanYaml, + kind: MethodKind.Unary, + }, + /** + * Gets yaml representing the plan the package will execute in an enclave + * + * @generated from rpc api_container_api.ApiContainerService.GetStarlarkPackagePlanYaml + */ + getStarlarkPackagePlanYaml: { + name: "GetStarlarkPackagePlanYaml", + I: StarlarkPackagePlanYamlArgs, + O: PlanYaml, + kind: MethodKind.Unary, + }, + } +}; + diff --git a/enclave-manager/api/typescript/src/api_container_service_pb.d.ts b/enclave-manager/api/typescript/src/api_container_service_pb.d.ts new file mode 100644 index 0000000000..de9778ca61 --- /dev/null +++ b/enclave-manager/api/typescript/src/api_container_service_pb.d.ts @@ -0,0 +1,1945 @@ +// @generated by protoc-gen-es v1.3.1 with parameter "target=js+dts" +// @generated from file api_container_service.proto (package api_container_api, syntax proto3) +/* eslint-disable */ +// @ts-nocheck + +import type { BinaryReadOptions, FieldList, JsonReadOptions, JsonValue, PartialMessage, PlainMessage } from "@bufbuild/protobuf"; +import { Message, proto3 } from "@bufbuild/protobuf"; + +/** + * @generated from enum api_container_api.ServiceStatus + */ +export declare enum ServiceStatus { + /** + * @generated from enum value: STOPPED = 0; + */ + STOPPED = 0, + + /** + * @generated from enum value: RUNNING = 1; + */ + RUNNING = 1, + + /** + * @generated from enum value: UNKNOWN = 2; + */ + UNKNOWN = 2, +} + +/** + * @generated from enum api_container_api.ImageDownloadMode + */ +export declare enum ImageDownloadMode { + /** + * @generated from enum value: always = 0; + */ + always = 0, + + /** + * @generated from enum value: missing = 1; + */ + missing = 1, +} + +/** + * User services port forwarding + * + * @generated from enum api_container_api.Connect + */ +export declare enum Connect { + /** + * Best effort port forwarding + * + * @generated from enum value: CONNECT = 0; + */ + CONNECT = 0, + + /** + * Port forwarding disabled + * + * Starlark run fails if the ports cannot be forwarded. + * MUST_CONNECT = 2; + * + * @generated from enum value: NO_CONNECT = 1; + */ + NO_CONNECT = 1, +} + +/** + * @generated from enum api_container_api.KurtosisFeatureFlag + */ +export declare enum KurtosisFeatureFlag { + /** + * @generated from enum value: NO_INSTRUCTIONS_CACHING = 0; + */ + NO_INSTRUCTIONS_CACHING = 0, +} + +/** + * @generated from enum api_container_api.RestartPolicy + */ +export declare enum RestartPolicy { + /** + * @generated from enum value: NEVER = 0; + */ + NEVER = 0, + + /** + * @generated from enum value: ALWAYS = 1; + */ + ALWAYS = 1, +} + +/** + * ============================================================================================== + * Shared Objects (Used By Multiple Endpoints) + * ============================================================================================== + * + * @generated from message api_container_api.Port + */ +export declare class Port extends Message { + /** + * @generated from field: uint32 number = 1; + */ + number: number; + + /** + * The protocol that the port is listening on + * + * @generated from field: api_container_api.Port.TransportProtocol transport_protocol = 2; + */ + transportProtocol: Port_TransportProtocol; + + /** + * @generated from field: string maybe_application_protocol = 3; + */ + maybeApplicationProtocol: string; + + /** + * The wait timeout duration in string + * + * @generated from field: string maybe_wait_timeout = 4; + */ + maybeWaitTimeout: string; + + /** + * this is useful in the cloud context; ignore in local + * + * @generated from field: optional bool locked = 5; + */ + locked?: boolean; + + /** + * this is useful in the cloud context; ignore in local + * + * @generated from field: optional string alias = 6; + */ + alias?: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.Port"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): Port; + + static fromJson(jsonValue: JsonValue, options?: Partial): Port; + + static fromJsonString(jsonString: string, options?: Partial): Port; + + static equals(a: Port | PlainMessage | undefined, b: Port | PlainMessage | undefined): boolean; +} + +/** + * @generated from enum api_container_api.Port.TransportProtocol + */ +export declare enum Port_TransportProtocol { + /** + * @generated from enum value: TCP = 0; + */ + TCP = 0, + + /** + * @generated from enum value: SCTP = 1; + */ + SCTP = 1, + + /** + * @generated from enum value: UDP = 2; + */ + UDP = 2, +} + +/** + * @generated from message api_container_api.Container + */ +export declare class Container extends Message { + /** + * @generated from field: api_container_api.Container.Status status = 1; + */ + status: Container_Status; + + /** + * @generated from field: string image_name = 2; + */ + imageName: string; + + /** + * @generated from field: repeated string entrypoint_args = 3; + */ + entrypointArgs: string[]; + + /** + * @generated from field: repeated string cmd_args = 4; + */ + cmdArgs: string[]; + + /** + * @generated from field: map env_vars = 5; + */ + envVars: { [key: string]: string }; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.Container"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): Container; + + static fromJson(jsonValue: JsonValue, options?: Partial): Container; + + static fromJsonString(jsonString: string, options?: Partial): Container; + + static equals(a: Container | PlainMessage | undefined, b: Container | PlainMessage | undefined): boolean; +} + +/** + * @generated from enum api_container_api.Container.Status + */ +export declare enum Container_Status { + /** + * @generated from enum value: STOPPED = 0; + */ + STOPPED = 0, + + /** + * @generated from enum value: RUNNING = 1; + */ + RUNNING = 1, + + /** + * @generated from enum value: UNKNOWN = 2; + */ + UNKNOWN = 2, +} + +/** + * @generated from message api_container_api.ServiceInfo + */ +export declare class ServiceInfo extends Message { + /** + * UUID of the service + * + * @generated from field: string service_uuid = 1; + */ + serviceUuid: string; + + /** + * The IP address of the service inside the enclave + * + * @generated from field: string private_ip_addr = 2; + */ + privateIpAddr: string; + + /** + * The ports on which the service is reachable inside the enclave, specified in user_specified_port_id -> port_info + * Will be exactly what was passed in at the time of starting the service + * + * @generated from field: map private_ports = 3; + */ + privatePorts: { [key: string]: Port }; + + /** + * Public IP address *outside* the enclave where the service is reachable + * NOTE: Will be empty if the service isn't running, the service didn't define any ports, or the backend doesn't support reporting public service info + * + * @generated from field: string maybe_public_ip_addr = 4; + */ + maybePublicIpAddr: string; + + /** + * Mapping defining the ports that the service can be reached at *outside* the enclave, in the user_defined_port_id -> port_info where user_defined_port_id + * corresponds to the ID that was passed in in AddServiceArgs + * NOTE: Will be empty if the service isn't running, the service didn't define any ports, or the backend doesn't support reporting public service info + * + * @generated from field: map maybe_public_ports = 5; + */ + maybePublicPorts: { [key: string]: Port }; + + /** + * Name of the service + * + * @generated from field: string name = 6; + */ + name: string; + + /** + * Shortened uuid of the service + * + * @generated from field: string shortened_uuid = 7; + */ + shortenedUuid: string; + + /** + * Service status: stopped, running. + * + * @generated from field: api_container_api.ServiceStatus service_status = 8; + */ + serviceStatus: ServiceStatus; + + /** + * Docker container or Kubernetes pod container + * + * @generated from field: api_container_api.Container container = 9; + */ + container?: Container; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.ServiceInfo"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): ServiceInfo; + + static fromJson(jsonValue: JsonValue, options?: Partial): ServiceInfo; + + static fromJsonString(jsonString: string, options?: Partial): ServiceInfo; + + static equals(a: ServiceInfo | PlainMessage | undefined, b: ServiceInfo | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.RunStarlarkScriptArgs + */ +export declare class RunStarlarkScriptArgs extends Message { + /** + * @generated from field: string serialized_script = 1; + */ + serializedScript: string; + + /** + * @generated from field: optional string serialized_params = 2; + */ + serializedParams?: string; + + /** + * Defaults to false + * + * @generated from field: optional bool dry_run = 3; + */ + dryRun?: boolean; + + /** + * Defaults to 4 + * + * @generated from field: optional int32 parallelism = 4; + */ + parallelism?: number; + + /** + * The name of the main function, the default value is "run" + * + * @generated from field: optional string main_function_name = 5; + */ + mainFunctionName?: string; + + /** + * @generated from field: repeated api_container_api.KurtosisFeatureFlag experimental_features = 6; + */ + experimentalFeatures: KurtosisFeatureFlag[]; + + /** + * Defaults to empty + * + * @generated from field: optional string cloud_instance_id = 7; + */ + cloudInstanceId?: string; + + /** + * Defaults to empty + * + * @generated from field: optional string cloud_user_id = 8; + */ + cloudUserId?: string; + + /** + * Defaults to empty + * + * @generated from field: optional api_container_api.ImageDownloadMode image_download_mode = 9; + */ + imageDownloadMode?: ImageDownloadMode; + + /** + * Defaults to false + * + * @generated from field: optional bool non_blocking_mode = 10; + */ + nonBlockingMode?: boolean; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.RunStarlarkScriptArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): RunStarlarkScriptArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): RunStarlarkScriptArgs; + + static fromJsonString(jsonString: string, options?: Partial): RunStarlarkScriptArgs; + + static equals(a: RunStarlarkScriptArgs | PlainMessage | undefined, b: RunStarlarkScriptArgs | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.RunStarlarkPackageArgs + */ +export declare class RunStarlarkPackageArgs extends Message { + /** + * @generated from field: string package_id = 1; + */ + packageId: string; + + /** + * Deprecated: If the package is local, it should have been uploaded with UploadStarlarkPackage prior to calling + * RunStarlarkPackage. If the package is remote and must be cloned within the APIC, use the standalone boolean flag + * clone_package below + * + * @generated from oneof api_container_api.RunStarlarkPackageArgs.starlark_package_content + */ + starlarkPackageContent: { + /** + * the payload of the local module + * + * @generated from field: bytes local = 3; + */ + value: Uint8Array; + case: "local"; + } | { + /** + * just a flag to indicate the module must be cloned inside the API + * + * @generated from field: bool remote = 4; + */ + value: boolean; + case: "remote"; + } | { case: undefined; value?: undefined }; + + /** + * Serialized parameters data for the Starlark package main function + * This should be a valid JSON string + * + * @generated from field: optional string serialized_params = 5; + */ + serializedParams?: string; + + /** + * Defaults to false + * + * @generated from field: optional bool dry_run = 6; + */ + dryRun?: boolean; + + /** + * Defaults to 4 + * + * @generated from field: optional int32 parallelism = 7; + */ + parallelism?: number; + + /** + * Whether the package should be cloned or not. + * If false, then the package will be pulled from the APIC local package store. If it's a local package then is must + * have been uploaded using UploadStarlarkPackage prior to calling RunStarlarkPackage. + * If true, then the package will be cloned from GitHub before execution starts + * + * @generated from field: optional bool clone_package = 8; + */ + clonePackage?: boolean; + + /** + * The relative main file filepath, the default value is the "main.star" file in the root of a package + * + * @generated from field: optional string relative_path_to_main_file = 9; + */ + relativePathToMainFile?: string; + + /** + * The name of the main function, the default value is "run" + * + * @generated from field: optional string main_function_name = 10; + */ + mainFunctionName?: string; + + /** + * @generated from field: repeated api_container_api.KurtosisFeatureFlag experimental_features = 11; + */ + experimentalFeatures: KurtosisFeatureFlag[]; + + /** + * Defaults to empty + * Deprecated: This value isn't used in the APIC anymore + * + * @generated from field: optional string cloud_instance_id = 12; + */ + cloudInstanceId?: string; + + /** + * Defaults to empty + * Deprecated: This value isn't used in the APIC anymore + * + * @generated from field: optional string cloud_user_id = 13; + */ + cloudUserId?: string; + + /** + * Defaults to empty + * + * @generated from field: optional api_container_api.ImageDownloadMode image_download_mode = 14; + */ + imageDownloadMode?: ImageDownloadMode; + + /** + * Defaults to false + * + * @generated from field: optional bool non_blocking_mode = 15; + */ + nonBlockingMode?: boolean; + + /** + * token that will be used to authenticate requests for this package + * + * @generated from field: optional string github_auth_token = 16; + */ + githubAuthToken?: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.RunStarlarkPackageArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): RunStarlarkPackageArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): RunStarlarkPackageArgs; + + static fromJsonString(jsonString: string, options?: Partial): RunStarlarkPackageArgs; + + static equals(a: RunStarlarkPackageArgs | PlainMessage | undefined, b: RunStarlarkPackageArgs | PlainMessage | undefined): boolean; +} + +/** + * ============================================================================================== + * Starlark Execution Response + * ============================================================================================== + * + * @generated from message api_container_api.StarlarkRunResponseLine + */ +export declare class StarlarkRunResponseLine extends Message { + /** + * @generated from oneof api_container_api.StarlarkRunResponseLine.run_response_line + */ + runResponseLine: { + /** + * @generated from field: api_container_api.StarlarkInstruction instruction = 1; + */ + value: StarlarkInstruction; + case: "instruction"; + } | { + /** + * @generated from field: api_container_api.StarlarkError error = 2; + */ + value: StarlarkError; + case: "error"; + } | { + /** + * @generated from field: api_container_api.StarlarkRunProgress progress_info = 3; + */ + value: StarlarkRunProgress; + case: "progressInfo"; + } | { + /** + * @generated from field: api_container_api.StarlarkInstructionResult instruction_result = 4; + */ + value: StarlarkInstructionResult; + case: "instructionResult"; + } | { + /** + * @generated from field: api_container_api.StarlarkRunFinishedEvent run_finished_event = 5; + */ + value: StarlarkRunFinishedEvent; + case: "runFinishedEvent"; + } | { + /** + * @generated from field: api_container_api.StarlarkWarning warning = 6; + */ + value: StarlarkWarning; + case: "warning"; + } | { + /** + * @generated from field: api_container_api.StarlarkInfo info = 7; + */ + value: StarlarkInfo; + case: "info"; + } | { case: undefined; value?: undefined }; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkRunResponseLine"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkRunResponseLine; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkRunResponseLine; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkRunResponseLine; + + static equals(a: StarlarkRunResponseLine | PlainMessage | undefined, b: StarlarkRunResponseLine | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StarlarkInfo + */ +export declare class StarlarkInfo extends Message { + /** + * @generated from field: string info_message = 1; + */ + infoMessage: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkInfo"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkInfo; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkInfo; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkInfo; + + static equals(a: StarlarkInfo | PlainMessage | undefined, b: StarlarkInfo | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StarlarkWarning + */ +export declare class StarlarkWarning extends Message { + /** + * @generated from field: string warning_message = 1; + */ + warningMessage: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkWarning"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkWarning; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkWarning; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkWarning; + + static equals(a: StarlarkWarning | PlainMessage | undefined, b: StarlarkWarning | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StarlarkInstruction + */ +export declare class StarlarkInstruction extends Message { + /** + * @generated from field: api_container_api.StarlarkInstructionPosition position = 1; + */ + position?: StarlarkInstructionPosition; + + /** + * @generated from field: string instruction_name = 2; + */ + instructionName: string; + + /** + * @generated from field: repeated api_container_api.StarlarkInstructionArg arguments = 3; + */ + arguments: StarlarkInstructionArg[]; + + /** + * @generated from field: string executable_instruction = 4; + */ + executableInstruction: string; + + /** + * @generated from field: bool is_skipped = 5; + */ + isSkipped: boolean; + + /** + * @generated from field: string description = 6; + */ + description: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkInstruction"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkInstruction; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkInstruction; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkInstruction; + + static equals(a: StarlarkInstruction | PlainMessage | undefined, b: StarlarkInstruction | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StarlarkInstructionResult + */ +export declare class StarlarkInstructionResult extends Message { + /** + * @generated from field: string serialized_instruction_result = 1; + */ + serializedInstructionResult: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkInstructionResult"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkInstructionResult; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkInstructionResult; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkInstructionResult; + + static equals(a: StarlarkInstructionResult | PlainMessage | undefined, b: StarlarkInstructionResult | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StarlarkInstructionArg + */ +export declare class StarlarkInstructionArg extends Message { + /** + * @generated from field: string serialized_arg_value = 1; + */ + serializedArgValue: string; + + /** + * @generated from field: optional string arg_name = 2; + */ + argName?: string; + + /** + * @generated from field: bool is_representative = 3; + */ + isRepresentative: boolean; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkInstructionArg"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkInstructionArg; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkInstructionArg; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkInstructionArg; + + static equals(a: StarlarkInstructionArg | PlainMessage | undefined, b: StarlarkInstructionArg | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StarlarkInstructionPosition + */ +export declare class StarlarkInstructionPosition extends Message { + /** + * @generated from field: string filename = 1; + */ + filename: string; + + /** + * @generated from field: int32 line = 2; + */ + line: number; + + /** + * @generated from field: int32 column = 3; + */ + column: number; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkInstructionPosition"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkInstructionPosition; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkInstructionPosition; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkInstructionPosition; + + static equals(a: StarlarkInstructionPosition | PlainMessage | undefined, b: StarlarkInstructionPosition | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StarlarkError + */ +export declare class StarlarkError extends Message { + /** + * @generated from oneof api_container_api.StarlarkError.error + */ + error: { + /** + * @generated from field: api_container_api.StarlarkInterpretationError interpretation_error = 1; + */ + value: StarlarkInterpretationError; + case: "interpretationError"; + } | { + /** + * @generated from field: api_container_api.StarlarkValidationError validation_error = 2; + */ + value: StarlarkValidationError; + case: "validationError"; + } | { + /** + * @generated from field: api_container_api.StarlarkExecutionError execution_error = 3; + */ + value: StarlarkExecutionError; + case: "executionError"; + } | { case: undefined; value?: undefined }; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkError"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkError; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkError; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkError; + + static equals(a: StarlarkError | PlainMessage | undefined, b: StarlarkError | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StarlarkInterpretationError + */ +export declare class StarlarkInterpretationError extends Message { + /** + * @generated from field: string error_message = 1; + */ + errorMessage: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkInterpretationError"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkInterpretationError; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkInterpretationError; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkInterpretationError; + + static equals(a: StarlarkInterpretationError | PlainMessage | undefined, b: StarlarkInterpretationError | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StarlarkValidationError + */ +export declare class StarlarkValidationError extends Message { + /** + * @generated from field: string error_message = 1; + */ + errorMessage: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkValidationError"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkValidationError; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkValidationError; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkValidationError; + + static equals(a: StarlarkValidationError | PlainMessage | undefined, b: StarlarkValidationError | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StarlarkExecutionError + */ +export declare class StarlarkExecutionError extends Message { + /** + * @generated from field: string error_message = 1; + */ + errorMessage: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkExecutionError"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkExecutionError; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkExecutionError; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkExecutionError; + + static equals(a: StarlarkExecutionError | PlainMessage | undefined, b: StarlarkExecutionError | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StarlarkRunProgress + */ +export declare class StarlarkRunProgress extends Message { + /** + * @generated from field: repeated string current_step_info = 1; + */ + currentStepInfo: string[]; + + /** + * @generated from field: uint32 total_steps = 2; + */ + totalSteps: number; + + /** + * @generated from field: uint32 current_step_number = 3; + */ + currentStepNumber: number; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkRunProgress"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkRunProgress; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkRunProgress; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkRunProgress; + + static equals(a: StarlarkRunProgress | PlainMessage | undefined, b: StarlarkRunProgress | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StarlarkRunFinishedEvent + */ +export declare class StarlarkRunFinishedEvent extends Message { + /** + * @generated from field: bool is_run_successful = 1; + */ + isRunSuccessful: boolean; + + /** + * @generated from field: optional string serialized_output = 2; + */ + serializedOutput?: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkRunFinishedEvent"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkRunFinishedEvent; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkRunFinishedEvent; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkRunFinishedEvent; + + static equals(a: StarlarkRunFinishedEvent | PlainMessage | undefined, b: StarlarkRunFinishedEvent | PlainMessage | undefined): boolean; +} + +/** + * ============================================================================================== + * Get Services + * ============================================================================================== + * + * @generated from message api_container_api.GetServicesArgs + */ +export declare class GetServicesArgs extends Message { + /** + * "Set" of identifiers to fetch info for + * If empty, will fetch info for all services + * + * @generated from field: map service_identifiers = 1; + */ + serviceIdentifiers: { [key: string]: boolean }; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.GetServicesArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): GetServicesArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): GetServicesArgs; + + static fromJsonString(jsonString: string, options?: Partial): GetServicesArgs; + + static equals(a: GetServicesArgs | PlainMessage | undefined, b: GetServicesArgs | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.GetServicesResponse + */ +export declare class GetServicesResponse extends Message { + /** + * "Set" from identifiers -> info about the service + * + * @generated from field: map service_info = 1; + */ + serviceInfo: { [key: string]: ServiceInfo }; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.GetServicesResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): GetServicesResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): GetServicesResponse; + + static fromJsonString(jsonString: string, options?: Partial): GetServicesResponse; + + static equals(a: GetServicesResponse | PlainMessage | undefined, b: GetServicesResponse | PlainMessage | undefined): boolean; +} + +/** + * An service identifier is a collection of uuid, name and shortened uuid + * + * @generated from message api_container_api.ServiceIdentifiers + */ +export declare class ServiceIdentifiers extends Message { + /** + * UUID of the service + * + * @generated from field: string service_uuid = 1; + */ + serviceUuid: string; + + /** + * Name of the service + * + * @generated from field: string name = 2; + */ + name: string; + + /** + * The shortened uuid of the service + * + * @generated from field: string shortened_uuid = 3; + */ + shortenedUuid: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.ServiceIdentifiers"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): ServiceIdentifiers; + + static fromJson(jsonValue: JsonValue, options?: Partial): ServiceIdentifiers; + + static fromJsonString(jsonString: string, options?: Partial): ServiceIdentifiers; + + static equals(a: ServiceIdentifiers | PlainMessage | undefined, b: ServiceIdentifiers | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.GetExistingAndHistoricalServiceIdentifiersResponse + */ +export declare class GetExistingAndHistoricalServiceIdentifiersResponse extends Message { + /** + * @generated from field: repeated api_container_api.ServiceIdentifiers allIdentifiers = 1; + */ + allIdentifiers: ServiceIdentifiers[]; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.GetExistingAndHistoricalServiceIdentifiersResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): GetExistingAndHistoricalServiceIdentifiersResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): GetExistingAndHistoricalServiceIdentifiersResponse; + + static fromJsonString(jsonString: string, options?: Partial): GetExistingAndHistoricalServiceIdentifiersResponse; + + static equals(a: GetExistingAndHistoricalServiceIdentifiersResponse | PlainMessage | undefined, b: GetExistingAndHistoricalServiceIdentifiersResponse | PlainMessage | undefined): boolean; +} + +/** + * ============================================================================================== + * Exec Command + * ============================================================================================== + * + * @generated from message api_container_api.ExecCommandArgs + */ +export declare class ExecCommandArgs extends Message { + /** + * The service identifier of the container that the command should be executed in + * + * @generated from field: string service_identifier = 1; + */ + serviceIdentifier: string; + + /** + * @generated from field: repeated string command_args = 2; + */ + commandArgs: string[]; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.ExecCommandArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): ExecCommandArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): ExecCommandArgs; + + static fromJsonString(jsonString: string, options?: Partial): ExecCommandArgs; + + static equals(a: ExecCommandArgs | PlainMessage | undefined, b: ExecCommandArgs | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.ExecCommandResponse + */ +export declare class ExecCommandResponse extends Message { + /** + * @generated from field: int32 exit_code = 1; + */ + exitCode: number; + + /** + * Assumes UTF-8 encoding + * + * @generated from field: string log_output = 2; + */ + logOutput: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.ExecCommandResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): ExecCommandResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): ExecCommandResponse; + + static fromJsonString(jsonString: string, options?: Partial): ExecCommandResponse; + + static equals(a: ExecCommandResponse | PlainMessage | undefined, b: ExecCommandResponse | PlainMessage | undefined): boolean; +} + +/** + * ============================================================================================== + * Wait For HTTP Get Endpoint Availability + * ============================================================================================== + * + * @generated from message api_container_api.WaitForHttpGetEndpointAvailabilityArgs + */ +export declare class WaitForHttpGetEndpointAvailabilityArgs extends Message { + /** + * The identifier of the service to check. + * + * @generated from field: string service_identifier = 1; + */ + serviceIdentifier: string; + + /** + * The port of the service to check. For instance 8080 + * + * @generated from field: uint32 port = 2; + */ + port: number; + + /** + * The path of the service to check. It mustn't start with the first slash. For instance `service/health` + * + * @generated from field: optional string path = 3; + */ + path?: string; + + /** + * The number of milliseconds to wait until executing the first HTTP call + * + * @generated from field: optional uint32 initial_delay_milliseconds = 4; + */ + initialDelayMilliseconds?: number; + + /** + * Max number of HTTP call attempts that this will execute until giving up and returning an error + * + * @generated from field: optional uint32 retries = 5; + */ + retries?: number; + + /** + * Number of milliseconds to wait between retries + * + * @generated from field: optional uint32 retries_delay_milliseconds = 6; + */ + retriesDelayMilliseconds?: number; + + /** + * If the endpoint returns this value, the service will be marked as available (e.g. Hello World). + * + * @generated from field: optional string body_text = 7; + */ + bodyText?: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.WaitForHttpGetEndpointAvailabilityArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): WaitForHttpGetEndpointAvailabilityArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): WaitForHttpGetEndpointAvailabilityArgs; + + static fromJsonString(jsonString: string, options?: Partial): WaitForHttpGetEndpointAvailabilityArgs; + + static equals(a: WaitForHttpGetEndpointAvailabilityArgs | PlainMessage | undefined, b: WaitForHttpGetEndpointAvailabilityArgs | PlainMessage | undefined): boolean; +} + +/** + * ============================================================================================== + * Wait For HTTP Post Endpoint Availability + * ============================================================================================== + * + * @generated from message api_container_api.WaitForHttpPostEndpointAvailabilityArgs + */ +export declare class WaitForHttpPostEndpointAvailabilityArgs extends Message { + /** + * The identifier of the service to check. + * + * @generated from field: string service_identifier = 1; + */ + serviceIdentifier: string; + + /** + * The port of the service to check. For instance 8080 + * + * @generated from field: uint32 port = 2; + */ + port: number; + + /** + * The path of the service to check. It mustn't start with the first slash. For instance `service/health` + * + * @generated from field: optional string path = 3; + */ + path?: string; + + /** + * The content of the request body. + * + * @generated from field: optional string request_body = 4; + */ + requestBody?: string; + + /** + * The number of milliseconds to wait until executing the first HTTP call + * + * @generated from field: optional uint32 initial_delay_milliseconds = 5; + */ + initialDelayMilliseconds?: number; + + /** + * Max number of HTTP call attempts that this will execute until giving up and returning an error + * + * @generated from field: optional uint32 retries = 6; + */ + retries?: number; + + /** + * Number of milliseconds to wait between retries + * + * @generated from field: optional uint32 retries_delay_milliseconds = 7; + */ + retriesDelayMilliseconds?: number; + + /** + * If the endpoint returns this value, the service will be marked as available (e.g. Hello World). + * + * @generated from field: optional string body_text = 8; + */ + bodyText?: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.WaitForHttpPostEndpointAvailabilityArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): WaitForHttpPostEndpointAvailabilityArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): WaitForHttpPostEndpointAvailabilityArgs; + + static fromJsonString(jsonString: string, options?: Partial): WaitForHttpPostEndpointAvailabilityArgs; + + static equals(a: WaitForHttpPostEndpointAvailabilityArgs | PlainMessage | undefined, b: WaitForHttpPostEndpointAvailabilityArgs | PlainMessage | undefined): boolean; +} + +/** + * ============================================================================================== + * Streamed Data Chunk + * ============================================================================================== + * + * @generated from message api_container_api.StreamedDataChunk + */ +export declare class StreamedDataChunk extends Message { + /** + * Chunk of the overall files artifact bytes + * + * @generated from field: bytes data = 1; + */ + data: Uint8Array; + + /** + * Hash of the PREVIOUS chunk, or empty string is this is the first chunk + * Referencing the previous chunk via its hash allows Kurtosis to validate + * the consistency of the data in case some chunk were not received + * + * @generated from field: string previous_chunk_hash = 2; + */ + previousChunkHash: string; + + /** + * Additional metadata about the item being streamed + * + * @generated from field: api_container_api.DataChunkMetadata metadata = 3; + */ + metadata?: DataChunkMetadata; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StreamedDataChunk"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StreamedDataChunk; + + static fromJson(jsonValue: JsonValue, options?: Partial): StreamedDataChunk; + + static fromJsonString(jsonString: string, options?: Partial): StreamedDataChunk; + + static equals(a: StreamedDataChunk | PlainMessage | undefined, b: StreamedDataChunk | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.DataChunkMetadata + */ +export declare class DataChunkMetadata extends Message { + /** + * @generated from field: string name = 1; + */ + name: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.DataChunkMetadata"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): DataChunkMetadata; + + static fromJson(jsonValue: JsonValue, options?: Partial): DataChunkMetadata; + + static fromJsonString(jsonString: string, options?: Partial): DataChunkMetadata; + + static equals(a: DataChunkMetadata | PlainMessage | undefined, b: DataChunkMetadata | PlainMessage | undefined): boolean; +} + +/** + * ============================================================================================== + * Upload Files Artifact + * ============================================================================================== + * + * @generated from message api_container_api.UploadFilesArtifactResponse + */ +export declare class UploadFilesArtifactResponse extends Message { + /** + * UUID of the files artifact, for use when referencing it in the future + * + * @generated from field: string uuid = 1; + */ + uuid: string; + + /** + * UUID of the files artifact, for use when referencing it in the future + * + * @generated from field: string name = 2; + */ + name: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.UploadFilesArtifactResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): UploadFilesArtifactResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): UploadFilesArtifactResponse; + + static fromJsonString(jsonString: string, options?: Partial): UploadFilesArtifactResponse; + + static equals(a: UploadFilesArtifactResponse | PlainMessage | undefined, b: UploadFilesArtifactResponse | PlainMessage | undefined): boolean; +} + +/** + * ============================================================================================== + * Download Files Artifact + * ============================================================================================== + * + * @generated from message api_container_api.DownloadFilesArtifactArgs + */ +export declare class DownloadFilesArtifactArgs extends Message { + /** + * Files identifier to get bytes for + * + * @generated from field: string identifier = 1; + */ + identifier: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.DownloadFilesArtifactArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): DownloadFilesArtifactArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): DownloadFilesArtifactArgs; + + static fromJsonString(jsonString: string, options?: Partial): DownloadFilesArtifactArgs; + + static equals(a: DownloadFilesArtifactArgs | PlainMessage | undefined, b: DownloadFilesArtifactArgs | PlainMessage | undefined): boolean; +} + +/** + * ============================================================================================== + * Store Web Files Artifact + * ============================================================================================== + * + * @generated from message api_container_api.StoreWebFilesArtifactArgs + */ +export declare class StoreWebFilesArtifactArgs extends Message { + /** + * URL to download the artifact from + * + * @generated from field: string url = 1; + */ + url: string; + + /** + * The name of the files artifact + * + * @generated from field: string name = 2; + */ + name: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StoreWebFilesArtifactArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StoreWebFilesArtifactArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): StoreWebFilesArtifactArgs; + + static fromJsonString(jsonString: string, options?: Partial): StoreWebFilesArtifactArgs; + + static equals(a: StoreWebFilesArtifactArgs | PlainMessage | undefined, b: StoreWebFilesArtifactArgs | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StoreWebFilesArtifactResponse + */ +export declare class StoreWebFilesArtifactResponse extends Message { + /** + * UUID of the files artifact, for use when referencing it in the future + * + * @generated from field: string uuid = 1; + */ + uuid: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StoreWebFilesArtifactResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StoreWebFilesArtifactResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): StoreWebFilesArtifactResponse; + + static fromJsonString(jsonString: string, options?: Partial): StoreWebFilesArtifactResponse; + + static equals(a: StoreWebFilesArtifactResponse | PlainMessage | undefined, b: StoreWebFilesArtifactResponse | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StoreFilesArtifactFromServiceArgs + */ +export declare class StoreFilesArtifactFromServiceArgs extends Message { + /** + * Identifier that will be used to identify the service where the source files will be copied from + * + * @generated from field: string service_identifier = 1; + */ + serviceIdentifier: string; + + /** + * The absolute source path where the source files will be copied from + * + * @generated from field: string source_path = 2; + */ + sourcePath: string; + + /** + * The name of the files artifact + * + * @generated from field: string name = 3; + */ + name: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StoreFilesArtifactFromServiceArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StoreFilesArtifactFromServiceArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): StoreFilesArtifactFromServiceArgs; + + static fromJsonString(jsonString: string, options?: Partial): StoreFilesArtifactFromServiceArgs; + + static equals(a: StoreFilesArtifactFromServiceArgs | PlainMessage | undefined, b: StoreFilesArtifactFromServiceArgs | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StoreFilesArtifactFromServiceResponse + */ +export declare class StoreFilesArtifactFromServiceResponse extends Message { + /** + * UUID of the files artifact, for use when referencing it in the future + * + * @generated from field: string uuid = 1; + */ + uuid: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StoreFilesArtifactFromServiceResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StoreFilesArtifactFromServiceResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): StoreFilesArtifactFromServiceResponse; + + static fromJsonString(jsonString: string, options?: Partial): StoreFilesArtifactFromServiceResponse; + + static equals(a: StoreFilesArtifactFromServiceResponse | PlainMessage | undefined, b: StoreFilesArtifactFromServiceResponse | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.FilesArtifactNameAndUuid + */ +export declare class FilesArtifactNameAndUuid extends Message { + /** + * A string representing the name of the file + * + * @generated from field: string fileName = 1; + */ + fileName: string; + + /** + * A string representing the uuid of the file + * + * @generated from field: string fileUuid = 2; + */ + fileUuid: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.FilesArtifactNameAndUuid"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): FilesArtifactNameAndUuid; + + static fromJson(jsonValue: JsonValue, options?: Partial): FilesArtifactNameAndUuid; + + static fromJsonString(jsonString: string, options?: Partial): FilesArtifactNameAndUuid; + + static equals(a: FilesArtifactNameAndUuid | PlainMessage | undefined, b: FilesArtifactNameAndUuid | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.ListFilesArtifactNamesAndUuidsResponse + */ +export declare class ListFilesArtifactNamesAndUuidsResponse extends Message { + /** + * @generated from field: repeated api_container_api.FilesArtifactNameAndUuid file_names_and_uuids = 1; + */ + fileNamesAndUuids: FilesArtifactNameAndUuid[]; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.ListFilesArtifactNamesAndUuidsResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): ListFilesArtifactNamesAndUuidsResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): ListFilesArtifactNamesAndUuidsResponse; + + static fromJsonString(jsonString: string, options?: Partial): ListFilesArtifactNamesAndUuidsResponse; + + static equals(a: ListFilesArtifactNamesAndUuidsResponse | PlainMessage | undefined, b: ListFilesArtifactNamesAndUuidsResponse | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.InspectFilesArtifactContentsRequest + */ +export declare class InspectFilesArtifactContentsRequest extends Message { + /** + * @generated from field: api_container_api.FilesArtifactNameAndUuid file_names_and_uuid = 1; + */ + fileNamesAndUuid?: FilesArtifactNameAndUuid; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.InspectFilesArtifactContentsRequest"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): InspectFilesArtifactContentsRequest; + + static fromJson(jsonValue: JsonValue, options?: Partial): InspectFilesArtifactContentsRequest; + + static fromJsonString(jsonString: string, options?: Partial): InspectFilesArtifactContentsRequest; + + static equals(a: InspectFilesArtifactContentsRequest | PlainMessage | undefined, b: InspectFilesArtifactContentsRequest | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.InspectFilesArtifactContentsResponse + */ +export declare class InspectFilesArtifactContentsResponse extends Message { + /** + * @generated from field: repeated api_container_api.FileArtifactContentsFileDescription file_descriptions = 1; + */ + fileDescriptions: FileArtifactContentsFileDescription[]; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.InspectFilesArtifactContentsResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): InspectFilesArtifactContentsResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): InspectFilesArtifactContentsResponse; + + static fromJsonString(jsonString: string, options?: Partial): InspectFilesArtifactContentsResponse; + + static equals(a: InspectFilesArtifactContentsResponse | PlainMessage | undefined, b: InspectFilesArtifactContentsResponse | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.FileArtifactContentsFileDescription + */ +export declare class FileArtifactContentsFileDescription extends Message { + /** + * Path relative to the file artifact + * + * @generated from field: string path = 1; + */ + path: string; + + /** + * Size of the file, in bytes + * + * @generated from field: uint64 size = 2; + */ + size: bigint; + + /** + * A bit of text content, if the file allows (similar to UNIX's 'head') + * + * @generated from field: optional string text_preview = 3; + */ + textPreview?: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.FileArtifactContentsFileDescription"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): FileArtifactContentsFileDescription; + + static fromJson(jsonValue: JsonValue, options?: Partial): FileArtifactContentsFileDescription; + + static fromJsonString(jsonString: string, options?: Partial): FileArtifactContentsFileDescription; + + static equals(a: FileArtifactContentsFileDescription | PlainMessage | undefined, b: FileArtifactContentsFileDescription | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.ConnectServicesArgs + */ +export declare class ConnectServicesArgs extends Message { + /** + * @generated from field: api_container_api.Connect connect = 1; + */ + connect: Connect; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.ConnectServicesArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): ConnectServicesArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): ConnectServicesArgs; + + static fromJsonString(jsonString: string, options?: Partial): ConnectServicesArgs; + + static equals(a: ConnectServicesArgs | PlainMessage | undefined, b: ConnectServicesArgs | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.ConnectServicesResponse + */ +export declare class ConnectServicesResponse extends Message { + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.ConnectServicesResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): ConnectServicesResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): ConnectServicesResponse; + + static fromJsonString(jsonString: string, options?: Partial): ConnectServicesResponse; + + static equals(a: ConnectServicesResponse | PlainMessage | undefined, b: ConnectServicesResponse | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.GetStarlarkRunResponse + */ +export declare class GetStarlarkRunResponse extends Message { + /** + * @generated from field: string package_id = 1; + */ + packageId: string; + + /** + * @generated from field: string serialized_script = 2; + */ + serializedScript: string; + + /** + * @generated from field: string serialized_params = 3; + */ + serializedParams: string; + + /** + * @generated from field: int32 parallelism = 4; + */ + parallelism: number; + + /** + * @generated from field: string relative_path_to_main_file = 5; + */ + relativePathToMainFile: string; + + /** + * @generated from field: string main_function_name = 6; + */ + mainFunctionName: string; + + /** + * @generated from field: repeated api_container_api.KurtosisFeatureFlag experimental_features = 7; + */ + experimentalFeatures: KurtosisFeatureFlag[]; + + /** + * @generated from field: api_container_api.RestartPolicy restart_policy = 8; + */ + restartPolicy: RestartPolicy; + + /** + * The params that were used on for the very first Starlark run in an APIC + * + * @generated from field: optional string initial_serialized_params = 9; + */ + initialSerializedParams?: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.GetStarlarkRunResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): GetStarlarkRunResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): GetStarlarkRunResponse; + + static fromJsonString(jsonString: string, options?: Partial): GetStarlarkRunResponse; + + static equals(a: GetStarlarkRunResponse | PlainMessage | undefined, b: GetStarlarkRunResponse | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.PlanYaml + */ +export declare class PlanYaml extends Message { + /** + * @generated from field: string plan_yaml = 1; + */ + planYaml: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.PlanYaml"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): PlanYaml; + + static fromJson(jsonValue: JsonValue, options?: Partial): PlanYaml; + + static fromJsonString(jsonString: string, options?: Partial): PlanYaml; + + static equals(a: PlanYaml | PlainMessage | undefined, b: PlanYaml | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StarlarkScriptPlanYamlArgs + */ +export declare class StarlarkScriptPlanYamlArgs extends Message { + /** + * @generated from field: string serialized_script = 1; + */ + serializedScript: string; + + /** + * @generated from field: optional string serialized_params = 2; + */ + serializedParams?: string; + + /** + * The name of the main function, the default value is "run" + * + * @generated from field: optional string main_function_name = 5; + */ + mainFunctionName?: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkScriptPlanYamlArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkScriptPlanYamlArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkScriptPlanYamlArgs; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkScriptPlanYamlArgs; + + static equals(a: StarlarkScriptPlanYamlArgs | PlainMessage | undefined, b: StarlarkScriptPlanYamlArgs | PlainMessage | undefined): boolean; +} + +/** + * @generated from message api_container_api.StarlarkPackagePlanYamlArgs + */ +export declare class StarlarkPackagePlanYamlArgs extends Message { + /** + * @generated from field: string package_id = 1; + */ + packageId: string; + + /** + * Serialized parameters data for the Starlark package main function + * This should be a valid JSON string + * + * @generated from field: optional string serialized_params = 2; + */ + serializedParams?: string; + + /** + * The relative main file filepath, the default value is the "main.star" file in the root of a package + * + * @generated from field: optional string relative_path_to_main_file = 3; + */ + relativePathToMainFile?: string; + + /** + * The name of the main function, the default value is "run" + * + * @generated from field: optional string main_function_name = 4; + */ + mainFunctionName?: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "api_container_api.StarlarkPackagePlanYamlArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StarlarkPackagePlanYamlArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): StarlarkPackagePlanYamlArgs; + + static fromJsonString(jsonString: string, options?: Partial): StarlarkPackagePlanYamlArgs; + + static equals(a: StarlarkPackagePlanYamlArgs | PlainMessage | undefined, b: StarlarkPackagePlanYamlArgs | PlainMessage | undefined): boolean; +} + diff --git a/enclave-manager/api/typescript/src/api_container_service_pb.js b/enclave-manager/api/typescript/src/api_container_service_pb.js new file mode 100644 index 0000000000..164d68d7d5 --- /dev/null +++ b/enclave-manager/api/typescript/src/api_container_service_pb.js @@ -0,0 +1,677 @@ +// @generated by protoc-gen-es v1.3.1 with parameter "target=js+dts" +// @generated from file api_container_service.proto (package api_container_api, syntax proto3) +/* eslint-disable */ +// @ts-nocheck + +import { proto3 } from "@bufbuild/protobuf"; + +/** + * @generated from enum api_container_api.ServiceStatus + */ +export const ServiceStatus = proto3.makeEnum( + "api_container_api.ServiceStatus", + [ + {no: 0, name: "STOPPED"}, + {no: 1, name: "RUNNING"}, + {no: 2, name: "UNKNOWN"}, + ], +); + +/** + * @generated from enum api_container_api.ImageDownloadMode + */ +export const ImageDownloadMode = proto3.makeEnum( + "api_container_api.ImageDownloadMode", + [ + {no: 0, name: "always"}, + {no: 1, name: "missing"}, + ], +); + +/** + * User services port forwarding + * + * @generated from enum api_container_api.Connect + */ +export const Connect = proto3.makeEnum( + "api_container_api.Connect", + [ + {no: 0, name: "CONNECT"}, + {no: 1, name: "NO_CONNECT"}, + ], +); + +/** + * @generated from enum api_container_api.KurtosisFeatureFlag + */ +export const KurtosisFeatureFlag = proto3.makeEnum( + "api_container_api.KurtosisFeatureFlag", + [ + {no: 0, name: "NO_INSTRUCTIONS_CACHING"}, + ], +); + +/** + * @generated from enum api_container_api.RestartPolicy + */ +export const RestartPolicy = proto3.makeEnum( + "api_container_api.RestartPolicy", + [ + {no: 0, name: "NEVER"}, + {no: 1, name: "ALWAYS"}, + ], +); + +/** + * ============================================================================================== + * Shared Objects (Used By Multiple Endpoints) + * ============================================================================================== + * + * @generated from message api_container_api.Port + */ +export const Port = proto3.makeMessageType( + "api_container_api.Port", + () => [ + { no: 1, name: "number", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, + { no: 2, name: "transport_protocol", kind: "enum", T: proto3.getEnumType(Port_TransportProtocol) }, + { no: 3, name: "maybe_application_protocol", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 4, name: "maybe_wait_timeout", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 5, name: "locked", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true }, + { no: 6, name: "alias", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + ], +); + +/** + * @generated from enum api_container_api.Port.TransportProtocol + */ +export const Port_TransportProtocol = proto3.makeEnum( + "api_container_api.Port.TransportProtocol", + [ + {no: 0, name: "TCP"}, + {no: 1, name: "SCTP"}, + {no: 2, name: "UDP"}, + ], +); + +/** + * @generated from message api_container_api.Container + */ +export const Container = proto3.makeMessageType( + "api_container_api.Container", + () => [ + { no: 1, name: "status", kind: "enum", T: proto3.getEnumType(Container_Status) }, + { no: 2, name: "image_name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "entrypoint_args", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true }, + { no: 4, name: "cmd_args", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true }, + { no: 5, name: "env_vars", kind: "map", K: 9 /* ScalarType.STRING */, V: {kind: "scalar", T: 9 /* ScalarType.STRING */} }, + ], +); + +/** + * @generated from enum api_container_api.Container.Status + */ +export const Container_Status = proto3.makeEnum( + "api_container_api.Container.Status", + [ + {no: 0, name: "STOPPED"}, + {no: 1, name: "RUNNING"}, + {no: 2, name: "UNKNOWN"}, + ], +); + +/** + * @generated from message api_container_api.ServiceInfo + */ +export const ServiceInfo = proto3.makeMessageType( + "api_container_api.ServiceInfo", + () => [ + { no: 1, name: "service_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "private_ip_addr", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "private_ports", kind: "map", K: 9 /* ScalarType.STRING */, V: {kind: "message", T: Port} }, + { no: 4, name: "maybe_public_ip_addr", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 5, name: "maybe_public_ports", kind: "map", K: 9 /* ScalarType.STRING */, V: {kind: "message", T: Port} }, + { no: 6, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 7, name: "shortened_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 8, name: "service_status", kind: "enum", T: proto3.getEnumType(ServiceStatus) }, + { no: 9, name: "container", kind: "message", T: Container }, + ], +); + +/** + * @generated from message api_container_api.RunStarlarkScriptArgs + */ +export const RunStarlarkScriptArgs = proto3.makeMessageType( + "api_container_api.RunStarlarkScriptArgs", + () => [ + { no: 1, name: "serialized_script", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "serialized_params", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 3, name: "dry_run", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true }, + { no: 4, name: "parallelism", kind: "scalar", T: 5 /* ScalarType.INT32 */, opt: true }, + { no: 5, name: "main_function_name", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 6, name: "experimental_features", kind: "enum", T: proto3.getEnumType(KurtosisFeatureFlag), repeated: true }, + { no: 7, name: "cloud_instance_id", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 8, name: "cloud_user_id", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 9, name: "image_download_mode", kind: "enum", T: proto3.getEnumType(ImageDownloadMode), opt: true }, + { no: 10, name: "non_blocking_mode", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true }, + ], +); + +/** + * @generated from message api_container_api.RunStarlarkPackageArgs + */ +export const RunStarlarkPackageArgs = proto3.makeMessageType( + "api_container_api.RunStarlarkPackageArgs", + () => [ + { no: 1, name: "package_id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "local", kind: "scalar", T: 12 /* ScalarType.BYTES */, oneof: "starlark_package_content" }, + { no: 4, name: "remote", kind: "scalar", T: 8 /* ScalarType.BOOL */, oneof: "starlark_package_content" }, + { no: 5, name: "serialized_params", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 6, name: "dry_run", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true }, + { no: 7, name: "parallelism", kind: "scalar", T: 5 /* ScalarType.INT32 */, opt: true }, + { no: 8, name: "clone_package", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true }, + { no: 9, name: "relative_path_to_main_file", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 10, name: "main_function_name", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 11, name: "experimental_features", kind: "enum", T: proto3.getEnumType(KurtosisFeatureFlag), repeated: true }, + { no: 12, name: "cloud_instance_id", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 13, name: "cloud_user_id", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 14, name: "image_download_mode", kind: "enum", T: proto3.getEnumType(ImageDownloadMode), opt: true }, + { no: 15, name: "non_blocking_mode", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true }, + { no: 16, name: "github_auth_token", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + ], +); + +/** + * ============================================================================================== + * Starlark Execution Response + * ============================================================================================== + * + * @generated from message api_container_api.StarlarkRunResponseLine + */ +export const StarlarkRunResponseLine = proto3.makeMessageType( + "api_container_api.StarlarkRunResponseLine", + () => [ + { no: 1, name: "instruction", kind: "message", T: StarlarkInstruction, oneof: "run_response_line" }, + { no: 2, name: "error", kind: "message", T: StarlarkError, oneof: "run_response_line" }, + { no: 3, name: "progress_info", kind: "message", T: StarlarkRunProgress, oneof: "run_response_line" }, + { no: 4, name: "instruction_result", kind: "message", T: StarlarkInstructionResult, oneof: "run_response_line" }, + { no: 5, name: "run_finished_event", kind: "message", T: StarlarkRunFinishedEvent, oneof: "run_response_line" }, + { no: 6, name: "warning", kind: "message", T: StarlarkWarning, oneof: "run_response_line" }, + { no: 7, name: "info", kind: "message", T: StarlarkInfo, oneof: "run_response_line" }, + ], +); + +/** + * @generated from message api_container_api.StarlarkInfo + */ +export const StarlarkInfo = proto3.makeMessageType( + "api_container_api.StarlarkInfo", + () => [ + { no: 1, name: "info_message", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message api_container_api.StarlarkWarning + */ +export const StarlarkWarning = proto3.makeMessageType( + "api_container_api.StarlarkWarning", + () => [ + { no: 1, name: "warning_message", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message api_container_api.StarlarkInstruction + */ +export const StarlarkInstruction = proto3.makeMessageType( + "api_container_api.StarlarkInstruction", + () => [ + { no: 1, name: "position", kind: "message", T: StarlarkInstructionPosition }, + { no: 2, name: "instruction_name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "arguments", kind: "message", T: StarlarkInstructionArg, repeated: true }, + { no: 4, name: "executable_instruction", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 5, name: "is_skipped", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, + { no: 6, name: "description", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message api_container_api.StarlarkInstructionResult + */ +export const StarlarkInstructionResult = proto3.makeMessageType( + "api_container_api.StarlarkInstructionResult", + () => [ + { no: 1, name: "serialized_instruction_result", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message api_container_api.StarlarkInstructionArg + */ +export const StarlarkInstructionArg = proto3.makeMessageType( + "api_container_api.StarlarkInstructionArg", + () => [ + { no: 1, name: "serialized_arg_value", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "arg_name", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 3, name: "is_representative", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, + ], +); + +/** + * @generated from message api_container_api.StarlarkInstructionPosition + */ +export const StarlarkInstructionPosition = proto3.makeMessageType( + "api_container_api.StarlarkInstructionPosition", + () => [ + { no: 1, name: "filename", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "line", kind: "scalar", T: 5 /* ScalarType.INT32 */ }, + { no: 3, name: "column", kind: "scalar", T: 5 /* ScalarType.INT32 */ }, + ], +); + +/** + * @generated from message api_container_api.StarlarkError + */ +export const StarlarkError = proto3.makeMessageType( + "api_container_api.StarlarkError", + () => [ + { no: 1, name: "interpretation_error", kind: "message", T: StarlarkInterpretationError, oneof: "error" }, + { no: 2, name: "validation_error", kind: "message", T: StarlarkValidationError, oneof: "error" }, + { no: 3, name: "execution_error", kind: "message", T: StarlarkExecutionError, oneof: "error" }, + ], +); + +/** + * @generated from message api_container_api.StarlarkInterpretationError + */ +export const StarlarkInterpretationError = proto3.makeMessageType( + "api_container_api.StarlarkInterpretationError", + () => [ + { no: 1, name: "error_message", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message api_container_api.StarlarkValidationError + */ +export const StarlarkValidationError = proto3.makeMessageType( + "api_container_api.StarlarkValidationError", + () => [ + { no: 1, name: "error_message", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message api_container_api.StarlarkExecutionError + */ +export const StarlarkExecutionError = proto3.makeMessageType( + "api_container_api.StarlarkExecutionError", + () => [ + { no: 1, name: "error_message", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message api_container_api.StarlarkRunProgress + */ +export const StarlarkRunProgress = proto3.makeMessageType( + "api_container_api.StarlarkRunProgress", + () => [ + { no: 1, name: "current_step_info", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true }, + { no: 2, name: "total_steps", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, + { no: 3, name: "current_step_number", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, + ], +); + +/** + * @generated from message api_container_api.StarlarkRunFinishedEvent + */ +export const StarlarkRunFinishedEvent = proto3.makeMessageType( + "api_container_api.StarlarkRunFinishedEvent", + () => [ + { no: 1, name: "is_run_successful", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, + { no: 2, name: "serialized_output", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + ], +); + +/** + * ============================================================================================== + * Get Services + * ============================================================================================== + * + * @generated from message api_container_api.GetServicesArgs + */ +export const GetServicesArgs = proto3.makeMessageType( + "api_container_api.GetServicesArgs", + () => [ + { no: 1, name: "service_identifiers", kind: "map", K: 9 /* ScalarType.STRING */, V: {kind: "scalar", T: 8 /* ScalarType.BOOL */} }, + ], +); + +/** + * @generated from message api_container_api.GetServicesResponse + */ +export const GetServicesResponse = proto3.makeMessageType( + "api_container_api.GetServicesResponse", + () => [ + { no: 1, name: "service_info", kind: "map", K: 9 /* ScalarType.STRING */, V: {kind: "message", T: ServiceInfo} }, + ], +); + +/** + * An service identifier is a collection of uuid, name and shortened uuid + * + * @generated from message api_container_api.ServiceIdentifiers + */ +export const ServiceIdentifiers = proto3.makeMessageType( + "api_container_api.ServiceIdentifiers", + () => [ + { no: 1, name: "service_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "shortened_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message api_container_api.GetExistingAndHistoricalServiceIdentifiersResponse + */ +export const GetExistingAndHistoricalServiceIdentifiersResponse = proto3.makeMessageType( + "api_container_api.GetExistingAndHistoricalServiceIdentifiersResponse", + () => [ + { no: 1, name: "allIdentifiers", kind: "message", T: ServiceIdentifiers, repeated: true }, + ], +); + +/** + * ============================================================================================== + * Exec Command + * ============================================================================================== + * + * @generated from message api_container_api.ExecCommandArgs + */ +export const ExecCommandArgs = proto3.makeMessageType( + "api_container_api.ExecCommandArgs", + () => [ + { no: 1, name: "service_identifier", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "command_args", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true }, + ], +); + +/** + * @generated from message api_container_api.ExecCommandResponse + */ +export const ExecCommandResponse = proto3.makeMessageType( + "api_container_api.ExecCommandResponse", + () => [ + { no: 1, name: "exit_code", kind: "scalar", T: 5 /* ScalarType.INT32 */ }, + { no: 2, name: "log_output", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * ============================================================================================== + * Wait For HTTP Get Endpoint Availability + * ============================================================================================== + * + * @generated from message api_container_api.WaitForHttpGetEndpointAvailabilityArgs + */ +export const WaitForHttpGetEndpointAvailabilityArgs = proto3.makeMessageType( + "api_container_api.WaitForHttpGetEndpointAvailabilityArgs", + () => [ + { no: 1, name: "service_identifier", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "port", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, + { no: 3, name: "path", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 4, name: "initial_delay_milliseconds", kind: "scalar", T: 13 /* ScalarType.UINT32 */, opt: true }, + { no: 5, name: "retries", kind: "scalar", T: 13 /* ScalarType.UINT32 */, opt: true }, + { no: 6, name: "retries_delay_milliseconds", kind: "scalar", T: 13 /* ScalarType.UINT32 */, opt: true }, + { no: 7, name: "body_text", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + ], +); + +/** + * ============================================================================================== + * Wait For HTTP Post Endpoint Availability + * ============================================================================================== + * + * @generated from message api_container_api.WaitForHttpPostEndpointAvailabilityArgs + */ +export const WaitForHttpPostEndpointAvailabilityArgs = proto3.makeMessageType( + "api_container_api.WaitForHttpPostEndpointAvailabilityArgs", + () => [ + { no: 1, name: "service_identifier", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "port", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, + { no: 3, name: "path", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 4, name: "request_body", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 5, name: "initial_delay_milliseconds", kind: "scalar", T: 13 /* ScalarType.UINT32 */, opt: true }, + { no: 6, name: "retries", kind: "scalar", T: 13 /* ScalarType.UINT32 */, opt: true }, + { no: 7, name: "retries_delay_milliseconds", kind: "scalar", T: 13 /* ScalarType.UINT32 */, opt: true }, + { no: 8, name: "body_text", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + ], +); + +/** + * ============================================================================================== + * Streamed Data Chunk + * ============================================================================================== + * + * @generated from message api_container_api.StreamedDataChunk + */ +export const StreamedDataChunk = proto3.makeMessageType( + "api_container_api.StreamedDataChunk", + () => [ + { no: 1, name: "data", kind: "scalar", T: 12 /* ScalarType.BYTES */ }, + { no: 2, name: "previous_chunk_hash", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "metadata", kind: "message", T: DataChunkMetadata }, + ], +); + +/** + * @generated from message api_container_api.DataChunkMetadata + */ +export const DataChunkMetadata = proto3.makeMessageType( + "api_container_api.DataChunkMetadata", + () => [ + { no: 1, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * ============================================================================================== + * Upload Files Artifact + * ============================================================================================== + * + * @generated from message api_container_api.UploadFilesArtifactResponse + */ +export const UploadFilesArtifactResponse = proto3.makeMessageType( + "api_container_api.UploadFilesArtifactResponse", + () => [ + { no: 1, name: "uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * ============================================================================================== + * Download Files Artifact + * ============================================================================================== + * + * @generated from message api_container_api.DownloadFilesArtifactArgs + */ +export const DownloadFilesArtifactArgs = proto3.makeMessageType( + "api_container_api.DownloadFilesArtifactArgs", + () => [ + { no: 1, name: "identifier", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * ============================================================================================== + * Store Web Files Artifact + * ============================================================================================== + * + * @generated from message api_container_api.StoreWebFilesArtifactArgs + */ +export const StoreWebFilesArtifactArgs = proto3.makeMessageType( + "api_container_api.StoreWebFilesArtifactArgs", + () => [ + { no: 1, name: "url", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message api_container_api.StoreWebFilesArtifactResponse + */ +export const StoreWebFilesArtifactResponse = proto3.makeMessageType( + "api_container_api.StoreWebFilesArtifactResponse", + () => [ + { no: 1, name: "uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message api_container_api.StoreFilesArtifactFromServiceArgs + */ +export const StoreFilesArtifactFromServiceArgs = proto3.makeMessageType( + "api_container_api.StoreFilesArtifactFromServiceArgs", + () => [ + { no: 1, name: "service_identifier", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "source_path", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message api_container_api.StoreFilesArtifactFromServiceResponse + */ +export const StoreFilesArtifactFromServiceResponse = proto3.makeMessageType( + "api_container_api.StoreFilesArtifactFromServiceResponse", + () => [ + { no: 1, name: "uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message api_container_api.FilesArtifactNameAndUuid + */ +export const FilesArtifactNameAndUuid = proto3.makeMessageType( + "api_container_api.FilesArtifactNameAndUuid", + () => [ + { no: 1, name: "fileName", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "fileUuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message api_container_api.ListFilesArtifactNamesAndUuidsResponse + */ +export const ListFilesArtifactNamesAndUuidsResponse = proto3.makeMessageType( + "api_container_api.ListFilesArtifactNamesAndUuidsResponse", + () => [ + { no: 1, name: "file_names_and_uuids", kind: "message", T: FilesArtifactNameAndUuid, repeated: true }, + ], +); + +/** + * @generated from message api_container_api.InspectFilesArtifactContentsRequest + */ +export const InspectFilesArtifactContentsRequest = proto3.makeMessageType( + "api_container_api.InspectFilesArtifactContentsRequest", + () => [ + { no: 1, name: "file_names_and_uuid", kind: "message", T: FilesArtifactNameAndUuid }, + ], +); + +/** + * @generated from message api_container_api.InspectFilesArtifactContentsResponse + */ +export const InspectFilesArtifactContentsResponse = proto3.makeMessageType( + "api_container_api.InspectFilesArtifactContentsResponse", + () => [ + { no: 1, name: "file_descriptions", kind: "message", T: FileArtifactContentsFileDescription, repeated: true }, + ], +); + +/** + * @generated from message api_container_api.FileArtifactContentsFileDescription + */ +export const FileArtifactContentsFileDescription = proto3.makeMessageType( + "api_container_api.FileArtifactContentsFileDescription", + () => [ + { no: 1, name: "path", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "size", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, + { no: 3, name: "text_preview", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + ], +); + +/** + * @generated from message api_container_api.ConnectServicesArgs + */ +export const ConnectServicesArgs = proto3.makeMessageType( + "api_container_api.ConnectServicesArgs", + () => [ + { no: 1, name: "connect", kind: "enum", T: proto3.getEnumType(Connect) }, + ], +); + +/** + * @generated from message api_container_api.ConnectServicesResponse + */ +export const ConnectServicesResponse = proto3.makeMessageType( + "api_container_api.ConnectServicesResponse", + [], +); + +/** + * @generated from message api_container_api.GetStarlarkRunResponse + */ +export const GetStarlarkRunResponse = proto3.makeMessageType( + "api_container_api.GetStarlarkRunResponse", + () => [ + { no: 1, name: "package_id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "serialized_script", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "serialized_params", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 4, name: "parallelism", kind: "scalar", T: 5 /* ScalarType.INT32 */ }, + { no: 5, name: "relative_path_to_main_file", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 6, name: "main_function_name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 7, name: "experimental_features", kind: "enum", T: proto3.getEnumType(KurtosisFeatureFlag), repeated: true }, + { no: 8, name: "restart_policy", kind: "enum", T: proto3.getEnumType(RestartPolicy) }, + { no: 9, name: "initial_serialized_params", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + ], +); + +/** + * @generated from message api_container_api.PlanYaml + */ +export const PlanYaml = proto3.makeMessageType( + "api_container_api.PlanYaml", + () => [ + { no: 1, name: "plan_yaml", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message api_container_api.StarlarkScriptPlanYamlArgs + */ +export const StarlarkScriptPlanYamlArgs = proto3.makeMessageType( + "api_container_api.StarlarkScriptPlanYamlArgs", + () => [ + { no: 1, name: "serialized_script", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "serialized_params", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 5, name: "main_function_name", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + ], +); + +/** + * @generated from message api_container_api.StarlarkPackagePlanYamlArgs + */ +export const StarlarkPackagePlanYamlArgs = proto3.makeMessageType( + "api_container_api.StarlarkPackagePlanYamlArgs", + () => [ + { no: 1, name: "package_id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "serialized_params", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 3, name: "relative_path_to_main_file", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 4, name: "main_function_name", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + ], +); + diff --git a/enclave-manager/api/typescript/src/engine_service_connect.d.ts b/enclave-manager/api/typescript/src/engine_service_connect.d.ts new file mode 100644 index 0000000000..ce3e6243db --- /dev/null +++ b/enclave-manager/api/typescript/src/engine_service_connect.d.ts @@ -0,0 +1,108 @@ +// @generated by protoc-gen-connect-es v1.4.0 with parameter "target=js+dts" +// @generated from file engine_service.proto (package engine_api, syntax proto3) +/* eslint-disable */ +// @ts-nocheck + +import { Empty, MethodKind } from "@bufbuild/protobuf"; +import { CleanArgs, CleanResponse, CreateEnclaveArgs, CreateEnclaveResponse, DestroyEnclaveArgs, GetEnclavesResponse, GetEngineInfoResponse, GetExistingAndHistoricalEnclaveIdentifiersResponse, GetServiceLogsArgs, GetServiceLogsResponse, StopEnclaveArgs } from "./engine_service_pb.js"; + +/** + * @generated from service engine_api.EngineService + */ +export declare const EngineService: { + readonly typeName: "engine_api.EngineService", + readonly methods: { + /** + * Endpoint for getting information about the engine, which is also what we use to verify that the engine has become available + * + * @generated from rpc engine_api.EngineService.GetEngineInfo + */ + readonly getEngineInfo: { + readonly name: "GetEngineInfo", + readonly I: typeof Empty, + readonly O: typeof GetEngineInfoResponse, + readonly kind: MethodKind.Unary, + }, + /** + * ============================================================================================== + * Enclave Management + * ============================================================================================== + * Creates a new Kurtosis Enclave + * + * @generated from rpc engine_api.EngineService.CreateEnclave + */ + readonly createEnclave: { + readonly name: "CreateEnclave", + readonly I: typeof CreateEnclaveArgs, + readonly O: typeof CreateEnclaveResponse, + readonly kind: MethodKind.Unary, + }, + /** + * Returns information about the existing enclaves + * + * @generated from rpc engine_api.EngineService.GetEnclaves + */ + readonly getEnclaves: { + readonly name: "GetEnclaves", + readonly I: typeof Empty, + readonly O: typeof GetEnclavesResponse, + readonly kind: MethodKind.Unary, + }, + /** + * Returns information about all existing & historical enclaves + * + * @generated from rpc engine_api.EngineService.GetExistingAndHistoricalEnclaveIdentifiers + */ + readonly getExistingAndHistoricalEnclaveIdentifiers: { + readonly name: "GetExistingAndHistoricalEnclaveIdentifiers", + readonly I: typeof Empty, + readonly O: typeof GetExistingAndHistoricalEnclaveIdentifiersResponse, + readonly kind: MethodKind.Unary, + }, + /** + * Stops all containers in an enclave + * + * @generated from rpc engine_api.EngineService.StopEnclave + */ + readonly stopEnclave: { + readonly name: "StopEnclave", + readonly I: typeof StopEnclaveArgs, + readonly O: typeof Empty, + readonly kind: MethodKind.Unary, + }, + /** + * Destroys an enclave, removing all artifacts associated with it + * + * @generated from rpc engine_api.EngineService.DestroyEnclave + */ + readonly destroyEnclave: { + readonly name: "DestroyEnclave", + readonly I: typeof DestroyEnclaveArgs, + readonly O: typeof Empty, + readonly kind: MethodKind.Unary, + }, + /** + * Gets rid of old enclaves + * + * @generated from rpc engine_api.EngineService.Clean + */ + readonly clean: { + readonly name: "Clean", + readonly I: typeof CleanArgs, + readonly O: typeof CleanResponse, + readonly kind: MethodKind.Unary, + }, + /** + * Get service logs + * + * @generated from rpc engine_api.EngineService.GetServiceLogs + */ + readonly getServiceLogs: { + readonly name: "GetServiceLogs", + readonly I: typeof GetServiceLogsArgs, + readonly O: typeof GetServiceLogsResponse, + readonly kind: MethodKind.ServerStreaming, + }, + } +}; + diff --git a/enclave-manager/api/typescript/src/engine_service_connect.js b/enclave-manager/api/typescript/src/engine_service_connect.js new file mode 100644 index 0000000000..bb1dc86e15 --- /dev/null +++ b/enclave-manager/api/typescript/src/engine_service_connect.js @@ -0,0 +1,108 @@ +// @generated by protoc-gen-connect-es v1.4.0 with parameter "target=js+dts" +// @generated from file engine_service.proto (package engine_api, syntax proto3) +/* eslint-disable */ +// @ts-nocheck + +import { Empty, MethodKind } from "@bufbuild/protobuf"; +import { CleanArgs, CleanResponse, CreateEnclaveArgs, CreateEnclaveResponse, DestroyEnclaveArgs, GetEnclavesResponse, GetEngineInfoResponse, GetExistingAndHistoricalEnclaveIdentifiersResponse, GetServiceLogsArgs, GetServiceLogsResponse, StopEnclaveArgs } from "./engine_service_pb.js"; + +/** + * @generated from service engine_api.EngineService + */ +export const EngineService = { + typeName: "engine_api.EngineService", + methods: { + /** + * Endpoint for getting information about the engine, which is also what we use to verify that the engine has become available + * + * @generated from rpc engine_api.EngineService.GetEngineInfo + */ + getEngineInfo: { + name: "GetEngineInfo", + I: Empty, + O: GetEngineInfoResponse, + kind: MethodKind.Unary, + }, + /** + * ============================================================================================== + * Enclave Management + * ============================================================================================== + * Creates a new Kurtosis Enclave + * + * @generated from rpc engine_api.EngineService.CreateEnclave + */ + createEnclave: { + name: "CreateEnclave", + I: CreateEnclaveArgs, + O: CreateEnclaveResponse, + kind: MethodKind.Unary, + }, + /** + * Returns information about the existing enclaves + * + * @generated from rpc engine_api.EngineService.GetEnclaves + */ + getEnclaves: { + name: "GetEnclaves", + I: Empty, + O: GetEnclavesResponse, + kind: MethodKind.Unary, + }, + /** + * Returns information about all existing & historical enclaves + * + * @generated from rpc engine_api.EngineService.GetExistingAndHistoricalEnclaveIdentifiers + */ + getExistingAndHistoricalEnclaveIdentifiers: { + name: "GetExistingAndHistoricalEnclaveIdentifiers", + I: Empty, + O: GetExistingAndHistoricalEnclaveIdentifiersResponse, + kind: MethodKind.Unary, + }, + /** + * Stops all containers in an enclave + * + * @generated from rpc engine_api.EngineService.StopEnclave + */ + stopEnclave: { + name: "StopEnclave", + I: StopEnclaveArgs, + O: Empty, + kind: MethodKind.Unary, + }, + /** + * Destroys an enclave, removing all artifacts associated with it + * + * @generated from rpc engine_api.EngineService.DestroyEnclave + */ + destroyEnclave: { + name: "DestroyEnclave", + I: DestroyEnclaveArgs, + O: Empty, + kind: MethodKind.Unary, + }, + /** + * Gets rid of old enclaves + * + * @generated from rpc engine_api.EngineService.Clean + */ + clean: { + name: "Clean", + I: CleanArgs, + O: CleanResponse, + kind: MethodKind.Unary, + }, + /** + * Get service logs + * + * @generated from rpc engine_api.EngineService.GetServiceLogs + */ + getServiceLogs: { + name: "GetServiceLogs", + I: GetServiceLogsArgs, + O: GetServiceLogsResponse, + kind: MethodKind.ServerStreaming, + }, + } +}; + diff --git a/enclave-manager/api/typescript/src/engine_service_pb.d.ts b/enclave-manager/api/typescript/src/engine_service_pb.d.ts new file mode 100644 index 0000000000..7eb383b09a --- /dev/null +++ b/enclave-manager/api/typescript/src/engine_service_pb.d.ts @@ -0,0 +1,786 @@ +// @generated by protoc-gen-es v1.3.1 with parameter "target=js+dts" +// @generated from file engine_service.proto (package engine_api, syntax proto3) +/* eslint-disable */ +// @ts-nocheck + +import type { BinaryReadOptions, FieldList, JsonReadOptions, JsonValue, PartialMessage, PlainMessage, Timestamp } from "@bufbuild/protobuf"; +import { Message, proto3 } from "@bufbuild/protobuf"; + +/** + * @generated from enum engine_api.EnclaveMode + */ +export declare enum EnclaveMode { + /** + * @generated from enum value: TEST = 0; + */ + TEST = 0, + + /** + * @generated from enum value: PRODUCTION = 1; + */ + PRODUCTION = 1, +} + +/** + * ============================================================================================== + * Get Enclaves + * ============================================================================================== + * Status of the containers in the enclave + * NOTE: We have to prefix the enum values with the enum name due to the way Protobuf enum valuee uniqueness works + * + * @generated from enum engine_api.EnclaveContainersStatus + */ +export declare enum EnclaveContainersStatus { + /** + * The enclave has been created, but there are no containers inside it + * + * @generated from enum value: EnclaveContainersStatus_EMPTY = 0; + */ + EnclaveContainersStatus_EMPTY = 0, + + /** + * One or more containers are running in the enclave (which may or may not include the API container, depending on if the user was manually stopping/removing containers) + * + * @generated from enum value: EnclaveContainersStatus_RUNNING = 1; + */ + EnclaveContainersStatus_RUNNING = 1, + + /** + * There are >= 1 container in the enclave, but they're all stopped + * + * @generated from enum value: EnclaveContainersStatus_STOPPED = 2; + */ + EnclaveContainersStatus_STOPPED = 2, +} + +/** + * NOTE: We have to prefix the enum values with the enum name due to the way Protobuf enum value uniqueness works + * + * @generated from enum engine_api.EnclaveAPIContainerStatus + */ +export declare enum EnclaveAPIContainerStatus { + /** + * No API container exists in the enclave + * This is the only valid value when the enclave containers status is "EMPTY" + * + * @generated from enum value: EnclaveAPIContainerStatus_NONEXISTENT = 0; + */ + EnclaveAPIContainerStatus_NONEXISTENT = 0, + + /** + * An API container exists and is running + * NOTE: this does NOT say that the server inside the API container is available, because checking if it's available requires making a call to the API container + * If we have a lot of API containers, we'd be making tons of calls + * + * @generated from enum value: EnclaveAPIContainerStatus_RUNNING = 1; + */ + EnclaveAPIContainerStatus_RUNNING = 1, + + /** + * An API container exists, but isn't running + * + * @generated from enum value: EnclaveAPIContainerStatus_STOPPED = 2; + */ + EnclaveAPIContainerStatus_STOPPED = 2, +} + +/** + * The filter operator which can be text or regex type + * NOTE: We have to prefix the enum values with the enum name due to the way Protobuf enum value uniqueness works + * + * @generated from enum engine_api.LogLineOperator + */ +export declare enum LogLineOperator { + /** + * @generated from enum value: LogLineOperator_DOES_CONTAIN_TEXT = 0; + */ + LogLineOperator_DOES_CONTAIN_TEXT = 0, + + /** + * @generated from enum value: LogLineOperator_DOES_NOT_CONTAIN_TEXT = 1; + */ + LogLineOperator_DOES_NOT_CONTAIN_TEXT = 1, + + /** + * @generated from enum value: LogLineOperator_DOES_CONTAIN_MATCH_REGEX = 2; + */ + LogLineOperator_DOES_CONTAIN_MATCH_REGEX = 2, + + /** + * @generated from enum value: LogLineOperator_DOES_NOT_CONTAIN_MATCH_REGEX = 3; + */ + LogLineOperator_DOES_NOT_CONTAIN_MATCH_REGEX = 3, +} + +/** + * ============================================================================================== + * Get Engine Info + * ============================================================================================== + * + * @generated from message engine_api.GetEngineInfoResponse + */ +export declare class GetEngineInfoResponse extends Message { + /** + * Version of the engine server + * + * @generated from field: string engine_version = 1; + */ + engineVersion: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.GetEngineInfoResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): GetEngineInfoResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): GetEngineInfoResponse; + + static fromJsonString(jsonString: string, options?: Partial): GetEngineInfoResponse; + + static equals(a: GetEngineInfoResponse | PlainMessage | undefined, b: GetEngineInfoResponse | PlainMessage | undefined): boolean; +} + +/** + * ============================================================================================== + * Create Enclave + * ============================================================================================== + * + * @generated from message engine_api.CreateEnclaveArgs + */ +export declare class CreateEnclaveArgs extends Message { + /** + * The name of the new Kurtosis Enclave + * + * @generated from field: optional string enclave_name = 1; + */ + enclaveName?: string; + + /** + * The image tag of the API container that should be used inside the enclave + * If blank, will use the default version that the engine server uses + * + * @generated from field: optional string api_container_version_tag = 2; + */ + apiContainerVersionTag?: string; + + /** + * The API container log level + * + * @generated from field: optional string api_container_log_level = 3; + */ + apiContainerLogLevel?: string; + + /** + * @generated from field: optional engine_api.EnclaveMode mode = 4; + */ + mode?: EnclaveMode; + + /** + * Whether the APIC's container should run with the debug server to receive a remote debug connection + * This is not an EnclaveMode because we will need to debug both current Modes (Test and Prod) + * + * @generated from field: optional bool should_apic_run_in_debug_mode = 5; + */ + shouldApicRunInDebugMode?: boolean; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.CreateEnclaveArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): CreateEnclaveArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): CreateEnclaveArgs; + + static fromJsonString(jsonString: string, options?: Partial): CreateEnclaveArgs; + + static equals(a: CreateEnclaveArgs | PlainMessage | undefined, b: CreateEnclaveArgs | PlainMessage | undefined): boolean; +} + +/** + * @generated from message engine_api.CreateEnclaveResponse + */ +export declare class CreateEnclaveResponse extends Message { + /** + * All the enclave information inside this object + * + * @generated from field: engine_api.EnclaveInfo enclave_info = 1; + */ + enclaveInfo?: EnclaveInfo; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.CreateEnclaveResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): CreateEnclaveResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): CreateEnclaveResponse; + + static fromJsonString(jsonString: string, options?: Partial): CreateEnclaveResponse; + + static equals(a: CreateEnclaveResponse | PlainMessage | undefined, b: CreateEnclaveResponse | PlainMessage | undefined): boolean; +} + +/** + * @generated from message engine_api.EnclaveAPIContainerInfo + */ +export declare class EnclaveAPIContainerInfo extends Message { + /** + * The container engine ID of the API container + * + * @generated from field: string container_id = 1; + */ + containerId: string; + + /** + * The IP inside the enclave network of the API container (i.e. how services inside the network can reach the API container) + * + * @generated from field: string ip_inside_enclave = 2; + */ + ipInsideEnclave: string; + + /** + * The grpc port inside the enclave network that the API container is listening on + * + * @generated from field: uint32 grpc_port_inside_enclave = 3; + */ + grpcPortInsideEnclave: number; + + /** + * this is the bridge ip address that gets assigned to api container + * + * @generated from field: string bridge_ip_address = 6; + */ + bridgeIpAddress: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.EnclaveAPIContainerInfo"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): EnclaveAPIContainerInfo; + + static fromJson(jsonValue: JsonValue, options?: Partial): EnclaveAPIContainerInfo; + + static fromJsonString(jsonString: string, options?: Partial): EnclaveAPIContainerInfo; + + static equals(a: EnclaveAPIContainerInfo | PlainMessage | undefined, b: EnclaveAPIContainerInfo | PlainMessage | undefined): boolean; +} + +/** + * Will only be present if the API container is running + * + * @generated from message engine_api.EnclaveAPIContainerHostMachineInfo + */ +export declare class EnclaveAPIContainerHostMachineInfo extends Message { + /** + * The interface IP on the container engine host machine where the API container can be reached + * + * @generated from field: string ip_on_host_machine = 4; + */ + ipOnHostMachine: string; + + /** + * The grpc port on the container engine host machine where the API container can be reached + * + * @generated from field: uint32 grpc_port_on_host_machine = 5; + */ + grpcPortOnHostMachine: number; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.EnclaveAPIContainerHostMachineInfo"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): EnclaveAPIContainerHostMachineInfo; + + static fromJson(jsonValue: JsonValue, options?: Partial): EnclaveAPIContainerHostMachineInfo; + + static fromJsonString(jsonString: string, options?: Partial): EnclaveAPIContainerHostMachineInfo; + + static equals(a: EnclaveAPIContainerHostMachineInfo | PlainMessage | undefined, b: EnclaveAPIContainerHostMachineInfo | PlainMessage | undefined): boolean; +} + +/** + * Enclaves are defined by a network in the container system, which is why there's a bunch of network information here + * + * @generated from message engine_api.EnclaveInfo + */ +export declare class EnclaveInfo extends Message { + /** + * UUID of the enclave + * + * @generated from field: string enclave_uuid = 1; + */ + enclaveUuid: string; + + /** + * Name of the enclave + * + * @generated from field: string name = 2; + */ + name: string; + + /** + * The shortened uuid of the enclave + * + * @generated from field: string shortened_uuid = 3; + */ + shortenedUuid: string; + + /** + * State of all containers in the enclave + * + * @generated from field: engine_api.EnclaveContainersStatus containers_status = 4; + */ + containersStatus: EnclaveContainersStatus; + + /** + * State specifically of the API container + * + * @generated from field: engine_api.EnclaveAPIContainerStatus api_container_status = 5; + */ + apiContainerStatus: EnclaveAPIContainerStatus; + + /** + * NOTE: Will not be present if the API container status is "NONEXISTENT"!! + * + * @generated from field: engine_api.EnclaveAPIContainerInfo api_container_info = 6; + */ + apiContainerInfo?: EnclaveAPIContainerInfo; + + /** + * NOTE: Will not be present if the API container status is not "RUNNING"!! + * + * @generated from field: engine_api.EnclaveAPIContainerHostMachineInfo api_container_host_machine_info = 7; + */ + apiContainerHostMachineInfo?: EnclaveAPIContainerHostMachineInfo; + + /** + * The enclave's creation time + * + * @generated from field: google.protobuf.Timestamp creation_time = 8; + */ + creationTime?: Timestamp; + + /** + * @generated from field: engine_api.EnclaveMode mode = 9; + */ + mode: EnclaveMode; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.EnclaveInfo"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): EnclaveInfo; + + static fromJson(jsonValue: JsonValue, options?: Partial): EnclaveInfo; + + static fromJsonString(jsonString: string, options?: Partial): EnclaveInfo; + + static equals(a: EnclaveInfo | PlainMessage | undefined, b: EnclaveInfo | PlainMessage | undefined): boolean; +} + +/** + * @generated from message engine_api.GetEnclavesResponse + */ +export declare class GetEnclavesResponse extends Message { + /** + * Mapping of enclave_uuid -> info_about_enclave + * + * @generated from field: map enclave_info = 1; + */ + enclaveInfo: { [key: string]: EnclaveInfo }; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.GetEnclavesResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): GetEnclavesResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): GetEnclavesResponse; + + static fromJsonString(jsonString: string, options?: Partial): GetEnclavesResponse; + + static equals(a: GetEnclavesResponse | PlainMessage | undefined, b: GetEnclavesResponse | PlainMessage | undefined): boolean; +} + +/** + * An enclave identifier is a collection of uuid, name and shortened uuid + * + * @generated from message engine_api.EnclaveIdentifiers + */ +export declare class EnclaveIdentifiers extends Message { + /** + * UUID of the enclave + * + * @generated from field: string enclave_uuid = 1; + */ + enclaveUuid: string; + + /** + * Name of the enclave + * + * @generated from field: string name = 2; + */ + name: string; + + /** + * The shortened uuid of the enclave + * + * @generated from field: string shortened_uuid = 3; + */ + shortenedUuid: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.EnclaveIdentifiers"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): EnclaveIdentifiers; + + static fromJson(jsonValue: JsonValue, options?: Partial): EnclaveIdentifiers; + + static fromJsonString(jsonString: string, options?: Partial): EnclaveIdentifiers; + + static equals(a: EnclaveIdentifiers | PlainMessage | undefined, b: EnclaveIdentifiers | PlainMessage | undefined): boolean; +} + +/** + * @generated from message engine_api.GetExistingAndHistoricalEnclaveIdentifiersResponse + */ +export declare class GetExistingAndHistoricalEnclaveIdentifiersResponse extends Message { + /** + * @generated from field: repeated engine_api.EnclaveIdentifiers allIdentifiers = 1; + */ + allIdentifiers: EnclaveIdentifiers[]; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.GetExistingAndHistoricalEnclaveIdentifiersResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): GetExistingAndHistoricalEnclaveIdentifiersResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): GetExistingAndHistoricalEnclaveIdentifiersResponse; + + static fromJsonString(jsonString: string, options?: Partial): GetExistingAndHistoricalEnclaveIdentifiersResponse; + + static equals(a: GetExistingAndHistoricalEnclaveIdentifiersResponse | PlainMessage | undefined, b: GetExistingAndHistoricalEnclaveIdentifiersResponse | PlainMessage | undefined): boolean; +} + +/** + * ============================================================================================== + * Stop Enclave + * ============================================================================================== + * + * @generated from message engine_api.StopEnclaveArgs + */ +export declare class StopEnclaveArgs extends Message { + /** + * The identifier(uuid, shortened uuid, name) of the Kurtosis enclave to stop + * + * @generated from field: string enclave_identifier = 1; + */ + enclaveIdentifier: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.StopEnclaveArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): StopEnclaveArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): StopEnclaveArgs; + + static fromJsonString(jsonString: string, options?: Partial): StopEnclaveArgs; + + static equals(a: StopEnclaveArgs | PlainMessage | undefined, b: StopEnclaveArgs | PlainMessage | undefined): boolean; +} + +/** + * ============================================================================================== + * Destroy Enclave + * ============================================================================================== + * + * @generated from message engine_api.DestroyEnclaveArgs + */ +export declare class DestroyEnclaveArgs extends Message { + /** + * The identifier(uuid, shortened uuid, name) of the Kurtosis enclave to destroy + * + * @generated from field: string enclave_identifier = 1; + */ + enclaveIdentifier: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.DestroyEnclaveArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): DestroyEnclaveArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): DestroyEnclaveArgs; + + static fromJsonString(jsonString: string, options?: Partial): DestroyEnclaveArgs; + + static equals(a: DestroyEnclaveArgs | PlainMessage | undefined, b: DestroyEnclaveArgs | PlainMessage | undefined): boolean; +} + +/** + * ============================================================================================== + * Create Enclave + * ============================================================================================== + * + * @generated from message engine_api.CleanArgs + */ +export declare class CleanArgs extends Message { + /** + * If true, It will clean even the running enclaves + * + * @generated from field: optional bool should_clean_all = 1; + */ + shouldCleanAll?: boolean; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.CleanArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): CleanArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): CleanArgs; + + static fromJsonString(jsonString: string, options?: Partial): CleanArgs; + + static equals(a: CleanArgs | PlainMessage | undefined, b: CleanArgs | PlainMessage | undefined): boolean; +} + +/** + * @generated from message engine_api.EnclaveNameAndUuid + */ +export declare class EnclaveNameAndUuid extends Message { + /** + * @generated from field: string name = 1; + */ + name: string; + + /** + * @generated from field: string uuid = 2; + */ + uuid: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.EnclaveNameAndUuid"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): EnclaveNameAndUuid; + + static fromJson(jsonValue: JsonValue, options?: Partial): EnclaveNameAndUuid; + + static fromJsonString(jsonString: string, options?: Partial): EnclaveNameAndUuid; + + static equals(a: EnclaveNameAndUuid | PlainMessage | undefined, b: EnclaveNameAndUuid | PlainMessage | undefined): boolean; +} + +/** + * @generated from message engine_api.CleanResponse + */ +export declare class CleanResponse extends Message { + /** + * removed enclave name and uuids + * + * @generated from field: repeated engine_api.EnclaveNameAndUuid removed_enclave_name_and_uuids = 1; + */ + removedEnclaveNameAndUuids: EnclaveNameAndUuid[]; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.CleanResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): CleanResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): CleanResponse; + + static fromJsonString(jsonString: string, options?: Partial): CleanResponse; + + static equals(a: CleanResponse | PlainMessage | undefined, b: CleanResponse | PlainMessage | undefined): boolean; +} + +/** + * ============================================================================================== + * Get User Service Logs + * ============================================================================================== + * + * @generated from message engine_api.GetServiceLogsArgs + */ +export declare class GetServiceLogsArgs extends Message { + /** + * The identifier of the user service's Kurtosis Enclave + * + * @generated from field: string enclave_identifier = 1; + */ + enclaveIdentifier: string; + + /** + * "Set" of service UUIDs in the enclave + * + * @generated from field: map service_uuid_set = 2; + */ + serviceUuidSet: { [key: string]: boolean }; + + /** + * If true, It will follow the container logs + * + * @generated from field: optional bool follow_logs = 3; + */ + followLogs?: boolean; + + /** + * The conjunctive log lines filters, the first filter is applied over the found log lines, the second filter is applied over the filter one result and so on (like grep) + * + * @generated from field: repeated engine_api.LogLineFilter conjunctive_filters = 4; + */ + conjunctiveFilters: LogLineFilter[]; + + /** + * If true, return all log lines + * + * @generated from field: optional bool return_all_logs = 5; + */ + returnAllLogs?: boolean; + + /** + * If [return_all_logs] is false, return [num_log_lines] + * + * @generated from field: optional uint32 num_log_lines = 6; + */ + numLogLines?: number; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.GetServiceLogsArgs"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): GetServiceLogsArgs; + + static fromJson(jsonValue: JsonValue, options?: Partial): GetServiceLogsArgs; + + static fromJsonString(jsonString: string, options?: Partial): GetServiceLogsArgs; + + static equals(a: GetServiceLogsArgs | PlainMessage | undefined, b: GetServiceLogsArgs | PlainMessage | undefined): boolean; +} + +/** + * @generated from message engine_api.GetServiceLogsResponse + */ +export declare class GetServiceLogsResponse extends Message { + /** + * The service log lines grouped by service UUIDs and ordered in forward direction (oldest log line is the first element) + * + * @generated from field: map service_logs_by_service_uuid = 1; + */ + serviceLogsByServiceUuid: { [key: string]: LogLine }; + + /** + * A set of service GUIDs requested by the user that were not found in the logs database, could be related that users send + * a wrong GUID or a right GUID for a service that has not sent any logs so far + * + * @generated from field: map not_found_service_uuid_set = 2; + */ + notFoundServiceUuidSet: { [key: string]: boolean }; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.GetServiceLogsResponse"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): GetServiceLogsResponse; + + static fromJson(jsonValue: JsonValue, options?: Partial): GetServiceLogsResponse; + + static fromJsonString(jsonString: string, options?: Partial): GetServiceLogsResponse; + + static equals(a: GetServiceLogsResponse | PlainMessage | undefined, b: GetServiceLogsResponse | PlainMessage | undefined): boolean; +} + +/** + * @generated from message engine_api.LogLine + */ +export declare class LogLine extends Message { + /** + * @generated from field: repeated string line = 1; + */ + line: string[]; + + /** + * @generated from field: google.protobuf.Timestamp timestamp = 2; + */ + timestamp?: Timestamp; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.LogLine"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): LogLine; + + static fromJson(jsonValue: JsonValue, options?: Partial): LogLine; + + static fromJsonString(jsonString: string, options?: Partial): LogLine; + + static equals(a: LogLine | PlainMessage | undefined, b: LogLine | PlainMessage | undefined): boolean; +} + +/** + * @generated from message engine_api.LogLineFilter + */ +export declare class LogLineFilter extends Message { + /** + * @generated from field: engine_api.LogLineOperator operator = 1; + */ + operator: LogLineOperator; + + /** + * @generated from field: string text_pattern = 2; + */ + textPattern: string; + + constructor(data?: PartialMessage); + + static readonly runtime: typeof proto3; + static readonly typeName = "engine_api.LogLineFilter"; + static readonly fields: FieldList; + + static fromBinary(bytes: Uint8Array, options?: Partial): LogLineFilter; + + static fromJson(jsonValue: JsonValue, options?: Partial): LogLineFilter; + + static fromJsonString(jsonString: string, options?: Partial): LogLineFilter; + + static equals(a: LogLineFilter | PlainMessage | undefined, b: LogLineFilter | PlainMessage | undefined): boolean; +} + diff --git a/enclave-manager/api/typescript/src/engine_service_pb.js b/enclave-manager/api/typescript/src/engine_service_pb.js new file mode 100644 index 0000000000..c245f62078 --- /dev/null +++ b/enclave-manager/api/typescript/src/engine_service_pb.js @@ -0,0 +1,303 @@ +// @generated by protoc-gen-es v1.3.1 with parameter "target=js+dts" +// @generated from file engine_service.proto (package engine_api, syntax proto3) +/* eslint-disable */ +// @ts-nocheck + +import { proto3, Timestamp } from "@bufbuild/protobuf"; + +/** + * @generated from enum engine_api.EnclaveMode + */ +export const EnclaveMode = proto3.makeEnum( + "engine_api.EnclaveMode", + [ + {no: 0, name: "TEST"}, + {no: 1, name: "PRODUCTION"}, + ], +); + +/** + * ============================================================================================== + * Get Enclaves + * ============================================================================================== + * Status of the containers in the enclave + * NOTE: We have to prefix the enum values with the enum name due to the way Protobuf enum valuee uniqueness works + * + * @generated from enum engine_api.EnclaveContainersStatus + */ +export const EnclaveContainersStatus = proto3.makeEnum( + "engine_api.EnclaveContainersStatus", + [ + {no: 0, name: "EnclaveContainersStatus_EMPTY"}, + {no: 1, name: "EnclaveContainersStatus_RUNNING"}, + {no: 2, name: "EnclaveContainersStatus_STOPPED"}, + ], +); + +/** + * NOTE: We have to prefix the enum values with the enum name due to the way Protobuf enum value uniqueness works + * + * @generated from enum engine_api.EnclaveAPIContainerStatus + */ +export const EnclaveAPIContainerStatus = proto3.makeEnum( + "engine_api.EnclaveAPIContainerStatus", + [ + {no: 0, name: "EnclaveAPIContainerStatus_NONEXISTENT"}, + {no: 1, name: "EnclaveAPIContainerStatus_RUNNING"}, + {no: 2, name: "EnclaveAPIContainerStatus_STOPPED"}, + ], +); + +/** + * The filter operator which can be text or regex type + * NOTE: We have to prefix the enum values with the enum name due to the way Protobuf enum value uniqueness works + * + * @generated from enum engine_api.LogLineOperator + */ +export const LogLineOperator = proto3.makeEnum( + "engine_api.LogLineOperator", + [ + {no: 0, name: "LogLineOperator_DOES_CONTAIN_TEXT"}, + {no: 1, name: "LogLineOperator_DOES_NOT_CONTAIN_TEXT"}, + {no: 2, name: "LogLineOperator_DOES_CONTAIN_MATCH_REGEX"}, + {no: 3, name: "LogLineOperator_DOES_NOT_CONTAIN_MATCH_REGEX"}, + ], +); + +/** + * ============================================================================================== + * Get Engine Info + * ============================================================================================== + * + * @generated from message engine_api.GetEngineInfoResponse + */ +export const GetEngineInfoResponse = proto3.makeMessageType( + "engine_api.GetEngineInfoResponse", + () => [ + { no: 1, name: "engine_version", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * ============================================================================================== + * Create Enclave + * ============================================================================================== + * + * @generated from message engine_api.CreateEnclaveArgs + */ +export const CreateEnclaveArgs = proto3.makeMessageType( + "engine_api.CreateEnclaveArgs", + () => [ + { no: 1, name: "enclave_name", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 2, name: "api_container_version_tag", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 3, name: "api_container_log_level", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 4, name: "mode", kind: "enum", T: proto3.getEnumType(EnclaveMode), opt: true }, + { no: 5, name: "should_apic_run_in_debug_mode", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true }, + ], +); + +/** + * @generated from message engine_api.CreateEnclaveResponse + */ +export const CreateEnclaveResponse = proto3.makeMessageType( + "engine_api.CreateEnclaveResponse", + () => [ + { no: 1, name: "enclave_info", kind: "message", T: EnclaveInfo }, + ], +); + +/** + * @generated from message engine_api.EnclaveAPIContainerInfo + */ +export const EnclaveAPIContainerInfo = proto3.makeMessageType( + "engine_api.EnclaveAPIContainerInfo", + () => [ + { no: 1, name: "container_id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "ip_inside_enclave", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "grpc_port_inside_enclave", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, + { no: 6, name: "bridge_ip_address", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * Will only be present if the API container is running + * + * @generated from message engine_api.EnclaveAPIContainerHostMachineInfo + */ +export const EnclaveAPIContainerHostMachineInfo = proto3.makeMessageType( + "engine_api.EnclaveAPIContainerHostMachineInfo", + () => [ + { no: 4, name: "ip_on_host_machine", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 5, name: "grpc_port_on_host_machine", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, + ], +); + +/** + * Enclaves are defined by a network in the container system, which is why there's a bunch of network information here + * + * @generated from message engine_api.EnclaveInfo + */ +export const EnclaveInfo = proto3.makeMessageType( + "engine_api.EnclaveInfo", + () => [ + { no: 1, name: "enclave_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "shortened_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 4, name: "containers_status", kind: "enum", T: proto3.getEnumType(EnclaveContainersStatus) }, + { no: 5, name: "api_container_status", kind: "enum", T: proto3.getEnumType(EnclaveAPIContainerStatus) }, + { no: 6, name: "api_container_info", kind: "message", T: EnclaveAPIContainerInfo }, + { no: 7, name: "api_container_host_machine_info", kind: "message", T: EnclaveAPIContainerHostMachineInfo }, + { no: 8, name: "creation_time", kind: "message", T: Timestamp }, + { no: 9, name: "mode", kind: "enum", T: proto3.getEnumType(EnclaveMode) }, + ], +); + +/** + * @generated from message engine_api.GetEnclavesResponse + */ +export const GetEnclavesResponse = proto3.makeMessageType( + "engine_api.GetEnclavesResponse", + () => [ + { no: 1, name: "enclave_info", kind: "map", K: 9 /* ScalarType.STRING */, V: {kind: "message", T: EnclaveInfo} }, + ], +); + +/** + * An enclave identifier is a collection of uuid, name and shortened uuid + * + * @generated from message engine_api.EnclaveIdentifiers + */ +export const EnclaveIdentifiers = proto3.makeMessageType( + "engine_api.EnclaveIdentifiers", + () => [ + { no: 1, name: "enclave_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "shortened_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message engine_api.GetExistingAndHistoricalEnclaveIdentifiersResponse + */ +export const GetExistingAndHistoricalEnclaveIdentifiersResponse = proto3.makeMessageType( + "engine_api.GetExistingAndHistoricalEnclaveIdentifiersResponse", + () => [ + { no: 1, name: "allIdentifiers", kind: "message", T: EnclaveIdentifiers, repeated: true }, + ], +); + +/** + * ============================================================================================== + * Stop Enclave + * ============================================================================================== + * + * @generated from message engine_api.StopEnclaveArgs + */ +export const StopEnclaveArgs = proto3.makeMessageType( + "engine_api.StopEnclaveArgs", + () => [ + { no: 1, name: "enclave_identifier", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * ============================================================================================== + * Destroy Enclave + * ============================================================================================== + * + * @generated from message engine_api.DestroyEnclaveArgs + */ +export const DestroyEnclaveArgs = proto3.makeMessageType( + "engine_api.DestroyEnclaveArgs", + () => [ + { no: 1, name: "enclave_identifier", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * ============================================================================================== + * Create Enclave + * ============================================================================================== + * + * @generated from message engine_api.CleanArgs + */ +export const CleanArgs = proto3.makeMessageType( + "engine_api.CleanArgs", + () => [ + { no: 1, name: "should_clean_all", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true }, + ], +); + +/** + * @generated from message engine_api.EnclaveNameAndUuid + */ +export const EnclaveNameAndUuid = proto3.makeMessageType( + "engine_api.EnclaveNameAndUuid", + () => [ + { no: 1, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + +/** + * @generated from message engine_api.CleanResponse + */ +export const CleanResponse = proto3.makeMessageType( + "engine_api.CleanResponse", + () => [ + { no: 1, name: "removed_enclave_name_and_uuids", kind: "message", T: EnclaveNameAndUuid, repeated: true }, + ], +); + +/** + * ============================================================================================== + * Get User Service Logs + * ============================================================================================== + * + * @generated from message engine_api.GetServiceLogsArgs + */ +export const GetServiceLogsArgs = proto3.makeMessageType( + "engine_api.GetServiceLogsArgs", + () => [ + { no: 1, name: "enclave_identifier", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "service_uuid_set", kind: "map", K: 9 /* ScalarType.STRING */, V: {kind: "scalar", T: 8 /* ScalarType.BOOL */} }, + { no: 3, name: "follow_logs", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true }, + { no: 4, name: "conjunctive_filters", kind: "message", T: LogLineFilter, repeated: true }, + { no: 5, name: "return_all_logs", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true }, + { no: 6, name: "num_log_lines", kind: "scalar", T: 13 /* ScalarType.UINT32 */, opt: true }, + ], +); + +/** + * @generated from message engine_api.GetServiceLogsResponse + */ +export const GetServiceLogsResponse = proto3.makeMessageType( + "engine_api.GetServiceLogsResponse", + () => [ + { no: 1, name: "service_logs_by_service_uuid", kind: "map", K: 9 /* ScalarType.STRING */, V: {kind: "message", T: LogLine} }, + { no: 2, name: "not_found_service_uuid_set", kind: "map", K: 9 /* ScalarType.STRING */, V: {kind: "scalar", T: 8 /* ScalarType.BOOL */} }, + ], +); + +/** + * @generated from message engine_api.LogLine + */ +export const LogLine = proto3.makeMessageType( + "engine_api.LogLine", + () => [ + { no: 1, name: "line", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true }, + { no: 2, name: "timestamp", kind: "message", T: Timestamp }, + ], +); + +/** + * @generated from message engine_api.LogLineFilter + */ +export const LogLineFilter = proto3.makeMessageType( + "engine_api.LogLineFilter", + () => [ + { no: 1, name: "operator", kind: "enum", T: proto3.getEnumType(LogLineOperator) }, + { no: 2, name: "text_pattern", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ], +); + diff --git a/enclave-manager/api/typescript/src/kurtosis_backend_server_api_connect.ts b/enclave-manager/api/typescript/src/kurtosis_backend_server_api_connect.ts new file mode 100644 index 0000000000..d132d2a877 --- /dev/null +++ b/enclave-manager/api/typescript/src/kurtosis_backend_server_api_connect.ts @@ -0,0 +1,209 @@ +// @generated by protoc-gen-connect-es v1.4.0 with parameter "target=ts" +// @generated from file kurtosis_backend_server_api.proto (package kurtosis_cloud, syntax proto3) +/* eslint-disable */ +// @ts-nocheck + +import { Empty, MethodIdempotency, MethodKind } from "@bufbuild/protobuf"; +import { AddAliasRequest, CancelPaymentSubscriptionArgs, ChangeUserActiveRequest, CheckPortAuthorizationRequest, DeleteAliasRequest, DeleteInstancesRequest, DeleteInstancesResponse, GetCloudInstanceConfigArgs, GetCloudInstanceConfigResponse, GetInstancesResponse, GetOrCreateApiKeyRequest, GetOrCreateApiKeyResponse, GetOrCreateInstanceRequest, GetOrCreateInstanceResponse, GetOrCreatePaymentConfigArgs, GetOrCreatePaymentConfigResponse, GetPortsRequest, GetPortsResponse, GetUnlockedPortsRequest, GetUnlockedPortsResponse, GetUserRequest, GetUserResponse, IsNewKurtosisVersionAvailableRequest, IsNewKurtosisVersionAvailableResponse, LockPortRequest, RefreshDefaultPaymentMethodArgs, UnlockPortRequest, UpdateAddressArgs, UpgradeKurtosisVersionRequest } from "./kurtosis_backend_server_api_pb.js"; + +/** + * @generated from service kurtosis_cloud.KurtosisCloudBackendServer + */ +export const KurtosisCloudBackendServer = { + typeName: "kurtosis_cloud.KurtosisCloudBackendServer", + methods: { + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.IsAvailable + */ + isAvailable: { + name: "IsAvailable", + I: Empty, + O: Empty, + kind: MethodKind.Unary, + idempotency: MethodIdempotency.NoSideEffects, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.GetCloudInstanceConfig + */ + getCloudInstanceConfig: { + name: "GetCloudInstanceConfig", + I: GetCloudInstanceConfigArgs, + O: GetCloudInstanceConfigResponse, + kind: MethodKind.Unary, + idempotency: MethodIdempotency.NoSideEffects, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.GetOrCreateApiKey + */ + getOrCreateApiKey: { + name: "GetOrCreateApiKey", + I: GetOrCreateApiKeyRequest, + O: GetOrCreateApiKeyResponse, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.GetOrCreateInstance + */ + getOrCreateInstance: { + name: "GetOrCreateInstance", + I: GetOrCreateInstanceRequest, + O: GetOrCreateInstanceResponse, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.GetOrCreatePaymentConfig + */ + getOrCreatePaymentConfig: { + name: "GetOrCreatePaymentConfig", + I: GetOrCreatePaymentConfigArgs, + O: GetOrCreatePaymentConfigResponse, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.RefreshDefaultPaymentMethod + */ + refreshDefaultPaymentMethod: { + name: "RefreshDefaultPaymentMethod", + I: RefreshDefaultPaymentMethodArgs, + O: Empty, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.CancelPaymentSubscription + */ + cancelPaymentSubscription: { + name: "CancelPaymentSubscription", + I: CancelPaymentSubscriptionArgs, + O: Empty, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.UpdateAddress + */ + updateAddress: { + name: "UpdateAddress", + I: UpdateAddressArgs, + O: Empty, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.GetInstances + */ + getInstances: { + name: "GetInstances", + I: Empty, + O: GetInstancesResponse, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.DeleteInstances + */ + deleteInstances: { + name: "DeleteInstances", + I: DeleteInstancesRequest, + O: DeleteInstancesResponse, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.ChangeActiveStatus + */ + changeActiveStatus: { + name: "ChangeActiveStatus", + I: ChangeUserActiveRequest, + O: Empty, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.GetUser + */ + getUser: { + name: "GetUser", + I: GetUserRequest, + O: GetUserResponse, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.CheckPortAuthorization + */ + checkPortAuthorization: { + name: "CheckPortAuthorization", + I: CheckPortAuthorizationRequest, + O: Empty, + kind: MethodKind.Unary, + idempotency: MethodIdempotency.NoSideEffects, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.UnlockPort + */ + unlockPort: { + name: "UnlockPort", + I: UnlockPortRequest, + O: Empty, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.LockPort + */ + lockPort: { + name: "LockPort", + I: LockPortRequest, + O: Empty, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.GetUnlockedPorts + */ + getUnlockedPorts: { + name: "GetUnlockedPorts", + I: GetUnlockedPortsRequest, + O: GetUnlockedPortsResponse, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.GetPorts + */ + getPorts: { + name: "GetPorts", + I: GetPortsRequest, + O: GetPortsResponse, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.AddAlias + */ + addAlias: { + name: "AddAlias", + I: AddAliasRequest, + O: Empty, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.DeleteAlias + */ + deleteAlias: { + name: "DeleteAlias", + I: DeleteAliasRequest, + O: Empty, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.IsNewKurtosisVersionAvailable + */ + isNewKurtosisVersionAvailable: { + name: "IsNewKurtosisVersionAvailable", + I: IsNewKurtosisVersionAvailableRequest, + O: IsNewKurtosisVersionAvailableResponse, + kind: MethodKind.Unary, + }, + /** + * @generated from rpc kurtosis_cloud.KurtosisCloudBackendServer.UpgradeKurtosisVersion + */ + upgradeKurtosisVersion: { + name: "UpgradeKurtosisVersion", + I: UpgradeKurtosisVersionRequest, + O: Empty, + kind: MethodKind.Unary, + }, + } +} as const; + diff --git a/enclave-manager/api/typescript/src/kurtosis_backend_server_api_pb.ts b/enclave-manager/api/typescript/src/kurtosis_backend_server_api_pb.ts new file mode 100644 index 0000000000..de27ed6510 --- /dev/null +++ b/enclave-manager/api/typescript/src/kurtosis_backend_server_api_pb.ts @@ -0,0 +1,2124 @@ +// @generated by protoc-gen-es v1.3.1 with parameter "target=ts" +// @generated from file kurtosis_backend_server_api.proto (package kurtosis_cloud, syntax proto3) +/* eslint-disable */ +// @ts-nocheck + +import type { BinaryReadOptions, FieldList, JsonReadOptions, JsonValue, PartialMessage, PlainMessage } from "@bufbuild/protobuf"; +import { Message, proto3 } from "@bufbuild/protobuf"; + +/** + * @generated from message kurtosis_cloud.GetOrCreateApiKeyRequest + */ +export class GetOrCreateApiKeyRequest extends Message { + /** + * @generated from field: string access_token = 1; + */ + accessToken = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetOrCreateApiKeyRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "access_token", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetOrCreateApiKeyRequest { + return new GetOrCreateApiKeyRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetOrCreateApiKeyRequest { + return new GetOrCreateApiKeyRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetOrCreateApiKeyRequest { + return new GetOrCreateApiKeyRequest().fromJsonString(jsonString, options); + } + + static equals(a: GetOrCreateApiKeyRequest | PlainMessage | undefined, b: GetOrCreateApiKeyRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(GetOrCreateApiKeyRequest, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.GetOrCreateApiKeyResponse + */ +export class GetOrCreateApiKeyResponse extends Message { + /** + * @generated from field: string api_key = 1; + */ + apiKey = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetOrCreateApiKeyResponse"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "api_key", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetOrCreateApiKeyResponse { + return new GetOrCreateApiKeyResponse().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetOrCreateApiKeyResponse { + return new GetOrCreateApiKeyResponse().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetOrCreateApiKeyResponse { + return new GetOrCreateApiKeyResponse().fromJsonString(jsonString, options); + } + + static equals(a: GetOrCreateApiKeyResponse | PlainMessage | undefined, b: GetOrCreateApiKeyResponse | PlainMessage | undefined): boolean { + return proto3.util.equals(GetOrCreateApiKeyResponse, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.GetOrCreateInstanceRequest + */ +export class GetOrCreateInstanceRequest extends Message { + /** + * @generated from field: string api_key = 1; + */ + apiKey = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetOrCreateInstanceRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "api_key", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetOrCreateInstanceRequest { + return new GetOrCreateInstanceRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetOrCreateInstanceRequest { + return new GetOrCreateInstanceRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetOrCreateInstanceRequest { + return new GetOrCreateInstanceRequest().fromJsonString(jsonString, options); + } + + static equals(a: GetOrCreateInstanceRequest | PlainMessage | undefined, b: GetOrCreateInstanceRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(GetOrCreateInstanceRequest, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.GetOrCreateInstanceResponse + */ +export class GetOrCreateInstanceResponse extends Message { + /** + * @generated from field: string instance_id = 1; + */ + instanceId = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetOrCreateInstanceResponse"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "instance_id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetOrCreateInstanceResponse { + return new GetOrCreateInstanceResponse().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetOrCreateInstanceResponse { + return new GetOrCreateInstanceResponse().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetOrCreateInstanceResponse { + return new GetOrCreateInstanceResponse().fromJsonString(jsonString, options); + } + + static equals(a: GetOrCreateInstanceResponse | PlainMessage | undefined, b: GetOrCreateInstanceResponse | PlainMessage | undefined): boolean { + return proto3.util.equals(GetOrCreateInstanceResponse, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.GetCloudInstanceConfigArgs + */ +export class GetCloudInstanceConfigArgs extends Message { + /** + * @generated from field: optional string api_key = 1; + */ + apiKey?: string; + + /** + * @generated from field: optional string instance_id = 2; + */ + instanceId?: string; + + /** + * @generated from field: optional string instance_short_id = 3; + */ + instanceShortId?: string; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetCloudInstanceConfigArgs"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "api_key", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 2, name: "instance_id", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 3, name: "instance_short_id", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetCloudInstanceConfigArgs { + return new GetCloudInstanceConfigArgs().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetCloudInstanceConfigArgs { + return new GetCloudInstanceConfigArgs().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetCloudInstanceConfigArgs { + return new GetCloudInstanceConfigArgs().fromJsonString(jsonString, options); + } + + static equals(a: GetCloudInstanceConfigArgs | PlainMessage | undefined, b: GetCloudInstanceConfigArgs | PlainMessage | undefined): boolean { + return proto3.util.equals(GetCloudInstanceConfigArgs, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.LaunchResult + */ +export class LaunchResult extends Message { + /** + * @generated from field: string instance_name = 1; + */ + instanceName = ""; + + /** + * @generated from field: string instance_id = 2; + */ + instanceId = ""; + + /** + * @generated from field: string public_dns = 3; + */ + publicDns = ""; + + /** + * @generated from field: string ip_address = 4; + */ + ipAddress = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.LaunchResult"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "instance_name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "instance_id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "public_dns", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 4, name: "ip_address", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): LaunchResult { + return new LaunchResult().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): LaunchResult { + return new LaunchResult().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): LaunchResult { + return new LaunchResult().fromJsonString(jsonString, options); + } + + static equals(a: LaunchResult | PlainMessage | undefined, b: LaunchResult | PlainMessage | undefined): boolean { + return proto3.util.equals(LaunchResult, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.GetCloudInstanceConfigResponse + */ +export class GetCloudInstanceConfigResponse extends Message { + /** + * @generated from field: string user_id = 1; + */ + userId = ""; + + /** + * @generated from field: string instance_id = 2; + */ + instanceId = ""; + + /** + * @generated from field: string context_config = 3; + */ + contextConfig = ""; + + /** + * @generated from field: kurtosis_cloud.LaunchResult launch_result = 4; + */ + launchResult?: LaunchResult; + + /** + * @generated from field: string status = 5; + */ + status = ""; + + /** + * @generated from field: string created = 6; + */ + created = ""; + + /** + * @generated from field: string updated = 7; + */ + updated = ""; + + /** + * deprecated in favor of aws_environment + * TODO: remove it once this is released and the cloud BE is upgraded + * + * @generated from field: optional kurtosis_cloud.AwsKey user_key = 8; + */ + userKey?: AwsKey; + + /** + * TODO: remove the optional once this is released and the cloud BE is upgraded + * + * @generated from field: optional kurtosis_cloud.AwsEnvironment aws_environment = 9; + */ + awsEnvironment?: AwsEnvironment; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetCloudInstanceConfigResponse"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "user_id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "instance_id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "context_config", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 4, name: "launch_result", kind: "message", T: LaunchResult }, + { no: 5, name: "status", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 6, name: "created", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 7, name: "updated", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 8, name: "user_key", kind: "message", T: AwsKey, opt: true }, + { no: 9, name: "aws_environment", kind: "message", T: AwsEnvironment, opt: true }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetCloudInstanceConfigResponse { + return new GetCloudInstanceConfigResponse().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetCloudInstanceConfigResponse { + return new GetCloudInstanceConfigResponse().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetCloudInstanceConfigResponse { + return new GetCloudInstanceConfigResponse().fromJsonString(jsonString, options); + } + + static equals(a: GetCloudInstanceConfigResponse | PlainMessage | undefined, b: GetCloudInstanceConfigResponse | PlainMessage | undefined): boolean { + return proto3.util.equals(GetCloudInstanceConfigResponse, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.GetOrCreatePaymentConfigArgs + */ +export class GetOrCreatePaymentConfigArgs extends Message { + /** + * @generated from field: string access_token = 1; + */ + accessToken = ""; + + /** + * @generated from field: bool setup_intent = 2; + */ + setupIntent = false; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetOrCreatePaymentConfigArgs"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "access_token", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "setup_intent", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetOrCreatePaymentConfigArgs { + return new GetOrCreatePaymentConfigArgs().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetOrCreatePaymentConfigArgs { + return new GetOrCreatePaymentConfigArgs().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetOrCreatePaymentConfigArgs { + return new GetOrCreatePaymentConfigArgs().fromJsonString(jsonString, options); + } + + static equals(a: GetOrCreatePaymentConfigArgs | PlainMessage | undefined, b: GetOrCreatePaymentConfigArgs | PlainMessage | undefined): boolean { + return proto3.util.equals(GetOrCreatePaymentConfigArgs, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.PaymentMethod + */ +export class PaymentMethod extends Message { + /** + * @generated from field: int32 exp_month = 1; + */ + expMonth = 0; + + /** + * @generated from field: int32 exp_year = 2; + */ + expYear = 0; + + /** + * @generated from field: string last_four = 3; + */ + lastFour = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.PaymentMethod"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "exp_month", kind: "scalar", T: 5 /* ScalarType.INT32 */ }, + { no: 2, name: "exp_year", kind: "scalar", T: 5 /* ScalarType.INT32 */ }, + { no: 3, name: "last_four", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): PaymentMethod { + return new PaymentMethod().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): PaymentMethod { + return new PaymentMethod().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): PaymentMethod { + return new PaymentMethod().fromJsonString(jsonString, options); + } + + static equals(a: PaymentMethod | PlainMessage | undefined, b: PaymentMethod | PlainMessage | undefined): boolean { + return proto3.util.equals(PaymentMethod, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.PaymentProduct + */ +export class PaymentProduct extends Message { + /** + * @generated from field: string name = 1; + */ + name = ""; + + /** + * @generated from field: int32 price_unit_amount = 2; + */ + priceUnitAmount = 0; + + /** + * @generated from field: string price_currency = 3; + */ + priceCurrency = ""; + + /** + * @generated from field: string tax_code_name = 4; + */ + taxCodeName = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.PaymentProduct"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "price_unit_amount", kind: "scalar", T: 5 /* ScalarType.INT32 */ }, + { no: 3, name: "price_currency", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 4, name: "tax_code_name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): PaymentProduct { + return new PaymentProduct().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): PaymentProduct { + return new PaymentProduct().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): PaymentProduct { + return new PaymentProduct().fromJsonString(jsonString, options); + } + + static equals(a: PaymentProduct | PlainMessage | undefined, b: PaymentProduct | PlainMessage | undefined): boolean { + return proto3.util.equals(PaymentProduct, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.PaymentSubscription + */ +export class PaymentSubscription extends Message { + /** + * @generated from field: kurtosis_cloud.PaymentProduct product = 1; + */ + product?: PaymentProduct; + + /** + * @generated from field: kurtosis_cloud.PaymentSubscription.Status status = 2; + */ + status = PaymentSubscription_Status.ACTIVE; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.PaymentSubscription"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "product", kind: "message", T: PaymentProduct }, + { no: 2, name: "status", kind: "enum", T: proto3.getEnumType(PaymentSubscription_Status) }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): PaymentSubscription { + return new PaymentSubscription().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): PaymentSubscription { + return new PaymentSubscription().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): PaymentSubscription { + return new PaymentSubscription().fromJsonString(jsonString, options); + } + + static equals(a: PaymentSubscription | PlainMessage | undefined, b: PaymentSubscription | PlainMessage | undefined): boolean { + return proto3.util.equals(PaymentSubscription, a, b); + } +} + +/** + * @generated from enum kurtosis_cloud.PaymentSubscription.Status + */ +export enum PaymentSubscription_Status { + /** + * @generated from enum value: ACTIVE = 0; + */ + ACTIVE = 0, + + /** + * @generated from enum value: CANCELLED = 1; + */ + CANCELLED = 1, + + /** + * @generated from enum value: UNKNOWN = 2; + */ + UNKNOWN = 2, + + /** + * @generated from enum value: ACTIVE_CANCEL_AT_PERIOD_END = 3; + */ + ACTIVE_CANCEL_AT_PERIOD_END = 3, +} +// Retrieve enum metadata with: proto3.getEnumType(PaymentSubscription_Status) +proto3.util.setEnumType(PaymentSubscription_Status, "kurtosis_cloud.PaymentSubscription.Status", [ + { no: 0, name: "ACTIVE" }, + { no: 1, name: "CANCELLED" }, + { no: 2, name: "UNKNOWN" }, + { no: 3, name: "ACTIVE_CANCEL_AT_PERIOD_END" }, +]); + +/** + * @generated from message kurtosis_cloud.GetOrCreatePaymentConfigResponse + */ +export class GetOrCreatePaymentConfigResponse extends Message { + /** + * @generated from field: string user_id = 1; + */ + userId = ""; + + /** + * @generated from field: optional string client_secret = 2; + */ + clientSecret?: string; + + /** + * @generated from field: optional kurtosis_cloud.PaymentMethod payment_method = 3; + */ + paymentMethod?: PaymentMethod; + + /** + * @generated from field: kurtosis_cloud.PaymentProduct product = 4; + */ + product?: PaymentProduct; + + /** + * @generated from field: optional kurtosis_cloud.PaymentSubscription subscription = 5; + */ + subscription?: PaymentSubscription; + + /** + * @generated from field: int32 trial_end = 6; + */ + trialEnd = 0; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetOrCreatePaymentConfigResponse"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "user_id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "client_secret", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 3, name: "payment_method", kind: "message", T: PaymentMethod, opt: true }, + { no: 4, name: "product", kind: "message", T: PaymentProduct }, + { no: 5, name: "subscription", kind: "message", T: PaymentSubscription, opt: true }, + { no: 6, name: "trial_end", kind: "scalar", T: 5 /* ScalarType.INT32 */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetOrCreatePaymentConfigResponse { + return new GetOrCreatePaymentConfigResponse().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetOrCreatePaymentConfigResponse { + return new GetOrCreatePaymentConfigResponse().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetOrCreatePaymentConfigResponse { + return new GetOrCreatePaymentConfigResponse().fromJsonString(jsonString, options); + } + + static equals(a: GetOrCreatePaymentConfigResponse | PlainMessage | undefined, b: GetOrCreatePaymentConfigResponse | PlainMessage | undefined): boolean { + return proto3.util.equals(GetOrCreatePaymentConfigResponse, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.RefreshDefaultPaymentMethodArgs + */ +export class RefreshDefaultPaymentMethodArgs extends Message { + /** + * @generated from field: string access_token = 1; + */ + accessToken = ""; + + /** + * @generated from field: string payment_method_id = 2; + */ + paymentMethodId = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.RefreshDefaultPaymentMethodArgs"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "access_token", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "payment_method_id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): RefreshDefaultPaymentMethodArgs { + return new RefreshDefaultPaymentMethodArgs().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): RefreshDefaultPaymentMethodArgs { + return new RefreshDefaultPaymentMethodArgs().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): RefreshDefaultPaymentMethodArgs { + return new RefreshDefaultPaymentMethodArgs().fromJsonString(jsonString, options); + } + + static equals(a: RefreshDefaultPaymentMethodArgs | PlainMessage | undefined, b: RefreshDefaultPaymentMethodArgs | PlainMessage | undefined): boolean { + return proto3.util.equals(RefreshDefaultPaymentMethodArgs, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.CancelPaymentSubscriptionArgs + */ +export class CancelPaymentSubscriptionArgs extends Message { + /** + * @generated from field: string access_token = 1; + */ + accessToken = ""; + + /** + * @generated from field: string reason = 2; + */ + reason = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.CancelPaymentSubscriptionArgs"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "access_token", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "reason", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): CancelPaymentSubscriptionArgs { + return new CancelPaymentSubscriptionArgs().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): CancelPaymentSubscriptionArgs { + return new CancelPaymentSubscriptionArgs().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): CancelPaymentSubscriptionArgs { + return new CancelPaymentSubscriptionArgs().fromJsonString(jsonString, options); + } + + static equals(a: CancelPaymentSubscriptionArgs | PlainMessage | undefined, b: CancelPaymentSubscriptionArgs | PlainMessage | undefined): boolean { + return proto3.util.equals(CancelPaymentSubscriptionArgs, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.AwsKey + */ +export class AwsKey extends Message { + /** + * @generated from field: string id = 1; + */ + id = ""; + + /** + * @generated from field: string secret = 2; + */ + secret = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.AwsKey"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "secret", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): AwsKey { + return new AwsKey().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): AwsKey { + return new AwsKey().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): AwsKey { + return new AwsKey().fromJsonString(jsonString, options); + } + + static equals(a: AwsKey | PlainMessage | undefined, b: AwsKey | PlainMessage | undefined): boolean { + return proto3.util.equals(AwsKey, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.AwsEnvironment + */ +export class AwsEnvironment extends Message { + /** + * @generated from field: string access_key_id = 1; + */ + accessKeyId = ""; + + /** + * @generated from field: string secret_access_key = 2; + */ + secretAccessKey = ""; + + /** + * @generated from field: string bucket_region = 3; + */ + bucketRegion = ""; + + /** + * @generated from field: string bucket_name = 4; + */ + bucketName = ""; + + /** + * @generated from field: string bucket_user_folder = 5; + */ + bucketUserFolder = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.AwsEnvironment"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "access_key_id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "secret_access_key", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "bucket_region", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 4, name: "bucket_name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 5, name: "bucket_user_folder", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): AwsEnvironment { + return new AwsEnvironment().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): AwsEnvironment { + return new AwsEnvironment().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): AwsEnvironment { + return new AwsEnvironment().fromJsonString(jsonString, options); + } + + static equals(a: AwsEnvironment | PlainMessage | undefined, b: AwsEnvironment | PlainMessage | undefined): boolean { + return proto3.util.equals(AwsEnvironment, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.UpdateAddressArgs + */ +export class UpdateAddressArgs extends Message { + /** + * @generated from field: string access_token = 1; + */ + accessToken = ""; + + /** + * @generated from field: string name = 2; + */ + name = ""; + + /** + * @generated from field: string line_1 = 3; + */ + line1 = ""; + + /** + * @generated from field: optional string line_2 = 4; + */ + line2?: string; + + /** + * @generated from field: string city = 5; + */ + city = ""; + + /** + * @generated from field: string state = 6; + */ + state = ""; + + /** + * @generated from field: string postal_code = 7; + */ + postalCode = ""; + + /** + * @generated from field: string country = 8; + */ + country = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.UpdateAddressArgs"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "access_token", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "line_1", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 4, name: "line_2", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 5, name: "city", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 6, name: "state", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 7, name: "postal_code", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 8, name: "country", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): UpdateAddressArgs { + return new UpdateAddressArgs().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): UpdateAddressArgs { + return new UpdateAddressArgs().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): UpdateAddressArgs { + return new UpdateAddressArgs().fromJsonString(jsonString, options); + } + + static equals(a: UpdateAddressArgs | PlainMessage | undefined, b: UpdateAddressArgs | PlainMessage | undefined): boolean { + return proto3.util.equals(UpdateAddressArgs, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.DeleteInstancesRequest + */ +export class DeleteInstancesRequest extends Message { + /** + * @generated from field: repeated string instance_ids = 1; + */ + instanceIds: string[] = []; + + /** + * must be system user to delete instances + * + * @generated from field: string api_key = 2; + */ + apiKey = ""; + + /** + * can optionally pass a status to only delete instances with a certain status, eg. configuring + * + * @generated from field: optional string status = 3; + */ + status?: string; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.DeleteInstancesRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "instance_ids", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true }, + { no: 2, name: "api_key", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "status", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): DeleteInstancesRequest { + return new DeleteInstancesRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): DeleteInstancesRequest { + return new DeleteInstancesRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): DeleteInstancesRequest { + return new DeleteInstancesRequest().fromJsonString(jsonString, options); + } + + static equals(a: DeleteInstancesRequest | PlainMessage | undefined, b: DeleteInstancesRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(DeleteInstancesRequest, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.DeleteInstancesResponse + */ +export class DeleteInstancesResponse extends Message { + /** + * @generated from field: repeated string deleted_instances = 1; + */ + deletedInstances: string[] = []; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.DeleteInstancesResponse"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "deleted_instances", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): DeleteInstancesResponse { + return new DeleteInstancesResponse().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): DeleteInstancesResponse { + return new DeleteInstancesResponse().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): DeleteInstancesResponse { + return new DeleteInstancesResponse().fromJsonString(jsonString, options); + } + + static equals(a: DeleteInstancesResponse | PlainMessage | undefined, b: DeleteInstancesResponse | PlainMessage | undefined): boolean { + return proto3.util.equals(DeleteInstancesResponse, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.GetInstancesResponse + */ +export class GetInstancesResponse extends Message { + /** + * @generated from field: map instances = 1; + */ + instances: { [key: string]: Instance } = {}; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetInstancesResponse"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "instances", kind: "map", K: 9 /* ScalarType.STRING */, V: {kind: "message", T: Instance} }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetInstancesResponse { + return new GetInstancesResponse().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetInstancesResponse { + return new GetInstancesResponse().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetInstancesResponse { + return new GetInstancesResponse().fromJsonString(jsonString, options); + } + + static equals(a: GetInstancesResponse | PlainMessage | undefined, b: GetInstancesResponse | PlainMessage | undefined): boolean { + return proto3.util.equals(GetInstancesResponse, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.ChangeUserActiveRequest + */ +export class ChangeUserActiveRequest extends Message { + /** + * @generated from field: string user_id = 1; + */ + userId = ""; + + /** + * @generated from field: bool active = 2; + */ + active = false; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.ChangeUserActiveRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "user_id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "active", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): ChangeUserActiveRequest { + return new ChangeUserActiveRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): ChangeUserActiveRequest { + return new ChangeUserActiveRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): ChangeUserActiveRequest { + return new ChangeUserActiveRequest().fromJsonString(jsonString, options); + } + + static equals(a: ChangeUserActiveRequest | PlainMessage | undefined, b: ChangeUserActiveRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(ChangeUserActiveRequest, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.GetUserRequest + */ +export class GetUserRequest extends Message { + /** + * @generated from field: string user_id = 1; + */ + userId = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetUserRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "user_id", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetUserRequest { + return new GetUserRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetUserRequest { + return new GetUserRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetUserRequest { + return new GetUserRequest().fromJsonString(jsonString, options); + } + + static equals(a: GetUserRequest | PlainMessage | undefined, b: GetUserRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(GetUserRequest, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.GetUserResponse + */ +export class GetUserResponse extends Message { + /** + * @generated from field: kurtosis_cloud.User user = 1; + */ + user?: User; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetUserResponse"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "user", kind: "message", T: User }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetUserResponse { + return new GetUserResponse().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetUserResponse { + return new GetUserResponse().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetUserResponse { + return new GetUserResponse().fromJsonString(jsonString, options); + } + + static equals(a: GetUserResponse | PlainMessage | undefined, b: GetUserResponse | PlainMessage | undefined): boolean { + return proto3.util.equals(GetUserResponse, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.Auth0User + */ +export class Auth0User extends Message { + /** + * @generated from field: string Auth0UserId = 1; + */ + Auth0UserId = ""; + + /** + * @generated from field: optional string Auth0Name = 2; + */ + Auth0Name?: string; + + /** + * @generated from field: optional string Auth0GivenName = 3; + */ + Auth0GivenName?: string; + + /** + * @generated from field: optional string Auth0FamilyName = 4; + */ + Auth0FamilyName?: string; + + /** + * @generated from field: optional string Auth0Email = 5; + */ + Auth0Email?: string; + + /** + * @generated from field: optional bool Auth0EmailVerified = 6; + */ + Auth0EmailVerified?: boolean; + + /** + * @generated from field: optional string Auth0Provider = 7; + */ + Auth0Provider?: string; + + /** + * @generated from field: optional string Auth0Created = 8; + */ + Auth0Created?: string; + + /** + * @generated from field: optional string Auth0LastLogin = 9; + */ + Auth0LastLogin?: string; + + /** + * @generated from field: optional string Auth0LastIp = 10; + */ + Auth0LastIp?: string; + + /** + * @generated from field: optional int64 Auth0LoginsCount = 11; + */ + Auth0LoginsCount?: bigint; + + /** + * @generated from field: optional string Auth0Picture = 12; + */ + Auth0Picture?: string; + + /** + * @generated from field: optional string Auth0Location = 13; + */ + Auth0Location?: string; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.Auth0User"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "Auth0UserId", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "Auth0Name", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 3, name: "Auth0GivenName", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 4, name: "Auth0FamilyName", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 5, name: "Auth0Email", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 6, name: "Auth0EmailVerified", kind: "scalar", T: 8 /* ScalarType.BOOL */, opt: true }, + { no: 7, name: "Auth0Provider", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 8, name: "Auth0Created", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 9, name: "Auth0LastLogin", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 10, name: "Auth0LastIp", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 11, name: "Auth0LoginsCount", kind: "scalar", T: 3 /* ScalarType.INT64 */, opt: true }, + { no: 12, name: "Auth0Picture", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + { no: 13, name: "Auth0Location", kind: "scalar", T: 9 /* ScalarType.STRING */, opt: true }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): Auth0User { + return new Auth0User().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): Auth0User { + return new Auth0User().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): Auth0User { + return new Auth0User().fromJsonString(jsonString, options); + } + + static equals(a: Auth0User | PlainMessage | undefined, b: Auth0User | PlainMessage | undefined): boolean { + return proto3.util.equals(Auth0User, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.Ec2Connection + */ +export class Ec2Connection extends Message { + /** + * @generated from field: string InstanceName = 1; + */ + InstanceName = ""; + + /** + * @generated from field: string PublicDns = 2; + */ + PublicDns = ""; + + /** + * @generated from field: string IpAddress = 3; + */ + IpAddress = ""; + + /** + * @generated from field: string InstanceId = 4; + */ + InstanceId = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.Ec2Connection"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "InstanceName", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "PublicDns", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "IpAddress", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 4, name: "InstanceId", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): Ec2Connection { + return new Ec2Connection().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): Ec2Connection { + return new Ec2Connection().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): Ec2Connection { + return new Ec2Connection().fromJsonString(jsonString, options); + } + + static equals(a: Ec2Connection | PlainMessage | undefined, b: Ec2Connection | PlainMessage | undefined): boolean { + return proto3.util.equals(Ec2Connection, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.PaymentUser + */ +export class PaymentUser extends Message { + /** + * @generated from field: string UserId = 1; + */ + UserId = ""; + + /** + * @generated from field: string Subscription = 2; + */ + Subscription = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.PaymentUser"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "UserId", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "Subscription", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): PaymentUser { + return new PaymentUser().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): PaymentUser { + return new PaymentUser().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): PaymentUser { + return new PaymentUser().fromJsonString(jsonString, options); + } + + static equals(a: PaymentUser | PlainMessage | undefined, b: PaymentUser | PlainMessage | undefined): boolean { + return proto3.util.equals(PaymentUser, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.Instance + */ +export class Instance extends Message { + /** + * @generated from field: string Uuid = 1; + */ + Uuid = ""; + + /** + * @generated from field: string UserId = 2; + */ + UserId = ""; + + /** + * @generated from field: optional kurtosis_cloud.Auth0User Auth0User = 3; + */ + Auth0User?: Auth0User; + + /** + * @generated from field: optional kurtosis_cloud.Ec2Connection Ec2Connection = 4; + */ + Ec2Connection?: Ec2Connection; + + /** + * @generated from field: string Status = 5; + */ + Status = ""; + + /** + * @generated from field: string Updated = 6; + */ + Updated = ""; + + /** + * @generated from field: string Created = 7; + */ + Created = ""; + + /** + * @generated from field: optional kurtosis_cloud.PaymentUser PaymentUser = 8; + */ + PaymentUser?: PaymentUser; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.Instance"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "Uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "UserId", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "Auth0User", kind: "message", T: Auth0User, opt: true }, + { no: 4, name: "Ec2Connection", kind: "message", T: Ec2Connection, opt: true }, + { no: 5, name: "Status", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 6, name: "Updated", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 7, name: "Created", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 8, name: "PaymentUser", kind: "message", T: PaymentUser, opt: true }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): Instance { + return new Instance().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): Instance { + return new Instance().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): Instance { + return new Instance().fromJsonString(jsonString, options); + } + + static equals(a: Instance | PlainMessage | undefined, b: Instance | PlainMessage | undefined): boolean { + return proto3.util.equals(Instance, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.User + */ +export class User extends Message { + /** + * @generated from field: string UserID = 1; + */ + UserID = ""; + + /** + * @generated from field: string ExternalUserID = 2; + */ + ExternalUserID = ""; + + /** + * @generated from field: bool Active = 3; + */ + Active = false; + + /** + * @generated from field: string Updated = 4; + */ + Updated = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.User"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "UserID", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "ExternalUserID", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "Active", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, + { no: 4, name: "Updated", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): User { + return new User().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): User { + return new User().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): User { + return new User().fromJsonString(jsonString, options); + } + + static equals(a: User | PlainMessage | undefined, b: User | PlainMessage | undefined): boolean { + return proto3.util.equals(User, a, b); + } +} + +/** + * TODO deprecate this when all engines are upgraded + * + * @generated from message kurtosis_cloud.GetUnlockedPortsRequest + */ +export class GetUnlockedPortsRequest extends Message { + /** + * @generated from field: string access_token = 1; + */ + accessToken = ""; + + /** + * @generated from field: string instance_short_uuid = 2; + */ + instanceShortUuid = ""; + + /** + * @generated from field: string enclave_short_uuid = 3; + */ + enclaveShortUuid = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetUnlockedPortsRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "access_token", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "instance_short_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "enclave_short_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetUnlockedPortsRequest { + return new GetUnlockedPortsRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetUnlockedPortsRequest { + return new GetUnlockedPortsRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetUnlockedPortsRequest { + return new GetUnlockedPortsRequest().fromJsonString(jsonString, options); + } + + static equals(a: GetUnlockedPortsRequest | PlainMessage | undefined, b: GetUnlockedPortsRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(GetUnlockedPortsRequest, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.GetPortsRequest + */ +export class GetPortsRequest extends Message { + /** + * @generated from field: string access_token = 1; + */ + accessToken = ""; + + /** + * @generated from field: string instance_short_uuid = 2; + */ + instanceShortUuid = ""; + + /** + * @generated from field: string enclave_short_uuid = 3; + */ + enclaveShortUuid = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetPortsRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "access_token", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "instance_short_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "enclave_short_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetPortsRequest { + return new GetPortsRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetPortsRequest { + return new GetPortsRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetPortsRequest { + return new GetPortsRequest().fromJsonString(jsonString, options); + } + + static equals(a: GetPortsRequest | PlainMessage | undefined, b: GetPortsRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(GetPortsRequest, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.CheckPortAuthorizationRequest + */ +export class CheckPortAuthorizationRequest extends Message { + /** + * @generated from oneof kurtosis_cloud.CheckPortAuthorizationRequest.port_identifier + */ + portIdentifier: { + /** + * @generated from field: kurtosis_cloud.Port port = 1; + */ + value: Port; + case: "port"; + } | { + /** + * @generated from field: string alias = 2; + */ + value: string; + case: "alias"; + } | { case: undefined; value?: undefined } = { case: undefined }; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.CheckPortAuthorizationRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "port", kind: "message", T: Port, oneof: "port_identifier" }, + { no: 2, name: "alias", kind: "scalar", T: 9 /* ScalarType.STRING */, oneof: "port_identifier" }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): CheckPortAuthorizationRequest { + return new CheckPortAuthorizationRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): CheckPortAuthorizationRequest { + return new CheckPortAuthorizationRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): CheckPortAuthorizationRequest { + return new CheckPortAuthorizationRequest().fromJsonString(jsonString, options); + } + + static equals(a: CheckPortAuthorizationRequest | PlainMessage | undefined, b: CheckPortAuthorizationRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(CheckPortAuthorizationRequest, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.UnlockPortRequest + */ +export class UnlockPortRequest extends Message { + /** + * @generated from field: string access_token = 1; + */ + accessToken = ""; + + /** + * @generated from field: kurtosis_cloud.Port port = 2; + */ + port?: Port; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.UnlockPortRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "access_token", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "port", kind: "message", T: Port }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): UnlockPortRequest { + return new UnlockPortRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): UnlockPortRequest { + return new UnlockPortRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): UnlockPortRequest { + return new UnlockPortRequest().fromJsonString(jsonString, options); + } + + static equals(a: UnlockPortRequest | PlainMessage | undefined, b: UnlockPortRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(UnlockPortRequest, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.LockPortRequest + */ +export class LockPortRequest extends Message { + /** + * @generated from field: string access_token = 1; + */ + accessToken = ""; + + /** + * @generated from field: kurtosis_cloud.Port port = 2; + */ + port?: Port; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.LockPortRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "access_token", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "port", kind: "message", T: Port }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): LockPortRequest { + return new LockPortRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): LockPortRequest { + return new LockPortRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): LockPortRequest { + return new LockPortRequest().fromJsonString(jsonString, options); + } + + static equals(a: LockPortRequest | PlainMessage | undefined, b: LockPortRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(LockPortRequest, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.Port + */ +export class Port extends Message { + /** + * @generated from field: uint32 port_number = 1; + */ + portNumber = 0; + + /** + * @generated from field: string instance_short_uuid = 2; + */ + instanceShortUuid = ""; + + /** + * @generated from field: string service_short_uuid = 3; + */ + serviceShortUuid = ""; + + /** + * @generated from field: string enclave_short_uuid = 4; + */ + enclaveShortUuid = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.Port"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "port_number", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, + { no: 2, name: "instance_short_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "service_short_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 4, name: "enclave_short_uuid", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): Port { + return new Port().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): Port { + return new Port().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): Port { + return new Port().fromJsonString(jsonString, options); + } + + static equals(a: Port | PlainMessage | undefined, b: Port | PlainMessage | undefined): boolean { + return proto3.util.equals(Port, a, b); + } +} + +/** + * TODO deprecate this when all clients are upgraded + * + * @generated from message kurtosis_cloud.GetUnlockedPortsResponse + */ +export class GetUnlockedPortsResponse extends Message { + /** + * @generated from field: repeated kurtosis_cloud.Port port = 1; + */ + port: Port[] = []; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetUnlockedPortsResponse"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "port", kind: "message", T: Port, repeated: true }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetUnlockedPortsResponse { + return new GetUnlockedPortsResponse().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetUnlockedPortsResponse { + return new GetUnlockedPortsResponse().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetUnlockedPortsResponse { + return new GetUnlockedPortsResponse().fromJsonString(jsonString, options); + } + + static equals(a: GetUnlockedPortsResponse | PlainMessage | undefined, b: GetUnlockedPortsResponse | PlainMessage | undefined): boolean { + return proto3.util.equals(GetUnlockedPortsResponse, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.CloudPort + */ +export class CloudPort extends Message { + /** + * @generated from field: kurtosis_cloud.Port port = 1; + */ + port?: Port; + + /** + * @generated from field: string alias = 2; + */ + alias = ""; + + /** + * @generated from field: bool locked = 3; + */ + locked = false; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.CloudPort"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "port", kind: "message", T: Port }, + { no: 2, name: "alias", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "locked", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): CloudPort { + return new CloudPort().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): CloudPort { + return new CloudPort().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): CloudPort { + return new CloudPort().fromJsonString(jsonString, options); + } + + static equals(a: CloudPort | PlainMessage | undefined, b: CloudPort | PlainMessage | undefined): boolean { + return proto3.util.equals(CloudPort, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.GetPortsResponse + */ +export class GetPortsResponse extends Message { + /** + * @generated from field: repeated kurtosis_cloud.CloudPort cloudPorts = 1; + */ + cloudPorts: CloudPort[] = []; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.GetPortsResponse"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "cloudPorts", kind: "message", T: CloudPort, repeated: true }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): GetPortsResponse { + return new GetPortsResponse().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): GetPortsResponse { + return new GetPortsResponse().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): GetPortsResponse { + return new GetPortsResponse().fromJsonString(jsonString, options); + } + + static equals(a: GetPortsResponse | PlainMessage | undefined, b: GetPortsResponse | PlainMessage | undefined): boolean { + return proto3.util.equals(GetPortsResponse, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.AddAliasRequest + */ +export class AddAliasRequest extends Message { + /** + * @generated from field: string access_token = 1; + */ + accessToken = ""; + + /** + * @generated from field: kurtosis_cloud.Port port = 2; + */ + port?: Port; + + /** + * @generated from field: string alias = 3; + */ + alias = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.AddAliasRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "access_token", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "port", kind: "message", T: Port }, + { no: 3, name: "alias", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): AddAliasRequest { + return new AddAliasRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): AddAliasRequest { + return new AddAliasRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): AddAliasRequest { + return new AddAliasRequest().fromJsonString(jsonString, options); + } + + static equals(a: AddAliasRequest | PlainMessage | undefined, b: AddAliasRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(AddAliasRequest, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.DeleteAliasRequest + */ +export class DeleteAliasRequest extends Message { + /** + * @generated from field: string access_token = 1; + */ + accessToken = ""; + + /** + * @generated from field: string alias = 2; + */ + alias = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.DeleteAliasRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "access_token", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "alias", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): DeleteAliasRequest { + return new DeleteAliasRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): DeleteAliasRequest { + return new DeleteAliasRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): DeleteAliasRequest { + return new DeleteAliasRequest().fromJsonString(jsonString, options); + } + + static equals(a: DeleteAliasRequest | PlainMessage | undefined, b: DeleteAliasRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(DeleteAliasRequest, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.IsNewKurtosisVersionAvailableRequest + */ +export class IsNewKurtosisVersionAvailableRequest extends Message { + /** + * @generated from field: string access_token = 1; + */ + accessToken = ""; + + /** + * @generated from field: string current_kurtosis_version = 2; + */ + currentKurtosisVersion = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.IsNewKurtosisVersionAvailableRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "access_token", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "current_kurtosis_version", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): IsNewKurtosisVersionAvailableRequest { + return new IsNewKurtosisVersionAvailableRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): IsNewKurtosisVersionAvailableRequest { + return new IsNewKurtosisVersionAvailableRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): IsNewKurtosisVersionAvailableRequest { + return new IsNewKurtosisVersionAvailableRequest().fromJsonString(jsonString, options); + } + + static equals(a: IsNewKurtosisVersionAvailableRequest | PlainMessage | undefined, b: IsNewKurtosisVersionAvailableRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(IsNewKurtosisVersionAvailableRequest, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.IsNewKurtosisVersionAvailableResponse + */ +export class IsNewKurtosisVersionAvailableResponse extends Message { + /** + * @generated from field: bool isAvailable = 1; + */ + isAvailable = false; + + /** + * @generated from field: string latestVersion = 2; + */ + latestVersion = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.IsNewKurtosisVersionAvailableResponse"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "isAvailable", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, + { no: 2, name: "latestVersion", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): IsNewKurtosisVersionAvailableResponse { + return new IsNewKurtosisVersionAvailableResponse().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): IsNewKurtosisVersionAvailableResponse { + return new IsNewKurtosisVersionAvailableResponse().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): IsNewKurtosisVersionAvailableResponse { + return new IsNewKurtosisVersionAvailableResponse().fromJsonString(jsonString, options); + } + + static equals(a: IsNewKurtosisVersionAvailableResponse | PlainMessage | undefined, b: IsNewKurtosisVersionAvailableResponse | PlainMessage | undefined): boolean { + return proto3.util.equals(IsNewKurtosisVersionAvailableResponse, a, b); + } +} + +/** + * @generated from message kurtosis_cloud.UpgradeKurtosisVersionRequest + */ +export class UpgradeKurtosisVersionRequest extends Message { + /** + * @generated from field: string access_token = 1; + */ + accessToken = ""; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_cloud.UpgradeKurtosisVersionRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "access_token", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): UpgradeKurtosisVersionRequest { + return new UpgradeKurtosisVersionRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): UpgradeKurtosisVersionRequest { + return new UpgradeKurtosisVersionRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): UpgradeKurtosisVersionRequest { + return new UpgradeKurtosisVersionRequest().fromJsonString(jsonString, options); + } + + static equals(a: UpgradeKurtosisVersionRequest | PlainMessage | undefined, b: UpgradeKurtosisVersionRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(UpgradeKurtosisVersionRequest, a, b); + } +} + diff --git a/enclave-manager/api/typescript/src/kurtosis_enclave_manager_api_connect.ts b/enclave-manager/api/typescript/src/kurtosis_enclave_manager_api_connect.ts index ebee8e3811..69ad20f54c 100644 --- a/enclave-manager/api/typescript/src/kurtosis_enclave_manager_api_connect.ts +++ b/enclave-manager/api/typescript/src/kurtosis_enclave_manager_api_connect.ts @@ -3,7 +3,7 @@ /* eslint-disable */ // @ts-nocheck -import { AddAliasRequest, CreateRepositoryWebhookRequest, DownloadFilesArtifactRequest, GetCloudInstanceConfigRequest, GetListFilesArtifactNamesAndUuidsRequest, GetServicesRequest, GetStarlarkRunRequest, HealthCheckRequest, HealthCheckResponse, InspectFilesArtifactContentsRequest, LockUnlockPortRequest, RunStarlarkPackageRequest, RunStarlarkScriptRequest, StarlarkPackagePlanYamlArgs, StarlarkScriptPlanYamlArgs } from "./kurtosis_enclave_manager_api_pb.js"; +import { AddAliasRequest, CreateRepositoryWebhookRequest, DownloadFilesArtifactRequest, GetCloudInstanceConfigRequest, GetListFilesArtifactNamesAndUuidsRequest, GetServicesRequest, GetStarlarkRunRequest, HealthCheckRequest, HealthCheckResponse, InspectFilesArtifactContentsRequest, LockUnlockPortRequest, PublishPackageRequest, RunStarlarkPackageRequest, RunStarlarkScriptRequest, StarlarkPackagePlanYamlArgs, StarlarkScriptPlanYamlArgs } from "./kurtosis_enclave_manager_api_pb.js"; import { Empty, MethodKind } from "@bufbuild/protobuf"; import { CreateEnclaveArgs, CreateEnclaveResponse, DestroyEnclaveArgs, GetEnclavesResponse, GetServiceLogsArgs, GetServiceLogsResponse } from "./engine_service_pb.js"; import { GetServicesResponse, GetStarlarkRunResponse, InspectFilesArtifactContentsResponse, ListFilesArtifactNamesAndUuidsResponse, PlanYaml, StarlarkRunResponseLine, StreamedDataChunk } from "./api_container_service_pb.js"; @@ -204,6 +204,15 @@ export const KurtosisEnclaveManagerServer = { O: Empty, kind: MethodKind.Unary, }, + /** + * @generated from rpc kurtosis_enclave_manager.KurtosisEnclaveManagerServer.PublishPackageRepository + */ + publishPackageRepository: { + name: "PublishPackageRepository", + I: PublishPackageRequest, + O: Empty, + kind: MethodKind.Unary, + }, } } as const; diff --git a/enclave-manager/api/typescript/src/kurtosis_enclave_manager_api_pb.ts b/enclave-manager/api/typescript/src/kurtosis_enclave_manager_api_pb.ts index f9e90aa59d..5f77ed78e5 100644 --- a/enclave-manager/api/typescript/src/kurtosis_enclave_manager_api_pb.ts +++ b/enclave-manager/api/typescript/src/kurtosis_enclave_manager_api_pb.ts @@ -1,4 +1,4 @@ -// @generated by protoc-gen-es v1.8.0 with parameter "target=ts" +// @generated by protoc-gen-es v1.3.1 with parameter "target=ts" // @generated from file kurtosis_enclave_manager_api.proto (package kurtosis_enclave_manager, syntax proto3) /* eslint-disable */ // @ts-nocheck @@ -626,6 +626,61 @@ export class AddAliasRequest extends Message { } } +/** + * @generated from message kurtosis_enclave_manager.PublishPackageRequest + */ +export class PublishPackageRequest extends Message { + /** + * @generated from field: string authCode = 1; + */ + authCode = ""; + + /** + * @generated from field: string packageName = 2; + */ + packageName = ""; + + /** + * @generated from field: string serializedStarlarkScript = 3; + */ + serializedStarlarkScript = ""; + + /** + * @generated from field: bytes serializedPackageIcon = 4; + */ + serializedPackageIcon = new Uint8Array(0); + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "kurtosis_enclave_manager.PublishPackageRequest"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "authCode", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "packageName", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 3, name: "serializedStarlarkScript", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 4, name: "serializedPackageIcon", kind: "scalar", T: 12 /* ScalarType.BYTES */ }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): PublishPackageRequest { + return new PublishPackageRequest().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): PublishPackageRequest { + return new PublishPackageRequest().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): PublishPackageRequest { + return new PublishPackageRequest().fromJsonString(jsonString, options); + } + + static equals(a: PublishPackageRequest | PlainMessage | undefined, b: PublishPackageRequest | PlainMessage | undefined): boolean { + return proto3.util.equals(PublishPackageRequest, a, b); + } +} + /** * ============================================================================================== * Get Starlark Plan Yaml diff --git a/enclave-manager/server/README_K.md.tmpl b/enclave-manager/server/README_K.md.tmpl new file mode 100644 index 0000000000..1e34590c0b --- /dev/null +++ b/enclave-manager/server/README_K.md.tmpl @@ -0,0 +1,91 @@ +My Package +============ +This is a [Kurtosis](https://github.com/kurtosis-tech/kurtosis/) package. It doesn't do much now, but it will soon! + +Run this package +---------------- +If you have [Kurtosis installed][install-kurtosis], run: + + +```bash +kurtosis run github.com/YOURUSER/THISREPO +``` + +If you don't have Kurtosis installed, [click here to run this package on the Kurtosis playground](https://gitpod.io/?autoStart=true&editor=code#https://github.com/kurtosis-tech/playground-gitpod). + +To blow away the created [enclave][enclaves-reference], run `kurtosis clean -a`. + +#### Configuration + +
+ Click to see configuration + +You can configure this package using the JSON structure below. The default values for each parameter are shown. + +NOTE: the `//` lines are not valid JSON; you will need to remove them! + + +```javascript +{ + // The name to print + "name": "John Snow" +} +``` + +The arguments can then be passed in to `kurtosis run`. + +For example: + + +```bash +kurtosis run github.com/YOURUSER/THISREPO '{"name":"Maynard James Keenan"}' +``` + +You can also store the JSON args in a file, and use command expansion to slot them in: + + +```bash +kurtosis run github.com/YOURUSER/THISREPO "$(cat args.json)" +``` + +
+ +Use this package in your package +-------------------------------- +Kurtosis packages can be composed inside other Kurtosis packages. To use this package in your package: + + +First, import this package by adding the following to the top of your Starlark file: + +```python +# For remote packages: +this_package = import_module("github.com/YOURUSER/THISREPO/main.star") + +# For local packages: +this_package = import_module(".src/main.star") +``` + +If you want to use a fork or specific version of this package in your own package, you can replace the dependencies in your `kurtosis.yml` file using the [replace](https://docs.kurtosis.com/concepts-reference/kurtosis-yml/#replace) primitive. +Within your `kurtosis.yml` file: +```python +name: github.com/example-org/example-repo +replace: + github.com/YOURUSER/THISREPO: github.com/YOURUSER/THISREPO@YOURBRANCH +``` + +Then, call the this package's `run` function somewhere in your Starlark script: + +```python +this_package_output = this_package.run(plan, args) +``` + +Develop on this package +----------------------- +1. [Install Kurtosis][install-kurtosis] +1. Clone this repo +1. For your dev loop, run `kurtosis clean -a && kurtosis run .` inside the repo directory + + + +[install-kurtosis]: https://docs.kurtosis.com/install +[enclaves-reference]: https://docs.kurtosis.com/concepts-reference/enclaves \ No newline at end of file diff --git a/enclave-manager/server/go.mod b/enclave-manager/server/go.mod index 0c4be884d1..861bdabdc9 100644 --- a/enclave-manager/server/go.mod +++ b/enclave-manager/server/go.mod @@ -1,6 +1,8 @@ module github.com/kurtosis-tech/kurtosis/enclave-manager -go 1.20 +go 1.21 + +toolchain go1.22.2 require ( connectrpc.com/connect v1.11.1 @@ -13,6 +15,7 @@ require ( github.com/kurtosis-tech/stacktrace v0.0.0-20211028211901-1c67a77b5409 github.com/rs/cors v1.9.0 github.com/sirupsen/logrus v1.9.3 + golang.org/x/oauth2 v0.11.0 google.golang.org/protobuf v1.33.0 ) @@ -58,6 +61,7 @@ require ( golang.org/x/sys v0.15.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/tools v0.14.0 // indirect + google.golang.org/appengine v1.6.7 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230803162519-f966b187b2e5 // indirect google.golang.org/grpc v1.57.1 // indirect ) diff --git a/enclave-manager/server/go.sum b/enclave-manager/server/go.sum index b944694e09..5e55932b93 100644 --- a/enclave-manager/server/go.sum +++ b/enclave-manager/server/go.sum @@ -1,6 +1,7 @@ cloud.google.com/go v0.26.0 h1:e0WKqKTd5BnrG8aKH3J3h+QvEIQtSUcf2n5UZ5ZgLtQ= cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= -cloud.google.com/go/compute v1.19.1 h1:am86mquDUgjGNWxiGn+5PGLbmgiWXlE/yNWpIpNvuXY= +cloud.google.com/go/compute v1.20.1 h1:6aKEtlUiwEpJzM001l0yFkpXmUVXaN8W+fbkb2AZNbg= +cloud.google.com/go/compute v1.20.1/go.mod h1:4tCnrn48xsqlwSAiLf1HXMQk8CONslYbdiEZc9FEIbM= cloud.google.com/go/compute/metadata v0.2.3 h1:mg4jlk7mCAj6xXp9UJ4fjI9VUI5rubuGBW5aJ7UnBMY= cloud.google.com/go/compute/metadata v0.2.3/go.mod h1:VAV5nSsACxMJvgaAuX6Pk2AawlZn8kiOGuCv6gTkwuA= connectrpc.com/connect v1.11.1 h1:dqRwblixqkVh+OFBOOL1yIf1jS/yP0MSJLijRj29bFg= @@ -15,6 +16,7 @@ github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/xds/go v0.0.0-20230607035331-e9ce68804cb4 h1:/inchEIKaYC1Akx+H+gqO04wryn5h75LSazbRlnya1k= +github.com/cncf/xds/go v0.0.0-20230607035331-e9ce68804cb4/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/containerd/containerd v1.7.2 h1:UF2gdONnxO8I6byZXDi5sXWiWvlW3D/sci7dTQimEJo= github.com/containerd/containerd v1.7.2/go.mod h1:afcz74+K10M/+cjGHIVQrCt3RAQhUSCAjJ9iMYhhkuI= github.com/containerd/typeurl/v2 v2.1.1 h1:3Q4Pt7i8nYwy2KmQWIw2+1hTvwTE/6w9FqcttATPO/4= @@ -22,6 +24,7 @@ github.com/containerd/typeurl/v2 v2.1.1/go.mod h1:IDp2JFvbwZ31H8dQbEIY7sDl2L3o3H github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/creack/pty v1.1.21 h1:1/QdRyBaHHJP61QkWMXlOIBfsgdDeeKfK8SYVUWJKf0= +github.com/creack/pty v1.1.21/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= @@ -41,7 +44,9 @@ github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.m github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= github.com/envoyproxy/protoc-gen-validate v0.10.1 h1:c0g45+xCJhdgFGw7a5QAfdS4byAbud7miNWJ1WwEVf8= +github.com/envoyproxy/protoc-gen-validate v0.10.1/go.mod h1:DRjgyB0I43LtJapqN6NiRwroiAU2PaFuvk/vjgh61ss= github.com/frankban/quicktest v1.14.6 h1:7Xjx+VpznH+oBnejlPUj8oUpdxnVs4f8XU8WnHkI4W8= +github.com/frankban/quicktest v1.14.6/go.mod h1:4ptaffx2x8+WTWXmUCuVU6aPUX1/Mz7zb5vbUoiM6w0= github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= @@ -57,6 +62,7 @@ github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69 github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= +github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.3/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= @@ -70,6 +76,7 @@ github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= +github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-github/v60 v60.0.0 h1:oLG98PsLauFvvu4D/YPxq374jhSxFYdzQGNCyONLfn8= github.com/google/go-github/v60 v60.0.0/go.mod h1:ByhX2dP9XT9o/ll2yXAu2VD8l5eNVg8hD4Cr0S/LmQk= github.com/google/go-querystring v1.1.0 h1:AnCroh3fv4ZBgVIf1Iwtovgjaw/GiKJo8M8yD/fhyJ8= @@ -128,6 +135,7 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= github.com/rogpeppe/go-internal v1.11.0 h1:cWPaGQEPrBb5/AsnsZesgZZ9yb1OQ+GOISoDNXVBh4M= +github.com/rogpeppe/go-internal v1.11.0/go.mod h1:ddIwULY96R17DhadqLgMfk9H9tvdUzkipdSkR5nkCZA= github.com/rs/cors v1.9.0 h1:l9HGsTsHJcvW14Nk7J9KFz8bzeAWXn3CG6bgt7LsrAE= github.com/rs/cors v1.9.0/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= @@ -140,6 +148,7 @@ github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXf github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= +github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/ulikunitz/xz v0.5.8/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= github.com/ulikunitz/xz v0.5.11 h1:kpFauv27b6ynzBNT/Xy+1k+fK4WswhN/6PN5WhFAGw8= github.com/ulikunitz/xz v0.5.11/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= @@ -174,6 +183,7 @@ golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73r golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= @@ -181,12 +191,14 @@ golang.org/x/net v0.19.0 h1:zTwKpTd2XuCqf8huc7Fo2iSy+4RHPd10s4KzeTnVr1c= golang.org/x/net v0.19.0/go.mod h1:CfAk/cbD4CthTvqiEl8NpboMuiuOYsAr/7NOjZJtv1U= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.11.0 h1:vPL4xzxBM4niKCW6g9whtaWVXTJf1U5e4aZxxFx/gbU= +golang.org/x/oauth2 v0.11.0/go.mod h1:LdF7O/8bLR/qWK9DrpXmbHLTouvRHK0SgJl0GmDBchk= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.4.0 h1:zxkM55ReGkDlKSM+Fu41A+zmbZuaPVbGMzvvdUPznYQ= +golang.org/x/sync v0.4.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -197,10 +209,12 @@ golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc= golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= +golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= golang.org/x/time v0.3.0 h1:rg5rLMjNzMS1RkNLzCG38eapWhnYLFYXDXj2gOlr8j4= +golang.org/x/time v0.3.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= @@ -219,6 +233,7 @@ golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8T google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.6.7 h1:FZR1q0exgwxzPzp/aF+VccGrSfxfPpkBqjIIEq3ru6c= +google.golang.org/appengine v1.6.7/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= google.golang.org/genproto v0.0.0-20200423170343-7949de9c1215/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= @@ -240,7 +255,9 @@ gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8 gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= +gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk= gotest.tools/v3 v3.4.0 h1:ZazjZUfuVeZGLAmlKKuyv3IKP5orXcwtOwDQH6YVr6o= +gotest.tools/v3 v3.4.0/go.mod h1:CtbdzLSsqVhDgMtKsx03ird5YTGB3ar27v0u/yKBW5g= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= diff --git a/enclave-manager/server/publish_package.go b/enclave-manager/server/publish_package.go new file mode 100644 index 0000000000..974156d55b --- /dev/null +++ b/enclave-manager/server/publish_package.go @@ -0,0 +1,236 @@ +package server + +import ( + "context" + "encoding/base64" + "fmt" + "github.com/google/go-github/v60/github" + "github.com/kurtosis-tech/stacktrace" + "github.com/sirupsen/logrus" + "golang.org/x/oauth2" + "io" + "net/http" + "net/url" + "time" +) + +const ( + clientID = "Iv23liicwMSrJ7dqrqdO" + clientSecret = "" +) + +type BlobData struct { + Path string `json:"path"` + Content string `json:"content"` +} + +func PublishPackageRepository(ctx context.Context, authCode, packageName, serializedStarlarkScript string, serializedPackageIcon []byte) error { + logrus.Infof("Attempting to publish package using github code: %v, package name: %v", authCode, packageName) + + // Step 1: Exchange the code for an access token + accessToken, _, err := exchangeCodeForToken(authCode) + if err != nil { + return stacktrace.Propagate(err, "An error occurred retrieving access token for publishing pakcage.") + } + logrus.Infof("Access Token for GitHub %v", accessToken) + + // Step 2: create ghclient authed with user acccess + ts := oauth2.StaticTokenSource( + &oauth2.Token{AccessToken: accessToken}, + ) + tc := oauth2.NewClient(ctx, ts) + ghClient := github.NewClient(tc) + logrus.Infof("Successfully created authed github client using access token: %v", accessToken) + + // Step 3: Create a new repository + repo, err := createRepo(ctx, ghClient, accessToken, packageName) + if err != nil { + fmt.Println("Error creating repository:", err) + return stacktrace.Propagate(err, "An error occurred creating repo for publishing package.") + } + logrus.Infof("Repo creation success: %v", repo) + + // Step 4: Create blob data for files to be committed + files := []BlobData{ + {Path: "main.star", Content: serializedStarlarkScript}, + {Path: "kurtosis.yml", Content: fmt.Sprintf("name: github.com/%v/%v", "tedim52", "basic-package")}, + {Path: "kurtosis-package-icon.png", Content: string(serializedPackageIcon)}, + //{Path: "README_K.md", Content: getPackageReadMeContents(repo.Owner.Login, packageName) }, + } + + time.Sleep(10 * time.Second) + + baseTreeSha, err := getBaseTreeSha(ctx, ghClient, *repo.Owner.Login, packageName, "main") + if err != nil { + return stacktrace.Propagate(err, "An error occurred getting base tree") + } + logrus.Infof("Base tree SHA successfully retrieved: %v", baseTreeSha) + + treeSha, err := createTree(ctx, ghClient, accessToken, *repo.Owner.Login, packageName, baseTreeSha, files) + if err != nil { + return stacktrace.Propagate(err, "An error occurred creating tree.") + } + logrus.Infof("Tree successfully created: %v", treeSha) + + // Step 6: Create a commit + message := "Creating package!" // Replace with the commit message + commitSha, err := createCommit(ctx, ghClient, *repo.Owner.Login, packageName, message, treeSha, baseTreeSha) + if err != nil { + return stacktrace.Propagate(err, "An error occurred creating commit to publish package.") + } + fmt.Println("Commit created. SHA:", commitSha) + + // Step 7: Update reference + err = updateReference(ctx, ghClient, *repo.Owner.Login, packageName, commitSha) + if err != nil { + return stacktrace.Propagate(err, "An error occurred updating reference.") + } + return nil +} + +func exchangeCodeForToken(code string) (string, string, error) { + // Construct the URL for exchanging code for token + tokenURL := fmt.Sprintf("https://github.com/login/oauth/access_token?client_id=%s&client_secret=%s&code=%s", clientID, clientSecret, code) + + // Make a POST request to the token URL + resp, err := http.PostForm(tokenURL, url.Values{}) + if err != nil { + return "", "", err + } + defer resp.Body.Close() + + body, err := io.ReadAll(resp.Body) + if err != nil { + return "", "", err + } + logrus.Infof("access token request body: %v", string(body)) + + // Parse the response to extract the access token + values, err := url.ParseQuery(string(body)) + if err != nil { + return "", "", err + } + + accessToken := values.Get("access_token") + if accessToken == "" { + return "", "", fmt.Errorf("access_token not found in response") + } + + scope := values.Get("scope") + + return accessToken, scope, nil +} + +func createRepo(ctx context.Context, client *github.Client, accessToken string, packageName string) (*github.Repository, error) { + packageTemplateRepoReq := &github.TemplateRepoRequest{ + Name: &packageName, + Owner: nil, + Description: nil, + IncludeAllBranches: nil, + Private: nil, + } + template, _, err := client.Repositories.CreateFromTemplate(ctx, "kurtosis-tech", "package-template-repo", packageTemplateRepoReq) + if err != nil { + return nil, stacktrace.Propagate(err, "An error occurred creating repository from template.") + } + //logrus.Infof("Response body from create repo call %v", resp) + //logrus.Infof("Result from create repo call %v", template) + return template, nil +} + +func createTree(ctx context.Context, client *github.Client, accessToken, owner, repo, baseTreeSha string, files []BlobData) (string, error) { + // Create a slice to hold tree entries + var entries []*github.TreeEntry + + // Create blobs and add them to the tree + for _, file := range files { + // Create a new blob object + encodedContent := base64.StdEncoding.EncodeToString([]byte(file.Content)) + blob := &github.Blob{ + Content: github.String(encodedContent), + Encoding: github.String("base64"), + } + + // Create the blob in the repository + createdBlob, _, err := client.Git.CreateBlob(ctx, owner, repo, blob) + if err != nil { + return "", err + } + + // Create a new tree entry for the blob + entry := &github.TreeEntry{ + Path: github.String(file.Path), + Mode: github.String("100644"), // File mode + Type: github.String("blob"), + SHA: createdBlob.SHA, + } + + entries = append(entries, entry) + } + + // Create the tree with the new entries + tree, _, err := client.Git.CreateTree(ctx, owner, repo, baseTreeSha, entries) + if err != nil { + return "", err + } + + return tree.GetSHA(), nil +} + +func createCommit(ctx context.Context, client *github.Client, owner, repo, message, treeSha, parentSha string) (string, error) { + commit := &github.Commit{ + Message: github.String(message), + Tree: &github.Tree{SHA: github.String(treeSha)}, + Parents: []*github.Commit{{SHA: github.String(parentSha)}}, + } + createCommitOpts := &github.CreateCommitOptions{} + createdCommit, _, err := client.Git.CreateCommit(ctx, owner, repo, commit, createCommitOpts) + if err != nil { + return "", err + } + return createdCommit.GetSHA(), nil +} + +func updateReference(ctx context.Context, client *github.Client, owner, repo, commitSha string) error { + ref := "refs/heads/main" + force := true + + // Create a new reference object + gitRef := &github.Reference{ + Ref: github.String(ref), + Object: &github.GitObject{SHA: github.String(commitSha)}, + } + + // Update the reference in the repository + _, _, err := client.Git.UpdateRef(ctx, owner, repo, gitRef, force) + if err != nil { + return err + } + + return nil +} + +func getBaseTreeSha(ctx context.Context, client *github.Client, owner, repo, branch string) (string, error) { + ref := fmt.Sprintf("refs/heads/%s", branch) + + // Get the reference for the branch + gitRef, _, err := client.Git.GetRef(ctx, owner, repo, ref) + if err != nil { + return "", err + } + + if gitRef.Object == nil || gitRef.Object.SHA == nil { + return "", fmt.Errorf("commit SHA not found in response") + } + + return *gitRef.Object.SHA, nil +} + +//func getPackageReadMeContents(owner, repoName string) string { +// // TODO: turn this into a go template to parametrize owner and repo name +// readMeBytes, err := os.ReadFile("./README_.md.tmpl") +// if err != nil { +// panic(err) +// } +// return string(readMeBytes) +//} diff --git a/enclave-manager/server/server.go b/enclave-manager/server/server.go index 0dc33868a7..4d8ad78fea 100644 --- a/enclave-manager/server/server.go +++ b/enclave-manager/server/server.go @@ -425,6 +425,25 @@ func (c *WebServer) AddAlias(ctx context.Context, req *connect.Request[kurtosis_ } +func (c *WebServer) PublishPackageRepository(ctx context.Context, req *connect.Request[kurtosis_enclave_manager_api_bindings.PublishPackageRequest]) (*connect.Response[emptypb.Empty], error) { + isValidRequest, _, err := c.ValidateRequestAuthorization(ctx, c.enforceAuth, req.Header()) + if err != nil { + return nil, stacktrace.Propagate(err, "Authentication attempt failed") + } + if !isValidRequest { + return nil, stacktrace.Propagate(err, "User not authorized") + } + + err = PublishPackageRepository(ctx, req.Msg.AuthCode, req.Msg.PackageName, req.Msg.SerializedStarlarkScript, req.Msg.SerializedPackageIcon) + if err != nil { + logrus.Errorf("An error occurred publishing package: %v", err) + return nil, stacktrace.Propagate(err, "An error occurred publishing package repo") + } + logrus.Info("Successfully published package.") + + return &connect.Response[emptypb.Empty]{}, nil +} + func (c *WebServer) LockPort(ctx context.Context, req *connect.Request[kurtosis_enclave_manager_api_bindings.LockUnlockPortRequest]) (*connect.Response[emptypb.Empty], error) { if !c.enforceAuth { return nil, stacktrace.NewError("This method is only available in the cloud") @@ -983,7 +1002,7 @@ func RunEnclaveManagerApiServer(enforceAuth bool) error { ) emCors := cors.AllowAll() - emCors.Log = logrus.StandardLogger() + //emCors.Log = logrus.StandardLogger() if err := apiServer.RunServerUntilInterruptedWithCors(emCors); err != nil { logrus.Error("An error occurred running the server", err) diff --git a/enclave-manager/web/packages/app/src/client/enclaveManager/KurtosisClient.ts b/enclave-manager/web/packages/app/src/client/enclaveManager/KurtosisClient.ts index 9115cac0f2..38762654e7 100644 --- a/enclave-manager/web/packages/app/src/client/enclaveManager/KurtosisClient.ts +++ b/enclave-manager/web/packages/app/src/client/enclaveManager/KurtosisClient.ts @@ -27,6 +27,7 @@ import { GetStarlarkRunRequest, InspectFilesArtifactContentsRequest, LockUnlockPortRequest, + PublishPackageRequest, RunStarlarkPackageRequest, RunStarlarkScriptRequest, StarlarkPackagePlanYamlArgs as StarlarkPackagePlanYamlArgsRequest, @@ -103,6 +104,26 @@ export abstract class KurtosisClient { ); } + async publishPackageRequest( + githubAuthCode: string, + packageName: string, + serializedStarlarkScript: string, + serializedPackageIcon?: Uint8Array, + ) { + return asyncResult( + this.client.publishPackageRepository( + new PublishPackageRequest({ + authCode: githubAuthCode, + packageName: packageName, + serializedStarlarkScript: serializedStarlarkScript, + serializedPackageIcon: serializedPackageIcon, + }), + this.getHeaderOptions(), + ), + `KurtosisClient could not public package result for ${packageName}`, + ); + } + async addAlias(portNumber: number, serviceShortUUID: string, enclaveShortUUID: string, alias: string) { return asyncResult( this.client.addAlias( diff --git a/enclave-manager/web/packages/app/src/emui/enclaves/components/BuildEnclave.tsx b/enclave-manager/web/packages/app/src/emui/enclaves/components/BuildEnclave.tsx index 9d69a22305..b30de91ca4 100644 --- a/enclave-manager/web/packages/app/src/emui/enclaves/components/BuildEnclave.tsx +++ b/enclave-manager/web/packages/app/src/emui/enclaves/components/BuildEnclave.tsx @@ -14,6 +14,16 @@ export const BuildEnclave = () => { setBuildEnclaveOpen(location.hash === `#${KURTOSIS_BUILD_ENCLAVE_URL_ARG}`); }, [location]); + useEffect(() => { + const query = new URLSearchParams(location.search); + const code = query.get("code"); + if (code) { + console.log(`code ${code}`) + window.opener.postMessage({ code }, "http://localhost:4000"); + window.close(); + } + }, []); + const handleCloseBuildEnclave = () => { setBuildEnclaveOpen(false); if (isDefined(location.hash)) { diff --git a/enclave-manager/web/packages/app/src/emui/enclaves/components/configuration/PackageSelector.tsx b/enclave-manager/web/packages/app/src/emui/enclaves/components/configuration/PackageSelector.tsx index be0059a68c..597ed5d2ca 100644 --- a/enclave-manager/web/packages/app/src/emui/enclaves/components/configuration/PackageSelector.tsx +++ b/enclave-manager/web/packages/app/src/emui/enclaves/components/configuration/PackageSelector.tsx @@ -1,6 +1,7 @@ import { SmallCloseIcon } from "@chakra-ui/icons"; import { Button, + Divider, Flex, Icon, Input, @@ -8,6 +9,11 @@ import { InputLeftElement, InputRightElement, Spinner, + Tab, + TabList, + TabPanel, + TabPanels, + Tabs, Text, } from "@chakra-ui/react"; import { KurtosisPackage } from "kurtosis-cloud-indexer-sdk"; @@ -105,7 +111,7 @@ export const PackageSelector = ({ onPackageSelected }: PackageSelectorProps) => } return ( - <> + @@ -128,66 +134,80 @@ export const PackageSelector = ({ onPackageSelected }: PackageSelectorProps) => )} - {isDefined(exactMatch) && ( - - - Exact Match - - {exactMatch.type === "loading" && ( - - - Looking for a Kurtosis Package at {exactMatch.url} + + + Kurtosis Packages + Docker-compose Packages + + + + + + {isDefined(exactMatch) && ( + + + Exact Match + + {exactMatch.type === "loading" && ( + + + Looking for a Kurtosis Package at {exactMatch.url} + + )} + {exactMatch.type === "loaded" && ( + onPackageSelected(exactMatch.package)} + /> + )} + {exactMatch.type === "error" && ( + + )} )} - {exactMatch.type === "loaded" && ( - onPackageSelected(exactMatch.package)} - /> + {(searchTerm.length > 0 || savedPackages.length === 0) && ( + + + {searchTerm.length === 0 ? "All Packages" : "Search Results"} + + {searchResults.value.map((kurtosisPackage) => ( + onPackageSelected(kurtosisPackage)} + /> + ))} + )} - {exactMatch.type === "error" && ( - + {searchTerm.length === 0 && savedPackages.length > 0 && ( + + + Saved + + {savedPackages.map((kurtosisPackage) => ( + onPackageSelected(kurtosisPackage)} + /> + ))} + + All Packages + + {searchResults.value.map((kurtosisPackage) => ( + onPackageSelected(kurtosisPackage)} + /> + ))} + )} - - )} - {(searchTerm.length > 0 || savedPackages.length === 0) && ( - - - {searchTerm.length === 0 ? "All Packages" : "Search Results"} - - {searchResults.value.map((kurtosisPackage) => ( - onPackageSelected(kurtosisPackage)} - /> - ))} - - )} - {searchTerm.length === 0 && savedPackages.length > 0 && ( - - - Saved - - {savedPackages.map((kurtosisPackage) => ( - onPackageSelected(kurtosisPackage)} - /> - ))} - - All Packages - - {searchResults.value.map((kurtosisPackage) => ( - onPackageSelected(kurtosisPackage)} - /> - ))} - - )} - + + +

Docker compose!

+
+ +
); }; diff --git a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/EnclaveBuilderDrawer.tsx b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/EnclaveBuilderDrawer.tsx index 781622f5a1..cc18aa0c4b 100644 --- a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/EnclaveBuilderDrawer.tsx +++ b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/EnclaveBuilderDrawer.tsx @@ -21,8 +21,10 @@ import { Edge, Node, ReactFlowProvider } from "reactflow"; import "reactflow/dist/style.css"; import { useEnclavesContext } from "../../EnclavesContext"; import { EnclaveFullInfo } from "../../types"; +import { PublishRepoModal } from "./modals/PublishRepoModal"; import { ViewStarlarkModal } from "./modals/ViewStarlarkModal"; import { KurtosisNodeData } from "./types"; +import { UIStateProvider } from "./UIStateContext"; import { getInitialGraphStateFromEnclave } from "./utils"; import { useVariableContext, VariableContextProvider } from "./VariableContextProvider"; import { Visualiser, VisualiserImperativeAttributes } from "./Visualiser"; @@ -33,6 +35,8 @@ type EnclaveBuilderDrawerProps = { existingEnclave?: RemoveFunctions; }; +const CLIENT_ID = `Iv23liicwMSrJ7dqrqdO`; + export const EnclaveBuilderDrawer = (props: EnclaveBuilderDrawerProps) => { const variableContextKey = useRef(0); const [error, setError] = useState(); @@ -81,9 +85,13 @@ export const EnclaveBuilderDrawer = (props: EnclaveBuilderDrawerProps) => { } return ( - - - + + + + + + + ); }; @@ -112,6 +120,8 @@ const EnclaveBuilderDrawerImpl = ({ const [isLoading, setIsLoading] = useState(false); const [error, setError] = useState(); const [currentStarlarkPreview, setCurrentStarlarkPreview] = useState(); + const [isPublishModalOpen, setIsPublishModalOpen] = useState(false); + const [code, setCode] = useState(""); const handleRun = async () => { if (!isDefined(visualiserRef.current)) { @@ -157,6 +167,28 @@ const EnclaveBuilderDrawerImpl = ({ setCurrentStarlarkPreview(visualiserRef.current?.getStarlark() || "Unable to render"); }; + const handlePublish = () => { + const REDIRECT_URI = `http://localhost:4000`; + // const authUrl = `https://github.com/login/oauth/authorize?client_id=${CLIENT_ID}&scope=repo,read:user,workflow&redirect_uri=${encodeURIComponent( + // REDIRECT_URI, + // )}`; + const authUrl = `https://github.com/apps/kurtosis-test-app/installations/new/permissions?target_id=46531991` + const windowFeatures = "popup=yes, width=400, height=600"; + window.open(authUrl, undefined, windowFeatures); + + window.addEventListener( + "message", + (event: MessageEvent) => { + if (event.data.code) { + console.log(event.data.code); + setCode(event.data.code); + setIsPublishModalOpen(true); + } + }, + false, + ); + }; + return ( null} closeOnEsc={false}> @@ -167,14 +199,12 @@ const EnclaveBuilderDrawerImpl = ({ {isDefined(error) && } - - - + @@ -182,6 +212,7 @@ const EnclaveBuilderDrawerImpl = ({ Close + setCurrentStarlarkPreview(undefined)} starlark={currentStarlarkPreview} /> + setIsPublishModalOpen(false)} + code={code} + starlark={visualiserRef.current?.getStarlark()} + /> ); }; diff --git a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/Toolbar.tsx b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/Toolbar.tsx index 1c23d8f97f..52f6f7abe4 100644 --- a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/Toolbar.tsx +++ b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/Toolbar.tsx @@ -1,55 +1,20 @@ -import { Box, Button, ButtonGroup, Icon } from "@chakra-ui/react"; -import Dagre from "@dagrejs/dagre"; -import { useCallback, useRef } from "react"; -import { FiShare2 } from "react-icons/fi"; -import { Edge, Node, useOnViewportChange, useReactFlow, XYPosition } from "reactflow"; +import { Box, Button, ButtonGroup, Flex, Icon, Menu, MenuButton, MenuItem, MenuList } from "@chakra-ui/react"; +import { useRef } from "react"; +import { FiDownload, FiGrid, FiPlus } from "react-icons/fi"; +import { Node, useOnViewportChange, useReactFlow, XYPosition } from "reactflow"; import { v4 as uuidv4 } from "uuid"; import { nodeIcons } from "./nodes/KurtosisNode"; +import { useUIState } from "./UIStateContext"; import { useVariableContext } from "./VariableContextProvider"; -const g = new Dagre.graphlib.Graph().setDefaultEdgeLabel(() => ({})); -const getLayoutedElements = (nodes: Node[], edges: Edge[]) => { - if (nodes.length === 0) { - return { nodes, edges }; - } - g.setGraph({ rankdir: "LR", ranksep: 100 }); - - edges.forEach((edge) => g.setEdge(edge.source, edge.target)); - nodes.forEach((node) => - g.setNode(node.id, node as Node<{ label: string }, string | undefined> & { width?: number; height?: number }), - ); - - Dagre.layout(g); - - return { - nodes: nodes.map((node) => { - const { x, y } = g.node(node.id); - - return { ...node, position: { x, y } }; - }), - edges, - }; -}; - export const Toolbar = () => { const insertOffset = useRef(0); const { updateData } = useVariableContext(); - const { fitView, getViewport, getNodes, getEdges, addNodes, setNodes, setEdges } = useReactFlow(); - - useOnViewportChange({ onEnd: () => (insertOffset.current = 1) }); + const { getViewport, addNodes } = useReactFlow(); - const onLayout = useCallback(() => { - const nodes = getNodes(); - const edges = getEdges(); - const layouted = getLayoutedElements(nodes, edges); + const { applyAutoLayout, toggleExpanded, zoomToNode } = useUIState(); - setNodes([...layouted.nodes]); - setEdges([...layouted.edges]); - - window.requestAnimationFrame(() => { - fitView(); - }); - }, [fitView, setEdges, setNodes, getEdges, getNodes]); + useOnViewportChange({ onEnd: () => (insertOffset.current = 1) }); const getNewNodePosition = (): XYPosition => { const viewport = getViewport(); @@ -57,6 +22,12 @@ export const Toolbar = () => { return { x: -viewport.x + insertOffset.current * 20 + 400, y: -viewport.y + insertOffset.current * 20 }; }; + const addAndFocusNode = (node: Node) => { + addNodes(node); + toggleExpanded(node.id); + setTimeout(() => zoomToNode(node), 0); + }; + const handleAddServiceNode = () => { const id = uuidv4(); updateData(id, { @@ -80,7 +51,7 @@ export const Toolbar = () => { entrypoint: "", isValid: false, }); - addNodes({ + addAndFocusNode({ id, position: getNewNodePosition(), width: 650, @@ -100,7 +71,7 @@ export const Toolbar = () => { acceptableCodes: [], isValid: false, }); - addNodes({ + addAndFocusNode({ id, position: getNewNodePosition(), width: 650, @@ -113,7 +84,7 @@ export const Toolbar = () => { const handleAddArtifactNode = () => { const id = uuidv4(); updateData(id, { type: "artifact", name: "", files: {}, isValid: false }); - addNodes({ + addAndFocusNode({ id, position: getNewNodePosition(), width: 400, @@ -147,7 +118,7 @@ export const Toolbar = () => { wait: "", isValid: false, }); - addNodes({ + addAndFocusNode({ id, position: getNewNodePosition(), width: 650, @@ -182,7 +153,7 @@ export const Toolbar = () => { wait: "", isValid: false, }); - addNodes({ + addAndFocusNode({ id, position: getNewNodePosition(), width: 650, @@ -202,8 +173,9 @@ export const Toolbar = () => { locator: "", isValid: false, }); - addNodes({ + addAndFocusNode({ id, + selected: true, position: getNewNodePosition(), width: 900, style: { width: "900px" }, @@ -223,26 +195,43 @@ export const Toolbar = () => { p={"8px"} > - - - - - - - diff --git a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/UIStateContext.tsx b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/UIStateContext.tsx new file mode 100644 index 0000000000..63f53ba5be --- /dev/null +++ b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/UIStateContext.tsx @@ -0,0 +1,95 @@ +import { Edge, Node, useReactFlow } from "reactflow"; + +import Dagre from "@dagrejs/dagre"; +import { createContext, PropsWithChildren, useCallback, useContext, useState } from "react"; + +// Define the context +const UIContext = createContext<{ + expandedNodes: Record; + toggleExpanded: (nodeId: string) => void; + applyAutoLayout: () => void; + zoomToNode: (node: Node) => void; +}>({ + expandedNodes: {}, + toggleExpanded: () => {}, + applyAutoLayout: () => {}, + zoomToNode: () => {}, +}); + +// Graph layout for auto-layouting the nodes +const g = new Dagre.graphlib.Graph().setDefaultEdgeLabel(() => ({})); +const getLayoutedElements = (nodes: Node[], edges: Edge[]) => { + if (nodes.length === 0) { + return { nodes, edges }; + } + g.setGraph({ rankdir: "LR", ranksep: 200, nodesep: 200 }); + + edges.forEach((edge) => g.setEdge(edge.source, edge.target)); + nodes.forEach((node) => + g.setNode(node.id, node as Node<{ label: string }, string | undefined> & { width?: number; height?: number }), + ); + + Dagre.layout(g); + + return { + nodes: nodes.map((node) => { + const { x, y } = g.node(node.id); + + return { ...node, position: { x, y } }; + }), + edges, + }; +}; + +// Define the provider +export const UIStateProvider = ({ children }: PropsWithChildren) => { + const [expandedNodes, setExpandedNodes] = useState>({}); + + const { fitView, getNodes, getEdges, setNodes, setEdges } = useReactFlow(); + + // Toggles whether a node is expanded or not. A node only appears expanded if + // the zoom level is zoomed in enough (see ZoomAwareNodeContent) + const toggleExpanded = useCallback( + (nodeId: string) => { + setExpandedNodes({ ...expandedNodes, [nodeId]: !expandedNodes[nodeId] }); + }, + [expandedNodes, setExpandedNodes], + ); + + // Re-layouts the graph + const applyAutoLayout = useCallback(() => { + const nodes = getNodes(); + const edges = getEdges(); + const layouted = getLayoutedElements(nodes, edges); + // Reset package node to 0, 0 or zooming gets weird + const packageNode = layouted.nodes.find((node) => node.type === "packageNode"); + if (packageNode != null) { + packageNode.position = { x: 0, y: 0 }; + } + + setNodes([...layouted.nodes]); + setEdges([...layouted.edges]); + + window.requestAnimationFrame(() => { + fitView({ nodes: layouted.nodes, duration: 500 }); + }); + }, [setEdges, setNodes, getEdges, getNodes, fitView]); + + const zoomToNode = useCallback( + (node: Node) => { + fitView({ nodes: [node], maxZoom: 1, duration: 500 }); + }, + [fitView], + ); + + return ( + + {children} + + ); +}; + +// Define the hook +export function useUIState() { + return useContext(UIContext); +} diff --git a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/VariableContextProvider.tsx b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/VariableContextProvider.tsx index a696ed1526..3be9a14293 100644 --- a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/VariableContextProvider.tsx +++ b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/VariableContextProvider.tsx @@ -7,6 +7,8 @@ type VariableContextState = { variables: Variable[]; updateData: (id: string, data: KurtosisNodeData | ((oldData: KurtosisNodeData) => KurtosisNodeData)) => void; removeData: (id: { id: string }[]) => void; + initialImportedPackageData: null | Record; + setInitialImportedPackageData: (data: Record) => void; }; const VariableContext = createContext({ @@ -14,6 +16,8 @@ const VariableContext = createContext({ variables: [], updateData: () => null, removeData: () => null, + initialImportedPackageData: null, + setInitialImportedPackageData: () => null, }); type VariableContextProviderProps = { @@ -22,6 +26,11 @@ type VariableContextProviderProps = { export const VariableContextProvider = ({ initialData, children }: PropsWithChildren) => { const [data, setData] = useState>(initialData); + // A snapshot of the imported package data so we can compare changes the user + // makes to the original configuration and generate the appropriate Starlark code + const [initialImportedPackageData, setInitialImportedPackageData] = useState | null>( + null, + ); const variables = useMemo((): Variable[] => { return getVariablesFromNodes(data); @@ -45,7 +54,11 @@ export const VariableContextProvider = ({ initialData, children }: PropsWithChil }, []); return ( - {children} + + {children} + ); }; diff --git a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/Visualiser.tsx b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/Visualiser.tsx index c255ba2585..71b44f6822 100644 --- a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/Visualiser.tsx +++ b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/Visualiser.tsx @@ -1,16 +1,16 @@ import { Box, Flex } from "@chakra-ui/react"; import { RemoveFunctions } from "kurtosis-ui-components"; -import { forwardRef, useCallback, useEffect, useImperativeHandle, useRef } from "react"; +import { forwardRef, useCallback, useEffect, useImperativeHandle, useRef, useState } from "react"; import { Background, BackgroundVariant, Controls, Edge, + MarkerType, Node, ReactFlow, useEdgesState, useNodesState, - useReactFlow, } from "reactflow"; import { EnclaveFullInfo } from "../../types"; import { KurtosisArtifactNode } from "./nodes/KurtosisArtifactNode"; @@ -20,6 +20,7 @@ import { KurtosisPythonNode } from "./nodes/KurtosisPythonNode"; import { KurtosisServiceNode } from "./nodes/KurtosisServiceNode"; import { KurtosisShellNode } from "./nodes/KurtosisShellNode"; import { Toolbar } from "./Toolbar"; +import { useUIState } from "./UIStateContext"; import { generateStarlarkFromGraph, getNodeDependencies } from "./utils"; import { useVariableContext } from "./VariableContextProvider"; import "./Visualiser.css"; @@ -43,33 +44,40 @@ type VisualiserProps = { }; export const Visualiser = forwardRef( ({ initialNodes, initialEdges, existingEnclave }, ref) => { - const { data } = useVariableContext(); + const { data, initialImportedPackageData } = useVariableContext(); const insertOffset = useRef(0); - const { fitView } = useReactFlow(); const [nodes, , onNodesChange] = useNodesState(initialNodes || []); const [edges, setEdges, onEdgesChange] = useEdgesState(initialEdges || []); + // TODO(skylar): make this work for multiple packages? + const [shouldApplyAutoLayout, setShouldApplyAutoLayout] = useState(false); + const { expandedNodes, applyAutoLayout, zoomToNode } = useUIState(); - const handleNodeDoubleClick = useCallback( + const handleNodeClick = useCallback( (e: React.MouseEvent, node: Node) => { - fitView({ nodes: [node], maxZoom: 1, duration: 500 }); + // Only zoom to node if it is not expanded (i.e. it is about to be expanded) + if (expandedNodes[node.id]) { + return; + } + zoomToNode(node); }, - [fitView], + [zoomToNode, expandedNodes], ); useEffect(() => { setEdges((prevState) => { - return Object.entries(getNodeDependencies(data)).flatMap(([to, froms]) => + const nextEdges = Object.entries(getNodeDependencies(data)).flatMap(([to, froms]) => [...froms].map((from) => ({ id: `${from}-${to}`, source: from, target: to, - animated: true, - type: "straight", - style: { strokeWidth: "3px" }, })), ); + if (nextEdges.length > 0) { + setShouldApplyAutoLayout(true); + } + return nextEdges; }); - }, [setEdges, data]); + }, [setEdges, data, applyAutoLayout]); // Remove the resizeObserver error useEffect(() => { @@ -96,12 +104,18 @@ export const Visualiser = forwardRef ({ getStarlark: () => { - return generateStarlarkFromGraph(nodes, edges, data, existingEnclave); + return generateStarlarkFromGraph(nodes, edges, data, initialImportedPackageData, existingEnclave); }, }), - [nodes, edges, data, existingEnclave], + [nodes, edges, data, initialImportedPackageData, existingEnclave], ); + useEffect(() => { + if (shouldApplyAutoLayout) { + applyAutoLayout(); + } + }, [shouldApplyAutoLayout, applyAutoLayout]); + return ( @@ -115,12 +129,23 @@ export const Visualiser = forwardRef (insertOffset.current = 1)} onNodesChange={onNodesChange} onEdgesChange={onEdgesChange} - onNodeDoubleClick={handleNodeDoubleClick} + // TODO(skylar): fix this. it currently zooms to a random place off the top of the graph + onNodeClick={handleNodeClick} nodeTypes={nodeTypes} fitView + snapToGrid + onlyRenderVisibleElements={false} // This is required to prevent the package node from re-fetching data when it is re-rendered + defaultEdgeOptions={{ + focusable: false, + animated: false, + style: { strokeWidth: "2px" }, + markerEnd: { + type: MarkerType.ArrowClosed, + }, + }} > - + diff --git a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/modals/PublishRepoModal.tsx b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/modals/PublishRepoModal.tsx new file mode 100644 index 0000000000..7a9d28fca5 --- /dev/null +++ b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/modals/PublishRepoModal.tsx @@ -0,0 +1,114 @@ +import { + Box, + Button, + FormControl, + FormLabel, + Image, + Input, + Modal, + ModalBody, + ModalCloseButton, + ModalContent, + ModalFooter, + ModalHeader, + ModalOverlay, +} from "@chakra-ui/react"; +import { isDefined } from "kurtosis-ui-components"; +import { ChangeEvent, useState } from "react"; +import { useKurtosisClient } from "../../../../../client/enclaveManager/KurtosisClientContext"; + +type PublishRepoModalProps = { + isOpen: boolean; + onClose: () => void; + code: string; + starlark?: string; +}; + +export const PublishRepoModal = ({ isOpen, onClose, code, starlark }: PublishRepoModalProps) => { + const [repoName, setRepoName] = useState("basic-package"); + const [image, setImage] = useState(null); + const kurtosisClient = useKurtosisClient(); + + const handleImageChange = (e: ChangeEvent) => { + if (e.target.files && e.target.files[0]) { + setImage(e.target.files[0]); + } + }; + + const getImageData = (file: File): Promise => { + return new Promise((resolve, reject) => { + const reader = new FileReader(); + reader.onload = (event) => { + const arrayBuffer = event.target?.result as ArrayBuffer; + if (arrayBuffer) { + const uint8Array = new Uint8Array(arrayBuffer); + resolve(uint8Array); + } else { + reject(new Error("Failed to read file as ArrayBuffer.")); + } + }; + reader.onerror = (error) => { + reject(error); + }; + reader.readAsArrayBuffer(file); + }); + }; + + const handlePublishSubmit = async () => { + console.log("Repository Name:", repoName); + + let imageData: Uint8Array = new Uint8Array(100); + if (image) { + imageData = await getImageData(image); + } + console.log("Uploaded Image:", image); + + if (!isDefined(starlark)) { + console.log("starlark not defined which is unexpected"); + return; + } + + const resp = await kurtosisClient.publishPackageRequest(code, repoName, starlark, imageData); + if (resp.isOk) { + console.log(`successfully published package`); + } else { + console.log(`did not successfully publish package`); + } + return; + }; + + return ( + + + + Enter Repository Details + + + + Package Name + setRepoName(e.target.value)} /> + + + Upload Package Icon + + {image && ( + + Uploaded image + + )} + + + + + + + + + ); +}; diff --git a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/modals/ViewStarlarkModal.tsx b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/modals/ViewStarlarkModal.tsx index 16435e6f4f..ea9b2c947f 100644 --- a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/modals/ViewStarlarkModal.tsx +++ b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/modals/ViewStarlarkModal.tsx @@ -16,6 +16,7 @@ type ViewStarlarkModalProps = { onClose: () => void; starlark?: string; }; + export const ViewStarlarkModal = ({ isOpen, onClose, starlark }: ViewStarlarkModalProps) => { return ( diff --git a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/nodes/KurtosisNode.tsx b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/nodes/KurtosisNode.tsx index 7c31b8d599..9e284969b5 100644 --- a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/nodes/KurtosisNode.tsx +++ b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/nodes/KurtosisNode.tsx @@ -7,6 +7,7 @@ import { FiCpu, FiFile, FiPackage, FiTerminal, FiTrash } from "react-icons/fi"; import { RxCornerBottomRight } from "react-icons/rx"; import { Handle, NodeResizeControl, Position, useReactFlow, useViewport } from "reactflow"; import { KurtosisNodeData } from "../types"; +import { useUIState } from "../UIStateContext"; import { useVariableContext } from "../VariableContextProvider"; const colors: Record = { @@ -44,17 +45,18 @@ type KurtosisNodeProps = PropsWithChildren<{ // Optional element to show outside of the zoom aware behaviour portalContent?: ReactElement; backgroundColor?: string; + onClick?: () => void; }>; export const KurtosisNode = memo( ({ + backgroundColor, + children, id, - selected, - minWidth, maxWidth, + minWidth, portalContent, - backgroundColor, - children, + selected, }: KurtosisNodeProps) => { const { data } = useVariableContext(); const nodeData = data[id] as DataType; @@ -65,13 +67,13 @@ export const KurtosisNode = memo( return ( + backgroundColor={backgroundColor} id={id} - selected={selected} - minWidth={minWidth} maxWidth={maxWidth} + minWidth={minWidth} nodeData={nodeData} portalContent={portalContent} - backgroundColor={backgroundColor} + selected={selected} > {children} @@ -81,32 +83,34 @@ export const KurtosisNode = memo( type KurtosisNodeImplProps = KurtosisNodeProps & { nodeData: DataType }; const KurtosisNodeImpl = ({ + backgroundColor, + children, id, - nodeData, - selected, - minWidth, maxWidth, + minWidth, + nodeData, portalContent, - backgroundColor, - children, }: KurtosisNodeImplProps) => { + const { expandedNodes, toggleExpanded } = useUIState(); + + const selected = Boolean(expandedNodes[id]); + if (!selected) { return ( <> - {" "} - + toggleExpanded(id)} /> ); } @@ -120,6 +124,7 @@ const KurtosisNodeImpl = ({ nodeData={nodeData} portalContent={portalContent} backgroundColor={backgroundColor} + onClick={() => toggleExpanded(id)} > {children} @@ -186,9 +191,6 @@ const KurtosisFormNode = ({ flexDirection={"column"} height={"100%"} borderRadius={"8px"} - borderWidth={"3px"} - outline={"3px solid transparent"} - outlineOffset={"3px"} boxShadow={selected ? `0 0 0 4px ${chakraColor}` : undefined} _hover={{ boxShadow: !selected ? `0 0 0 1px ${chakraColor}` : undefined }} borderColor={color} @@ -198,13 +200,13 @@ const KurtosisFormNode = ({ ({ ) => void; }>; -const ZoomAwareNodeContent = ({ name, type, isDisabled, onDelete, children }: ZoomAwareNodeContentProps) => { +const ZoomAwareNodeContent = ({ name, type, isDisabled, id, onDelete, children }: ZoomAwareNodeContentProps) => { const viewport = useViewport(); return ( - + {children} ); @@ -257,7 +269,8 @@ const ZoomAwareNodeContent = ({ name, type, isDisabled, onDelete, children }: Zo type ZoomAwareNodeContentImplProps = ZoomAwareNodeContentProps & { zoom: number }; const ZoomAwareNodeContentImpl = memo( - ({ name, type, isDisabled, onDelete, zoom, children }: ZoomAwareNodeContentImplProps) => { + ({ name, type, isDisabled, id, onDelete, zoom, children }: ZoomAwareNodeContentImplProps) => { + const { toggleExpanded } = useUIState(); const { zoomOut, zoomIn } = useReactFlow(); const handleScroll = useCallback( (e: React.WheelEvent) => { @@ -280,7 +293,14 @@ const ZoomAwareNodeContentImpl = memo( return ( <> - + toggleExpanded(id)} + > {name || Unnamed} @@ -320,10 +340,24 @@ const ZoomAwareNodeContentImpl = memo( type BasicKurtosisNodeProps = { type: KurtosisNodeData["type"]; name?: string; + onClick?: () => void; }; -const BasicKurtosisNode = ({ type, name }: BasicKurtosisNodeProps) => { + +const BasicKurtosisNode = ({ type, name, onClick }: BasicKurtosisNodeProps) => { return ( - + {name || Unnamed} diff --git a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/nodes/KurtosisPackageNode.tsx b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/nodes/KurtosisPackageNode.tsx index 0e6d39ca74..4011ddff86 100644 --- a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/nodes/KurtosisPackageNode.tsx +++ b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/nodes/KurtosisPackageNode.tsx @@ -17,11 +17,12 @@ type Mode = { type: "loading" } | { type: "error"; error: string } | { type: "re export const KurtosisPackageNode = memo( ({ id, selected }: NodeProps) => { - const { getNodes, deleteElements, setNodes } = useReactFlow(); + const { getNodes, deleteElements, setNodes, getEdges } = useReactFlow(); const [showPackageConfigModal, setShowPackageConfigModal] = useState(false); const [mode, setMode] = useState({ type: "ready" }); const kurtosisClient = useKurtosisClient(); - const { data, updateData, removeData } = useVariableContext(); + const { data, updateData, removeData, initialImportedPackageData, setInitialImportedPackageData } = + useVariableContext(); const nodeData = data[id] as KurtosisPackageNodeData | undefined; useEffect(() => { @@ -302,6 +303,15 @@ export const KurtosisPackageNode = memo( updateData, ]); + // If we import a package, save a snapshot of the initial configuration + // so we can calculate differential updates to the Starlark code later + useEffect(() => { + if (initialImportedPackageData == null && Object.values(data).some((node) => node.isFromPackage)) { + console.log("Saving initial imported package data", data); + setInitialImportedPackageData(data); + } + }, [data, initialImportedPackageData, setInitialImportedPackageData]); + if (!isDefined(nodeData)) { return null; } diff --git a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/nodes/KurtosisServiceNode.tsx b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/nodes/KurtosisServiceNode.tsx index 06f6912dcd..714f07baed 100644 --- a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/nodes/KurtosisServiceNode.tsx +++ b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/nodes/KurtosisServiceNode.tsx @@ -45,9 +45,11 @@ export const KurtosisServiceNode = memo( name={"image.image"} label={"Container Image"} isRequired - isDisabled={nodeData.isFromPackage} + // isDisabled={nodeData.isFromPackage} > - + diff --git a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/utils.ts b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/utils.ts index feb174821a..1f4b09a1cb 100644 --- a/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/utils.ts +++ b/enclave-manager/web/packages/app/src/emui/enclaves/components/enclaveBuilder/utils.ts @@ -256,6 +256,7 @@ export function generateStarlarkFromGraph( nodes: Node[], edges: Edge[], data: Record, + initialImportedPackageData: Record | null, existingEnclave?: RemoveFunctions, ): string { const nodeLookup = nodes.reduce((acc: Record, cur) => ({ ...acc, [cur.id]: cur }), {}); @@ -504,9 +505,35 @@ export function generateStarlarkFromGraph( } if (nodeData.type === "package") { + let setServiceCalls = ""; + // If package is imported, we detect any service images that were edited + // by the user by comparing the current data to the upstream (initial) data + // TODO(skylar): Make this more generic / handle other fields other than container image + if (initialImportedPackageData != null) { + const initialServiceNodeData = Object.fromEntries( + Object.entries(initialImportedPackageData).filter( + ([, n]) => n.type === "service" && n.isFromPackage && n.image.type === "image", + ), + ); + Object.entries(data).forEach(([id, node]) => { + if (initialServiceNodeData[id] != null) { + const initialImageName = (initialServiceNodeData[id] as KurtosisServiceNodeData).image.image; + const currentImageName = (node as KurtosisServiceNodeData).image.image; + if (initialImageName !== currentImageName) { + // plan.set_service(name = "asdfasfd", config = ServiceConfig(image = "image-name")) + setServiceCalls += ` plan.set_service(\n`; + setServiceCalls += ` name = "${node.name}",\n`; + setServiceCalls += ` config = ServiceConfig(image = "${currentImageName}"),\n`; + setServiceCalls += ` )\n`; + } + } + }); + } + const packageName = normaliseNameToStarlarkVariable(nodeData.name); - starlark += ` ${packageName} = ${packageName}_module.run(plan, **${objectToStarlark(nodeData.args, 8)}`; - starlark += ` )\n\n`; + starlark += ` ${packageName} = ${packageName}_module.run(plan, **${objectToStarlark(nodeData.args, 8)}\n`; + starlark += ` )\n`; + starlark += `\n${setServiceCalls}\n`; } } diff --git a/engine/server/engine/main.go b/engine/server/engine/main.go index 262d38768f..dc65ed5496 100644 --- a/engine/server/engine/main.go +++ b/engine/server/engine/main.go @@ -31,7 +31,6 @@ import ( "github.com/kurtosis-tech/kurtosis/container-engine-lib/lib/backend_interface/objects/configs" "github.com/kurtosis-tech/kurtosis/container-engine-lib/lib/backend_interface/objects/engine" "github.com/kurtosis-tech/kurtosis/core/launcher/api_container_launcher" - em_api "github.com/kurtosis-tech/kurtosis/enclave-manager/server" "github.com/kurtosis-tech/kurtosis/engine/launcher/args" "github.com/kurtosis-tech/kurtosis/engine/launcher/args/kurtosis_backend_config" "github.com/kurtosis-tech/kurtosis/engine/server/engine/centralized_logs" @@ -225,16 +224,16 @@ func runMain() error { logrus.Debugf("error while starting the webapp: \n%v", err) } }() - - go func() { - enforceAuth := serverArgs.OnBastionHost - err = em_api.RunEnclaveManagerApiServer(enforceAuth) - if err != nil { - logrus.Fatal("an error occurred while processing the auth settings, exiting!", err) - fmt.Fprintln(logrus.StandardLogger().Out, err) - os.Exit(failureExitCode) - } - }() + // + //go func() { + // enforceAuth := serverArgs.OnBastionHost + // err = em_api.RunEnclaveManagerApiServer(enforceAuth) + // if err != nil { + // logrus.Fatal("an error occurred while processing the auth settings, exiting!", err) + // fmt.Fprintln(logrus.StandardLogger().Out, err) + // os.Exit(failureExitCode) + // } + //}() logger := logrus.StandardLogger() metricsClient, closeClientFunc, err := metrics_client.CreateMetricsClient(