Skip to content

Commit 46ae3ac

Browse files
committed
add readme
1 parent b46d41e commit 46ae3ac

File tree

1 file changed

+21
-1
lines changed

1 file changed

+21
-1
lines changed

README.md

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,13 @@
33
TiKV client for C++. So far, it only supports synchronous API.
44

55
It's built on top of
6-
[TiKV Client in Rust](https://github.com/tikv/client-rust) via [cxx](https://github.com/dtolnay/cxx).
6+
[TiKV Client in Rust](https://github.com/tikv/client-cpp) via [cxx](https://github.com/dtolnay/cxx).
77

88
This client is still in the stage of prove-of-concept and under heavy development.
99

1010
## Build
1111

12+
### Local Build
1213
```bash
1314
# cxxbridge-cmd 1.0.18 requires rustc 1.48+ and c++17 or newer
1415
cargo install cxxbridge-cmd --force --version 1.0.18
@@ -23,6 +24,25 @@ Otherwise, you can build release version by the following. The library will be i
2324
```bash
2425
make release
2526
```
27+
### Docker build
28+
**Way 1: Use Visual Studio Code Dev Container**
29+
you can use the dev container to build the project, just open the project in VSCode and press `F1` and select `Dev Containers: Reopen in Container` to open the project in dev container.
30+
31+
**Way 2: Build Docker Locally Then Compile**
32+
```bash
33+
docker build -t tikv/client-cpp:latest \ -f .devcontainer/Dockerfile .
34+
docker run -v $(pwd):/client-cpp \
35+
tikv/client-cpp:latest \
36+
/bin/bash -c "make release"
37+
```
38+
39+
**Way3: Use Image to Compile(Image is NOT Official)**
40+
```bash
41+
docker run -v $(pwd):/client-cpp \
42+
registry.cn-hangzhou.aliyuncs.com/smityz/client-cpp:latest \
43+
/bin/bash -c "make release"
44+
```
45+
2646

2747
## Run example
2848

0 commit comments

Comments
 (0)