Skip to content

Commit 255189f

Browse files
authored
build(images): build third-party images for ASan tests (#2347)
#2344. As is described in #2341, this PR is to build third-party images with ASan enabled, which are dedicated to ASan tests.
1 parent b507fd3 commit 255189f

2 files changed

Lines changed: 32 additions & 1 deletion

File tree

.github/workflows/build-push-thirdparty.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,36 @@ jobs:
154154
HADOOP_BIN_PATH=hadoop-bin
155155
ZOOKEEPER_BIN_PATH=zookeeper-bin
156156
157+
build_push_bin_test_asan_docker_images:
158+
runs-on: ubuntu-latest
159+
needs: build_push_src_docker_images
160+
steps:
161+
- uses: actions/checkout@v4
162+
- name: Set up QEMU
163+
uses: docker/setup-qemu-action@v1
164+
- name: Set up Docker Buildx
165+
uses: docker/setup-buildx-action@v1
166+
- name: Login to DockerHub
167+
uses: docker/login-action@v1
168+
with:
169+
username: ${{ secrets.DOCKERHUB_USER }}
170+
password: ${{ secrets.DOCKERHUB_TOKEN }}
171+
- name: Build and push for test asan
172+
uses: docker/build-push-action@v2.10.0
173+
with:
174+
context: .
175+
file: ./docker/thirdparties-bin/Dockerfile
176+
push: true
177+
tags: |
178+
apache/pegasus:thirdparties-bin-test-asan-${{ inputs.osversion }}-${{ github.ref_name }}
179+
build-args: |
180+
GITHUB_BRANCH=${{ github.ref_name }}
181+
OS_VERSION=${{ inputs.osversion }}
182+
ROCKSDB_PORTABLE=1
183+
ENABLE_ASAN=ON
184+
HADOOP_BIN_PATH=hadoop-bin
185+
ZOOKEEPER_BIN_PATH=zookeeper-bin
186+
157187
build_push_bin_test_jemalloc_docker_images:
158188
runs-on: ubuntu-latest
159189
needs: build_push_src_docker_images

docker/thirdparties-bin/Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,12 +28,13 @@ ARG GITHUB_BRANCH
2828
ARG GITHUB_REPOSITORY_URL=https://github.com/apache/incubator-pegasus.git
2929
ARG ROCKSDB_PORTABLE=native
3030
ARG USE_JEMALLOC=OFF
31+
ARG ENABLE_ASAN=OFF
3132
ARG HADOOP_BIN_PATH=hadoop-bin
3233
ARG ZOOKEEPER_BIN_PATH=zookeeper-bin
3334
RUN git clone --depth=1 --branch=${GITHUB_BRANCH} ${GITHUB_REPOSITORY_URL} \
3435
&& cd incubator-pegasus/thirdparty \
3536
&& unzip /root/thirdparties-src.zip -d . \
36-
&& cmake -DCMAKE_BUILD_TYPE=Release -DROCKSDB_PORTABLE=${ROCKSDB_PORTABLE} -DUSE_JEMALLOC=${USE_JEMALLOC} -B build/ . \
37+
&& cmake -DCMAKE_BUILD_TYPE=Release -DROCKSDB_PORTABLE=${ROCKSDB_PORTABLE} -DUSE_JEMALLOC=${USE_JEMALLOC} -DENABLE_ASAN=${ENABLE_ASAN} -B build/ . \
3738
&& cmake --build build/ -j $(($(nproc)/2+1)) \
3839
&& ../admin_tools/download_hadoop.sh ${HADOOP_BIN_PATH} \
3940
&& ../admin_tools/download_zk.sh ${ZOOKEEPER_BIN_PATH} \

0 commit comments

Comments
 (0)