Skip to content

Commit

Permalink
ci: Trying to fix rocksdb build (#2867)
Browse files Browse the repository at this point in the history
* ci: Trying to fix rocksdb build

Signed-off-by: Xuanwo <[email protected]>

* trigger test

Signed-off-by: Xuanwo <[email protected]>

---------

Signed-off-by: Xuanwo <[email protected]>
  • Loading branch information
Xuanwo authored Aug 15, 2023
1 parent 5384936 commit b89a2e3
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
14 changes: 9 additions & 5 deletions .github/actions/setup/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,12 @@ runs:
# Enable sparse index
echo "CARGO_REGISTRIES_CRATES_IO_PROTOCOL=sparse" >> $GITHUB_ENV
# Make sure all required lib has been installed.
- name: Setup Linux
if: runner.os == 'Linux'
shell: bash
run: sudo apt-get install libgflags-dev libsnappy-dev zlib1g-dev libbz2-dev liblz4-dev libzstd-dev

- name: Setup protoc on linux
if: inputs.need-protoc == 'true' && runner.os == 'Linux'
shell: bash
Expand Down Expand Up @@ -76,16 +82,14 @@ runs:
if: runner.os == 'Linux' && inputs.need-rocksdb == 'true'
with:
path: /tmp/rocksdb
key: r0-rocksdb-8.1.1
key: r1-rocksdb-8.1.1

- name: Build rocksdb if not cached
if: steps.cache-rocksdb.outputs.cache-hit != 'true' && runner.os == 'Linux' && inputs.need-rocksdb == 'true'
shell: bash
run: |
set -e
sudo apt-get install libgflags-dev libsnappy-dev zlib1g-dev libbz2-dev liblz4-dev libzstd-dev
cd /tmp
curl https://github.com/facebook/rocksdb/archive/refs/tags/v8.1.1.tar.gz -L -o rocksdb.tar.gz
tar -xzf rocksdb.tar.gz
Expand All @@ -98,15 +102,15 @@ runs:
cd ..
rm -rf /tmp/rocksdb-8.1.1
- name: Cache foundationdb
id: cache-foundationdb
uses: actions/cache@v3
if: runner.os == 'Linux' && inputs.need-foundationdb == 'true'
with:
path: /etc/foundationdb
key: r0-foundationdb-7.1.17

- name: Build foundationdb if not cached
if: steps.cache-foundationdb.outputs.cache-hit != 'true' && runner.os == 'Linux' && inputs.need-foundationdb == 'true'
shell: bash
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/service_test_rocksdb.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ on:
- "!core/src/docs/**"
- "!core/src/services/**"
- "core/src/services/rocksdb/**"
- ".github/actions/setup/action.yaml"
- ".github/workflows/service_test_rocksdb.yml"

concurrency:
Expand Down

0 comments on commit b89a2e3

Please sign in to comment.