appleboy / scp-action

GitHub Action that copy files and artifacts via SSH.
https://github.com/marketplace/actions/scp-command-to-transfer-files
MIT License
1.14k stars 134 forks source link

tar: can't open '/home/runner/work/_temp/kCTvmuuHYr.tar.gz': No such file or directory #168

Closed thermoweb closed 3 months ago

thermoweb commented 3 months ago

Hi,

I have the following configuration:

- name: publish site
  uses: appleboy/scp-action@v0.1.7
  with:
    host: ${{ secrets.SSH_HOST }}
    username: ${{ secrets.SSH_USERNAME }}
    key: ${{ secrets.SSH_KEY }}
    passphrase: ${{ secrets.SSH_PASSPHRASE }}
    source: "public/"
    target: "/var/www/mysite"
    overwrite: true

I tried a lot of things to make it works but I'm stuck with this error:

tar: can't open '/home/runner/work/_temp/kCTvmuuHYr.tar.gz': No such file or directory
exit status 1
drone-scp version: v1.6.14
tar all files into /home/runner/work/_temp/kCTvmuuHYr.tar.gz

I checked with ssh-action which works great so it might be an issue with the scp tar stuff.

Thanks in advance for your help.

thermoweb commented 3 months ago

Ok I finally managed to fix it. I had to use actions/upload and download artifact to make it work.

Sorry, I think I did not read with enough attention the readme.