From ebba0826e49020a2786084501e536e450b948f11 Mon Sep 17 00:00:00 2001 From: risemeup1 <515586620@qq.com> Date: Wed, 25 Dec 2024 04:51:52 +0000 Subject: [PATCH] fix,test=document_fix --- .github/workflows/test.yml | 46 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 .github/workflows/test.yml diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 00000000000000..bd8000398fdf2a --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,46 @@ +name: Clone Paddle2 + +on: + pull_request: + branches: [ "develop" ] + +jobs: + Clone-Paddle2: + name: Clone Paddle2 + runs-on: ubuntu-latest + steps: + - name: Clone paddle2 + uses: actions/checkout@v4 + with: + submodules: 'recursive' + + - name: Cache bos client + id: cache_bos_client + uses: actions/cache@v4 + with: + path: | + /home/runner/work/Paddle/bos_upload.py + ~/.cache/pip + key: bos_client_pip + + - name: Download bos client + env: + WORK: "/home/runner/work/Paddle" + if: steps.cache_bos_client.outputs.cache-hit != 'true' + run: | + cd $WORK + wget -q --no-proxy -O bos_upload.py https://paddle-docker-tar.cdn.bcebos.com/bos_upload.py --no-check-certificate + + - name: Push paddle-action.tar.gz to bos + env: + WORK: "/home/runner/work/Paddle" + AK: ${{ secrets.AK }} + SK: ${{ secrets.SK }} + PR_ID: ${{ github.event.pull_request.number }} + COMMIT_ID: ${{ github.event.pull_request.head.sha }} + run: | + git checkout -b test + cd $WORK + tar -zcf Paddle-action.tar.gz Paddle + python -m pip install bce-python-sdk==0.8.74 + python3 bos_upload.py Paddle-action.tar.gz xly-devops/PR/Paddle/${PR_ID}/${COMMIT_ID}