Skip to content

Commit 93bd7ac

Browse files
committed
README.md: add steps to run cryptpilot in a docker container
Signed-off-by: Kun Lai <[email protected]>
1 parent e71aeb4 commit 93bd7ac

File tree

2 files changed

+37
-3
lines changed

2 files changed

+37
-3
lines changed

README.md

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,45 @@ The cryptpilot project aims to provide a way that allows you to securely boot yo
88

99
# Installation
1010

11+
## Install on your system
12+
1113
You can found and install the prebuilt binaries the [latest release](https://github.com/openanolis/cryptpilot/releases). Or if you want to build it yourself, you can follow instructions from the [development guide](docs/development.md).
1214

1315
After installing, you can edit the configuration files under `/etc/cryptpilot/`. See the [configuration](docs/configuration.md) for details.
1416

17+
## Try with docker
18+
19+
If you are not running on a [supported distrubutions](#Supported Distrubutions), you can run cryptpilot in a docker container to encrypt a data volume or a bootable OS.
20+
21+
Here is an example:
22+
23+
1. First, make sure you have nbd kernel module installed.
24+
25+
```sh
26+
modprobe nbd max_part=8
27+
```
28+
29+
2. Create a container, and run your command in the container.
30+
31+
```bash
32+
docker run -it --privileged --ipc=host -v /run/udev/control:/run/udev/control -v /dev:/dev registry.openanolis.cn/openanolis/anolisos:8 bash
33+
```
34+
35+
> Note: The additional parameters (`--privileged --ipc=host -v /run/udev/control:/run/udev/control -v /dev:/dev`) are required to make `/dev` works properly in the container.
36+
37+
3. Run cryptpilot in the container shell.
38+
39+
40+
```bash
41+
cryptpilot --help
42+
```
43+
44+
Or
45+
46+
```bash
47+
cryptpilot-convert --help
48+
```
49+
1550

1651
## Example: encrypt a bootable OS
1752

docs/development.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Development
22

3-
## Build and Install
3+
## Build and Install RPM Package
44

55
It is recommended to build a RPM package and install it on your system.
66

@@ -14,8 +14,7 @@ Then install the rpm package on your system:
1414
rpm --install /root/rpmbuild/RPMS/x86_64/cryptpilot-*.rpm
1515
```
1616

17-
18-
## Test
17+
### Test
1918

2019
We have provided some test cases. You can run them with the following command:
2120

0 commit comments

Comments
 (0)