diff --git a/.gitea/workflows/deploy.yaml b/.gitea/workflows/deploy.yaml index 7619234..72ddc18 100644 --- a/.gitea/workflows/deploy.yaml +++ b/.gitea/workflows/deploy.yaml @@ -8,16 +8,17 @@ jobs: - name: Checkout code uses: https://gitea.com/actions/checkout@v4 - - name: Copy code to server via SCP - uses: https://gitea.com/actions/appleboy-scp-action@v0.1.7 - with: - host: 6.6.6.66 - username: quant - password: 123quant-speed - source: "." - target: /home/quant/data/dev/deploy - rm: false - overwrite: true + - name: Install sshpass + run: apt-get install -y sshpass rsync + + - name: Copy code to server + run: | + sshpass -p "123quant-speed" rsync -avz --delete \ + --exclude='.git' \ + --exclude='backend/.env' \ + --exclude='backend/media/' \ + -e "ssh -o StrictHostKeyChecking=no" \ + ./ quant@6.6.6.66:/home/quant/data/dev/deploy/ - name: Deploy on server via SSH uses: https://gitea.com/actions/appleboy-ssh-action@v1.0.3