drone-scp
drone-scp copied to clipboard
`error: tar: unknown option -- -`
Closing https://github.com/appleboy/scp-action/issues/83 and reopening here, because I believe it's an issue with drone-scp expecting GNU tar on the other end, which isn't always the case (OpenBSD).
untar file xpkHVyWJzG.tar
error: tar: unknown option -- -
usage: tar {crtux}[014578befHhjLmNOoPpqsvwXZz]
[blocking-factor | archive | replstr] [-C directory] [-I file]
[file ...]
tar {-crtux} [-014578eHhjLmNOoPpqvwXZz] [-b blocking-factor]
[-C directory] [-f archive] [-I file] [-s replstr] [file ...]
drone-scp error: Process exited with status 1
drone-scp rollback: remove all target tmp file
remove file xpkHVyWJzG.tar
To whomever comes across this issue: pkg_add gtar && ln -s /usr/local/bin/gtar /usr/bin/tar
will do the trick on OpenBSD, as a workaround.
@mrusme
```yaml
uses: appleboy/scp-action@master
with:
host: example.com
username: foo
password: bar
port: 22
source: "tests/a.txt,tests/b.txt"
target: "test"
+ tar_exec: gtar