api/wasi/v1/wasi.proto

82 lines
No EOL
1.7 KiB
Protocol Buffer

syntax = "proto3";
package buildr.rpc.v1;
import "common/v1/spec.proto";
import "remote/v1/executor.proto";
message HelpRequest {
ModuleReference module_reference = 1;
}
message TaskExample {
string name = 1;
string description = 2;
TaskSpec task_spec = 3;
}
message HelpResponse {
string name = 1;
string description = 2;
repeated TaskExample examples = 3;
}
message PluginInventoryRequest {
}
message PluginInventoryResponse {
message InventorySpec {
ModuleReference module_ref = 1;
bytes empty_spec = 2;
}
repeated InventorySpec specs = 1;
}
message StartTaskResponse {
string error = 1;
}
message BinaryNameRequest {
ModuleReference module_reference = 1;
ModuleSpec spec = 2;
}
message BinaryNameResponse {
string name = 1;
}
service WasiExecutorService {
rpc PluginInventory(PluginInventoryRequest) returns (PluginInventoryResponse);
rpc StartTask(StartTaskRequest) returns (StartTaskResponse);
rpc Help(HelpRequest) returns (HelpResponse);
rpc BinaryName(BinaryNameRequest) returns (BinaryNameResponse);
}
message ProcessStartRequest {
string command = 1;
repeated string args = 2;
string working_directory = 3;
map<string, string> environment = 4;
bytes stdin = 5;
}
message ProcessStartResponse {
int32 exit_code = 1;
string error = 2;
bytes stderr = 3;
}
message LookupPathRequest {
string command = 1;
}
message LookupPathResponse {
string path = 1;
string error = 2;
}
service ExecutorHostService {
rpc ProcessStart(ProcessStartRequest) returns (ProcessStartResponse);
rpc LookupPath(LookupPathRequest) returns (LookupPathResponse);
}