[CI] Ensure container cleanup after job to avoid resource leakage (#7315)

* [CI] Ensure container cleanup after job to avoid resource leakage

* [CI] Use prebuilt wheels to install xgrammar==0.1.19 and torch==2.6.0
This commit is contained in:
YuBaoku
2026-04-10 22:32:18 +08:00
committed by GitHub
parent 00005c92e0
commit 1269eda2f9
13 changed files with 103 additions and 6 deletions
+10 -1
View File
@@ -107,6 +107,7 @@ jobs:
git config --global user.name "FastDeployCI"
git config --global user.email "fastdeploy_ci@example.com"
git log -n 3 --oneline
- name: FastDeploy FD_ROUTER Build
shell: bash
env:
@@ -137,7 +138,8 @@ jobs:
PARENT_DIR=$(dirname "$WORKSPACE")
echo "PARENT_DIR:$PARENT_DIR"
docker run --rm --net=host \
--cap-add=SYS_PTRACE --privileged --shm-size=64G \
--cap-add=SYS_PTRACE --shm-size=64G \
--name ${runner_name} \
-v $(pwd):/workspace -w /workspace \
-v "${CACHE_DIR}/gitconfig:/etc/gitconfig:ro" \
-v "${CACHE_DIR}/.cache:/root/.cache" \
@@ -212,3 +214,10 @@ jobs:
target_path_stripped="${target_path#paddle-github-action/}"
FD_ROUTER_PATH=https://paddle-github-action.bj.bcebos.com/${target_path_stripped}/fd-router
echo "fd_router_path=${FD_ROUTER_PATH}" >> $GITHUB_OUTPUT
- name: Terminate and delete the container
if: always()
run: |
set +e
docker exec -t ${{ runner.name }} /bin/bash -c 'find /workspace -mindepth 1 -delete'
docker rm -f ${{ runner.name }}