summaryrefslogtreecommitdiff
path: root/proto/ormos.proto
blob: 05ae66104d0fb9c59139ee7c1850039ed8e88123 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
syntax = "proto3";

package unit.containers.v0;

service Ormos {
  rpc ListUsbDevices (ListUsbDevicesRequest) returns (ListUsbDevicesResponse) {}
  rpc MountUsbDevice (MountUsbDeviceRequest) returns (MountUsbDeviceResponse) {}
  rpc UnmountUsbDevice (UnmountUsbDeviceRequest) returns (UnmountUsbDeviceResponse) {}

  rpc ListImageArchives (ListImageArchivesRequest) returns (ListImageArchivesResponse) {}
}

message MountUsbDeviceRequest {
  string device_path = 1;
  string mount_point = 2;
}

message MountUsbDeviceResponse {
  bool is_success = 1;
  string error_message = 2;
}

message ListUsbDevicesRequest {}

message ListUsbDevicesResponse {
  repeated UsbDevice devices = 1;
}

message UnmountUsbDeviceRequest {
  string mount_point = 1;
}

message UnmountUsbDeviceResponse {
  bool is_success = 1;
  string error_message = 2;
}

message UsbDevice {
  string device_path = 1;
  bool is_mounted = 2;
  string mount_point = 3;
}

message ListImageArchivesRequest {
  string path = 1;
}

message ListImageArchivesResponse {
    repeated ImageArchive image_archives = 1;
}

message ImageArchive {
  string file_path = 1;
  int64 file_size_bytes = 2;
  string sha256_checksum = 3;
}