Skip to content

Commit

Permalink
chg: move to kvrocks 2.10, support docker
Browse files Browse the repository at this point in the history
  • Loading branch information
Rafiot committed Oct 17, 2024
1 parent 362b262 commit 21b6052
Show file tree
Hide file tree
Showing 4 changed files with 194 additions and 73 deletions.
40 changes: 7 additions & 33 deletions .github/workflows/test_api.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,44 +25,18 @@ jobs:
with:
python-version: ${{matrix.python-version}}

- name: Cache kvrocks
id: kvrocks
uses: actions/cache@v4
with:
path: ../kvrocks
key: ${{ runner.os }}-kvrocks

- name: Clone Kvrocks
uses: actions/checkout@v4
with:
repository: apache/kvrocks
path: kvrocks-tmp
ref: 2.6
submodules: true

- name: Install kvrocks
run: |
sudo apt-get update
sudo apt-get install gcc g++ make libsnappy-dev autoconf automake libtool libgtest-dev
mv kvrocks-tmp ../kvrocks
pushd ..
pushd kvrocks
./x.py build
popd
popd
- name: Clone Redis
- name: Clone Valkey
uses: actions/checkout@v4
with:
repository: redis/redis
path: redis-tmp
ref: 7.2
repository: valkey/valkey
path: valkey-tmp
ref: 8.0

- name: Install redis
- name: Install valkey
run: |
mv redis-tmp ../redis
mv valkey-tmp ../valkey
pushd ..
pushd redis
pushd valkey
make
popd
popd
Expand Down
14 changes: 13 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,14 @@ cd ..
[Kvrocks](https://github.com/apache/kvrocks) is a distributed key value NoSQL database that uses RocksDB as storage engine and is compatible with Valkey protocol.
Kvrocks intends to decrease the cost of memory and increase the capability while compared to valkey.


#### Installing from source

NOTE: Kvrocks should be installed from the source, and the repository must be in the same directory as the one you will be cloning Pandora into.

NOTE: Compiling Kvrocks takes well over 1 hour, you may want to use docker instead (see below).


In order to compile kvrocks, you will need a few packages:

```bash
Expand All @@ -72,11 +78,17 @@ sudo apt install git gcc g++ make cmake autoconf automake libtool python3 libssl
```bash
git clone --recursive https://github.com/apache/kvrocks.git kvrocks
cd kvrocks
git checkout 2.8
git checkout 2.10
./x.py build
cd ..
```

#### Using docker

If you have docker installed you don't have anything to do. It expects docker instlaled in [rootless mode](https://docs.docker.com/engine/security/rootless/) (no sudo required).

Check failure on line 88 in README.md

View workflow job for this annotation

GitHub Actions / build (3.10)

instlaled ==> installed

Check failure on line 88 in README.md

View workflow job for this annotation

GitHub Actions / build (3.11)

instlaled ==> installed

Check failure on line 88 in README.md

View workflow job for this annotation

GitHub Actions / build (3.12)

instlaled ==> installed
In case you have docker installed in normal mode, you will need to edit `storage/run_kvrocks.sh` and prepend `sudo` to the docker call.


### Clone pandora

Do the usual:
Expand Down
Loading

0 comments on commit 21b6052

Please sign in to comment.