Skip to content

Commit 94c69ef

Browse files
committed
[ci] test scp artifacts to zodiac
1 parent 479f0c7 commit 94c69ef

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

.github/workflows/build-deploy-zodiac.yml

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,15 @@ jobs:
2626
id: get_branch
2727
run: echo "BRANCH_NAME=${GITHUB_REF#refs/heads/}" >> $GITHUB_ENV
2828

29-
- name: Copy files to the server via SCP
30-
run: |
31-
echo "Deploying to /var/www/html/dev/${{ env.BRANCH_NAME }}/"
32-
scp -r -o StrictHostKeyChecking=no ./build/* ${{ secrets.NEUROJ_SERVER_USER }}@${{ secrets.NEUROJ_SERVER }}:/var/www/html/dev/${{ env.BRANCH_NAME }}/
29+
- name: Copy package to server
30+
if: ${{ github.repository_owner == 'fangq' && github.event_name != 'pull_request'}}
31+
uses: wlixcc/[email protected]
32+
with:
33+
server: ${{ secrets.NEUROJ_SERVER }}
34+
username: ${{ secrets.NEUROJ_SERVER_USER }}
35+
ssh_private_key: ${{ secrets.NEUROJ_SERVER_SSH_KEY }}
36+
local_path: "./build/*"
37+
remote_path: "${{ secrets.NEUROJ_CI_PATH }}/${{ env.BRANCH_NAME }}"
3338

3439
- name: Restart Server (Only in the deployed folder)
3540
run: |

0 commit comments

Comments
 (0)