4 Commits

Author SHA1 Message Date
Bo-Yi Wu
196ea3f88f chore(scp): default port is 22
Some checks failed
scp files / Build (push) Failing after 4s
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
2019-09-30 16:58:33 +08:00
Bo-Yi Wu
034b0ad00c Update README.md 2019-09-30 11:38:02 +08:00
Bo-Yi Wu
95e250284b docs: update readme 2019-09-29 14:16:22 +08:00
Bo-Yi Wu
a593d18cb8 docs: add default value of timeout 2019-09-29 01:45:56 +08:00
2 changed files with 22 additions and 12 deletions

View File

@@ -1,6 +1,6 @@
# 🚀 SCP for GitHub Actions
[GitHub Action](https://developer.github.com/actions/) for copying files and artifacts via SSH.
[GitHub Action](https://github.com/features/actions) for copying files and artifacts via SSH.
![ssh key](./images/copy-multiple-file.png)
@@ -11,15 +11,24 @@
copy files and artifacts via SSH as blow.
```yaml
- name: copy file via ssh password
uses: appleboy/scp-action@master
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
port: ${{ secrets.PORT }}
source: "tests/a.txt,tests/b.txt"
target: "test"
name: scp files
on: [push]
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: copy file via ssh password
uses: appleboy/scp-action@master
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
port: ${{ secrets.PORT }}
source: "tests/a.txt,tests/b.txt"
target: "test"
```
## Input variables
@@ -30,8 +39,8 @@ see the [action.yml](./action.yml) file for more detail imformation.
* port - scp remote port
* username - scp username
* password - scp password
* timeout - timeout for ssh to remote host
* command_timeout - timeout for scp command
* timeout - timeout for ssh to remote host, default is `30s`
* command_timeout - timeout for scp command, default is `1m`
* key - content of ssh private key. ex raw content of ~/.ssh/id_rsa
* key_path - path of ssh private key
* target - target path on the server

View File

@@ -6,6 +6,7 @@ inputs:
description: 'scp remote host'
port:
description: 'scp remote port'
default: 22
username:
description: 'scp username'
password: