summaryrefslogtreecommitdiff
path: root/README.md
blob: 564824a8f0e8b850e19d89877f95b977e2fac206 (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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
# skopos
A gRPC server that facilitates provisioning and updating containers.

## Usage
### List USB Devices
Replace IP address accordingly.
```bash
grpcurl -plaintext -import-path ./proto -proto ormos.proto -d '{}' '10.0.0.42:50052' unit.containers.v0.Ormos.ListUsbDevices
```

Example output (device not mounted):
```json
{
  "devices": [
    {
      "devicePath": "/dev/sda"
    },
    {
      "devicePath": "/dev/sda1"
    }
  ]
}
```

Example output (device mounted):
```json
{
  "devices": [
    {
      "devicePath": "/dev/sda"
    },
    {
      "devicePath": "/dev/sda1",
      "isMounted": true,
      "mountPoint": "/mnt/usb"
    }
  ]
}
```

### Mount USB Device
Replace IP address accordingly.
```bash
grpcurl -plaintext -import-path ./proto -proto ormos.proto -d '{"device_path": "/dev/sda1", "mount_point": "/mnt/usb"}' '10.0.0.42:50052' unit.containers.v0.Ormos.MountUsbDevice
```

### List Container Image Archives
Replace IP address accordingly.
```bash
grpcurl -plaintext -import-path ./proto -proto ormos.proto -d '{"path": "/mnt/usb"}' '10.0.0.42:50052' unit.containers.v0.Ormos.ListImageArchives
```

Example output:
```json
{
  "imageArchives": [
    {
      "filePath": "/mnt/usb/alpine-arm64.tar",
      "fileSizeBytes": "8468992",
      "sha256Checksum": "0b070f92dd64e2bfead9f0c494511c9ce486f18900ec8297f374e5000a5f2994"
    }
  ]
}

```

### Unmount USB Device
Replace IP address accordingly.
```bash
grpcurl -plaintext -import-path ./proto -proto ormos.proto -d '{"mount_point": "/mnt/usb"}' '10.0.0.42:50052' unit.containers.v0.Ormos.UnmountUsbDevice
```