Skip to content

Commit

Permalink
ci: added ASAN image
Browse files Browse the repository at this point in the history
Signed-off-by: Iaroslav Sydoruk <[email protected]>
  • Loading branch information
isdrk committed Mar 3, 2025
1 parent e93010e commit cd99a00
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 1 deletion.
22 changes: 22 additions & 0 deletions .ci/job_matrix_doca_nvmf_target_offload_nightly.yaml.in
Original file line number Diff line number Diff line change
Expand Up @@ -91,3 +91,25 @@ steps:
else
echo "Skip generic container build"
fi

- name: Build ASAN docker image
containerSelector: "{name: 'doca_ci'}"
credentialsId: '3s-bf3-dpa-prod-role'
archiveArtifacts: 'artifact.properties'
run: |
if [[ "$do_container" == "true" ]]; then
./container/build_image.sh \
--build-type=debug \
--doca-image=$DOCA_IMAGE \
--doca-builder-tag=$DOCA_BUILDER_TAG \
--doca-runtime-tag=$DOCA_RUNTIME_TAG \
--docker-registry-host=$DOCKER_REGISTRY_HOST \
--docker-registry-path=$DOCKER_REGISTRY_PATH \
--docker-image-name=doca_nvmf_target_offload_nightly_asan \
--doca-sta-url=$doca_sta_url \
--configure-args='--enable-asan --enable-ubsan' \
--artifact-prop-name=DOCKER_IMAGE_ASAN \
--sign --push
else
echo "Skip generic container build"
fi
2 changes: 1 addition & 1 deletion container/Dockerfile.nvmf_target_offload
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ ENV PYTHONPATH="${NVMF_TARGET_OFFLOAD_PATH}/local/lib/python3.10/dist-packages:$
ENV PKG_CONFIG_PATH="${NVMF_TARGET_OFFLOAD_PATH}/lib/pkgconfig:$PKG_CONFIG_PATH"
ENV PATH="${NVMF_TARGET_OFFLOAD_PATH}/bin:$PATH"

RUN apt update && apt install -y supervisor libjson-c5 fuse3
RUN apt update && apt install -y supervisor libjson-c5 fuse3 libasan6 libubsan1
RUN apt clean && rm -rf /var/lib/apt/lists/*
RUN dpkg --force-all -r spdk spdk-rpc mlnx-dpdk

Expand Down
5 changes: 5 additions & 0 deletions container/build_image.sh
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ Arguments:
--sign Sign DPA binary (default: ${SIGN}). Requires DPA_SIGN_USER and DPA_SIGN_PASS env variables to be set
--artifact-prop-name Key name in artifact.properties (default: ${ARTIFACT_PROP_NAME})
--doca-sta-url URL for DOCA-STA file: https://urm.nvidia.com/artifactory/sw-nbu-doca-local/doca-sdk/2.10.0/DOCA_2-10-0065-1/doca-sdk-sta-2.10.0065.tar.gz (default: empty)
--configure-args Configure arguments for DOCA NVMf target offload (default: empty)
EOF
}

Expand Down Expand Up @@ -106,6 +108,9 @@ while getopts ":h-:" optchar; do
doca-sta-url=*)
DOCA_STA_URL=${OPTARG#*=}
;;
configure-args=*)
NVMF_TARGET_OFFLOAD_BUILD_ARGS=${OPTARG#*=}
;;
*)
if [ "$OPTERR" = 1 ] && [ "${optspec:0:1}" != ":" ]; then
echo "Unknown option --${OPTARG}" >&2
Expand Down

0 comments on commit cd99a00

Please sign in to comment.