2019-09-28 02:54:49 +00:00
|
|
|
name: scp files
|
|
|
|
on: [push]
|
|
|
|
jobs:
|
2019-05-11 09:01:31 +00:00
|
|
|
|
2019-09-28 02:54:49 +00:00
|
|
|
build:
|
|
|
|
name: Build
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2020-02-13 16:49:23 +00:00
|
|
|
- name: checkout
|
|
|
|
uses: actions/checkout@v1
|
|
|
|
|
2019-09-28 02:54:49 +00:00
|
|
|
- name: copy file via ssh password
|
2020-02-13 16:49:23 +00:00
|
|
|
uses: ./
|
2019-09-28 02:54:49 +00:00
|
|
|
with:
|
2019-09-28 04:13:03 +00:00
|
|
|
host: ${{ secrets.HOST }}
|
|
|
|
username: ${{ secrets.USERNAME }}
|
|
|
|
password: ${{ secrets.PASSWORD }}
|
|
|
|
port: ${{ secrets.PORT }}
|
2019-09-28 02:54:49 +00:00
|
|
|
source: "tests/a.txt,tests/b.txt"
|
2019-09-28 03:37:34 +00:00
|
|
|
target: "test"
|
2019-09-28 04:01:18 +00:00
|
|
|
|
|
|
|
- name: copy file via ssh key
|
2020-02-13 16:49:23 +00:00
|
|
|
uses: ./
|
2019-09-28 04:01:18 +00:00
|
|
|
with:
|
2019-09-28 04:16:21 +00:00
|
|
|
host: ${{ secrets.HOST }}
|
|
|
|
username: ${{ secrets.USERNAME }}
|
|
|
|
key: ${{ secrets.KEY }}
|
|
|
|
port: ${{ secrets.PORT }}
|
2019-09-28 04:01:18 +00:00
|
|
|
source: "tests/a.txt,tests/b.txt"
|
|
|
|
target: "test"
|
2019-09-28 04:26:40 +00:00
|
|
|
|
|
|
|
- name: remove the specified number of leading path elements
|
2020-02-13 16:49:23 +00:00
|
|
|
uses: ./
|
2019-09-28 04:26:40 +00:00
|
|
|
with:
|
|
|
|
host: ${{ secrets.HOST }}
|
|
|
|
username: ${{ secrets.USERNAME }}
|
|
|
|
key: ${{ secrets.KEY }}
|
|
|
|
port: ${{ secrets.PORT }}
|
|
|
|
source: "tests/a.txt,tests/b.txt"
|
|
|
|
target: "foobar"
|
|
|
|
strip_components: 1
|
2020-01-20 14:51:17 +00:00
|
|
|
|
|
|
|
- name: ssh key with passphrase
|
2020-02-13 16:49:23 +00:00
|
|
|
uses: ./
|
2020-01-20 14:51:17 +00:00
|
|
|
with:
|
|
|
|
host: ${{ secrets.HOST }}
|
|
|
|
username: ${{ secrets.USERNAME }}
|
|
|
|
key: ${{ secrets.SSH2 }}
|
|
|
|
passphrase: ${{ secrets.PASSPHRASE }}
|
|
|
|
port: ${{ secrets.PORT }}
|
|
|
|
source: "tests/a.txt,tests/b.txt"
|
|
|
|
target: "test"
|
2020-05-21 15:24:36 +00:00
|
|
|
|
|
|
|
- name: empty archive
|
|
|
|
uses: ./
|
|
|
|
with:
|
|
|
|
host: ${{ secrets.HOST }}
|
|
|
|
username: ${{ secrets.USERNAME }}
|
|
|
|
key: ${{ secrets.SSH2 }}
|
|
|
|
passphrase: ${{ secrets.PASSPHRASE }}
|
|
|
|
port: ${{ secrets.PORT }}
|
2020-05-21 15:30:27 +00:00
|
|
|
debug: true
|
2020-05-21 15:24:36 +00:00
|
|
|
source: "tests/aaaaa.txt"
|
|
|
|
target: "test"
|