mirror of
https://github.com/appleboy/ssh-action.git
synced 2025-09-11 20:15:56 +08:00
Compare commits
22 Commits
v1.2.1
...
b8cf92c329
Author | SHA1 | Date | |
---|---|---|---|
|
b8cf92c329 | ||
|
40c4aada89 | ||
|
c1dc5db4d6 | ||
|
e59e1d9285 | ||
|
d855b8ad7c | ||
|
210ea25b05 | ||
|
058ddd1a69 | ||
|
4188bdc3ce | ||
|
c14811a802 | ||
|
5ec72068f5 | ||
|
bd67bfa881 | ||
|
4819506395 | ||
|
1a1adf6ba5 | ||
|
765833ffce | ||
|
4172428f49 | ||
|
fbf2b7866a | ||
|
5b73b09c92 | ||
|
aed736182d | ||
|
332ff99a47 | ||
|
ec7832be1a | ||
|
396c696e03 | ||
|
27b687e565 |
6
.github/ISSUE_TEMPLATE/bug_report.md
vendored
6
.github/ISSUE_TEMPLATE/bug_report.md
vendored
@@ -1,9 +1,10 @@
|
|||||||
---
|
---
|
||||||
name: Bug report
|
name: Bug report
|
||||||
about: Create a report to help us improve
|
about: Create a report to help us improve
|
||||||
title: ""
|
title: ''
|
||||||
labels: bug
|
labels: bug
|
||||||
assignees: appleboy
|
assignees: appleboy
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
## Describe the bug
|
## Describe the bug
|
||||||
@@ -18,12 +19,13 @@ Please post your Yaml configuration file along with the output results.
|
|||||||
name: remote ssh command
|
name: remote ssh command
|
||||||
on: [push]
|
on: [push]
|
||||||
jobs:
|
jobs:
|
||||||
|
|
||||||
build:
|
build:
|
||||||
name: Build
|
name: Build
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: executing remote ssh commands using password
|
- name: executing remote ssh commands using password
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
|
175
.github/workflows/main.yml
vendored
175
.github/workflows/main.yml
vendored
@@ -505,51 +505,6 @@ jobs:
|
|||||||
script: |
|
script: |
|
||||||
whoami
|
whoami
|
||||||
|
|
||||||
testing07:
|
|
||||||
name: some special character
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: checkout
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Set Environment Variables
|
|
||||||
run: |
|
|
||||||
PASS='3HUS$?8kLu)}'
|
|
||||||
printf "PASS=${PASS}" >> $GITHUB_ENV
|
|
||||||
|
|
||||||
- name: create new ssh server
|
|
||||||
run: |
|
|
||||||
docker run -d \
|
|
||||||
--name=openssh-server \
|
|
||||||
--hostname=openssh-server \
|
|
||||||
-p 2222:2222 \
|
|
||||||
-e SUDO_ACCESS=false \
|
|
||||||
-e PASSWORD_ACCESS=true \
|
|
||||||
-e USER_PASSWORD='${{ env.PASS }}' \
|
|
||||||
-e USER_NAME=linuxserver.io \
|
|
||||||
--restart unless-stopped \
|
|
||||||
lscr.io/linuxserver/openssh-server:latest
|
|
||||||
docker exec openssh-server sh -c "hostname -i" > ip.txt
|
|
||||||
echo "REMOTE_HOST<<EOF" >> $GITHUB_ENV
|
|
||||||
cat ip.txt >> $GITHUB_ENV
|
|
||||||
echo "EOF" >> $GITHUB_ENV
|
|
||||||
echo "======= container ip address ========="
|
|
||||||
cat ip.txt
|
|
||||||
echo "======================================"
|
|
||||||
sleep 2
|
|
||||||
|
|
||||||
- name: ssh by username and password
|
|
||||||
uses: ./
|
|
||||||
with:
|
|
||||||
host: ${{ env.REMOTE_HOST }}
|
|
||||||
username: linuxserver.io
|
|
||||||
password: ${{ env.PASS }}
|
|
||||||
port: 2222
|
|
||||||
script: |
|
|
||||||
#!/usr/bin/env bash
|
|
||||||
set -e
|
|
||||||
whoami
|
|
||||||
|
|
||||||
testing-capturing-output:
|
testing-capturing-output:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
@@ -585,7 +540,7 @@ jobs:
|
|||||||
username: linuxserver.io
|
username: linuxserver.io
|
||||||
password: password
|
password: password
|
||||||
port: 2222
|
port: 2222
|
||||||
capture_stdout: true
|
capture_stdout: 'true'
|
||||||
script: |
|
script: |
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
set -e
|
set -e
|
||||||
@@ -594,131 +549,3 @@ jobs:
|
|||||||
- name: check stdout
|
- name: check stdout
|
||||||
run: |
|
run: |
|
||||||
echo "stdout: ${{ steps.stdout.outputs.stdout }}"
|
echo "stdout: ${{ steps.stdout.outputs.stdout }}"
|
||||||
|
|
||||||
testing-script-stop:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout code
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: create new ssh server
|
|
||||||
run: |
|
|
||||||
docker run -d \
|
|
||||||
--name=openssh-server \
|
|
||||||
--hostname=openssh-server \
|
|
||||||
-p 2222:2222 \
|
|
||||||
-e SUDO_ACCESS=false \
|
|
||||||
-e PASSWORD_ACCESS=true \
|
|
||||||
-e USER_PASSWORD=password \
|
|
||||||
-e USER_NAME=linuxserver.io \
|
|
||||||
--restart unless-stopped \
|
|
||||||
lscr.io/linuxserver/openssh-server:latest
|
|
||||||
docker exec openssh-server sh -c "hostname -i" > ip.txt
|
|
||||||
echo "REMOTE_HOST<<EOF" >> $GITHUB_ENV
|
|
||||||
cat ip.txt >> $GITHUB_ENV
|
|
||||||
echo "EOF" >> $GITHUB_ENV
|
|
||||||
echo "======= container ip address ========="
|
|
||||||
cat ip.txt
|
|
||||||
echo "======================================"
|
|
||||||
sleep 2
|
|
||||||
|
|
||||||
- id: stdout01
|
|
||||||
name: ssh command with stdout 01
|
|
||||||
uses: ./
|
|
||||||
with:
|
|
||||||
host: ${{ env.REMOTE_HOST }}
|
|
||||||
username: linuxserver.io
|
|
||||||
password: password
|
|
||||||
port: 2222
|
|
||||||
capture_stdout: true
|
|
||||||
script: |
|
|
||||||
#!/usr/bin/env bash
|
|
||||||
set -e
|
|
||||||
echo "TMP TESTING IF"
|
|
||||||
if [[ "2" == "1" ]]; then
|
|
||||||
echo "True"
|
|
||||||
else
|
|
||||||
echo "False"
|
|
||||||
fi
|
|
||||||
|
|
||||||
- name: check stdout 01
|
|
||||||
run: |
|
|
||||||
echo "stdout: ${{ steps.stdout01.outputs.stdout }}"
|
|
||||||
if echo "${{ steps.stdout01.outputs.stdout }}" | grep -q "True"; then
|
|
||||||
echo "Output contains 'True'"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
if echo "${{ steps.stdout01.outputs.stdout }}" | grep -q "False"; then
|
|
||||||
echo "Output contains 'False'"
|
|
||||||
fi
|
|
||||||
|
|
||||||
- id: stdout02
|
|
||||||
name: ssh command with stdout 01
|
|
||||||
uses: ./
|
|
||||||
with:
|
|
||||||
host: ${{ env.REMOTE_HOST }}
|
|
||||||
username: linuxserver.io
|
|
||||||
password: password
|
|
||||||
port: 2222
|
|
||||||
capture_stdout: true
|
|
||||||
script: |
|
|
||||||
#!/usr/bin/env bash
|
|
||||||
set -e
|
|
||||||
echo "TMP TESTING IF"
|
|
||||||
if [[ "1" == "1" ]]; then
|
|
||||||
echo "True"
|
|
||||||
else
|
|
||||||
echo "False"
|
|
||||||
fi
|
|
||||||
|
|
||||||
- name: check stdout 02
|
|
||||||
run: |
|
|
||||||
echo "stdout: ${{ steps.stdout02.outputs.stdout }}"
|
|
||||||
if echo "${{ steps.stdout02.outputs.stdout }}" | grep -q "False"; then
|
|
||||||
echo "Output contains 'False'"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
if echo "${{ steps.stdout02.outputs.stdout }}" | grep -q "True"; then
|
|
||||||
echo "Output contains 'True'"
|
|
||||||
fi
|
|
||||||
|
|
||||||
testing-script-error:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout code
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: create new ssh server
|
|
||||||
run: |
|
|
||||||
docker run -d \
|
|
||||||
--name=openssh-server \
|
|
||||||
--hostname=openssh-server \
|
|
||||||
-p 2222:2222 \
|
|
||||||
-e SUDO_ACCESS=false \
|
|
||||||
-e PASSWORD_ACCESS=true \
|
|
||||||
-e USER_PASSWORD=password \
|
|
||||||
-e USER_NAME=linuxserver.io \
|
|
||||||
--restart unless-stopped \
|
|
||||||
lscr.io/linuxserver/openssh-server:latest
|
|
||||||
docker exec openssh-server sh -c "hostname -i" > ip.txt
|
|
||||||
echo "REMOTE_HOST<<EOF" >> $GITHUB_ENV
|
|
||||||
cat ip.txt >> $GITHUB_ENV
|
|
||||||
echo "EOF" >> $GITHUB_ENV
|
|
||||||
echo "======= container ip address ========="
|
|
||||||
cat ip.txt
|
|
||||||
echo "======================================"
|
|
||||||
sleep 2
|
|
||||||
|
|
||||||
- name: test script error
|
|
||||||
uses: ./
|
|
||||||
continue-on-error: true
|
|
||||||
with:
|
|
||||||
host: ${{ env.REMOTE_HOST }}
|
|
||||||
username: linuxserver.io
|
|
||||||
password: password
|
|
||||||
port: 2222
|
|
||||||
capture_stdout: true
|
|
||||||
script: |
|
|
||||||
#!/usr/bin/env bash
|
|
||||||
set -e
|
|
||||||
ls /nonexistent
|
|
||||||
|
32
.github/workflows/stable.yml
vendored
32
.github/workflows/stable.yml
vendored
@@ -31,7 +31,7 @@ jobs:
|
|||||||
sleep 2
|
sleep 2
|
||||||
|
|
||||||
- name: ssh by username and password
|
- name: ssh by username and password
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ env.REMOTE_HOST }}
|
host: ${{ env.REMOTE_HOST }}
|
||||||
username: linuxserver.io
|
username: linuxserver.io
|
||||||
@@ -43,7 +43,7 @@ jobs:
|
|||||||
whoami
|
whoami
|
||||||
|
|
||||||
- name: ssh commands from a file
|
- name: ssh commands from a file
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ env.REMOTE_HOST }}
|
host: ${{ env.REMOTE_HOST }}
|
||||||
username: linuxserver.io
|
username: linuxserver.io
|
||||||
@@ -95,7 +95,7 @@ jobs:
|
|||||||
sleep 2
|
sleep 2
|
||||||
|
|
||||||
- name: ssh by private key
|
- name: ssh by private key
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ env.REMOTE_HOST }}
|
host: ${{ env.REMOTE_HOST }}
|
||||||
username: linuxserver.io
|
username: linuxserver.io
|
||||||
@@ -104,7 +104,7 @@ jobs:
|
|||||||
script: whoami
|
script: whoami
|
||||||
|
|
||||||
- name: wrong password but correct key
|
- name: wrong password but correct key
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ env.REMOTE_HOST }}
|
host: ${{ env.REMOTE_HOST }}
|
||||||
username: linuxserver.io
|
username: linuxserver.io
|
||||||
@@ -114,7 +114,7 @@ jobs:
|
|||||||
script: whoami
|
script: whoami
|
||||||
|
|
||||||
- name: correct password but wrong key
|
- name: correct password but wrong key
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ env.REMOTE_HOST }}
|
host: ${{ env.REMOTE_HOST }}
|
||||||
username: linuxserver.io
|
username: linuxserver.io
|
||||||
@@ -167,7 +167,7 @@ jobs:
|
|||||||
sleep 2
|
sleep 2
|
||||||
|
|
||||||
- name: ssh key passphrase
|
- name: ssh key passphrase
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ env.REMOTE_HOST }}
|
host: ${{ env.REMOTE_HOST }}
|
||||||
username: linuxserver.io
|
username: linuxserver.io
|
||||||
@@ -179,7 +179,7 @@ jobs:
|
|||||||
ls -al
|
ls -al
|
||||||
|
|
||||||
- name: missing ssh key passphrase
|
- name: missing ssh key passphrase
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
with:
|
with:
|
||||||
host: ${{ env.REMOTE_HOST }}
|
host: ${{ env.REMOTE_HOST }}
|
||||||
@@ -192,7 +192,7 @@ jobs:
|
|||||||
|
|
||||||
# https://github.com/appleboy/ssh-action/issues/75#issuecomment-668314271
|
# https://github.com/appleboy/ssh-action/issues/75#issuecomment-668314271
|
||||||
- name: Multiline SSH commands interpreted as single lines
|
- name: Multiline SSH commands interpreted as single lines
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ env.REMOTE_HOST }}
|
host: ${{ env.REMOTE_HOST }}
|
||||||
username: linuxserver.io
|
username: linuxserver.io
|
||||||
@@ -269,7 +269,7 @@ jobs:
|
|||||||
|
|
||||||
# https://github.com/appleboy/ssh-action/issues/85
|
# https://github.com/appleboy/ssh-action/issues/85
|
||||||
- name: Deployment to multiple hosts with different ports
|
- name: Deployment to multiple hosts with different ports
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: "${{ env.REMOTE_HOST_01 }}:2222,${{ env.REMOTE_HOST_02 }}:2222"
|
host: "${{ env.REMOTE_HOST_01 }}:2222,${{ env.REMOTE_HOST_02 }}:2222"
|
||||||
username: linuxserver.io
|
username: linuxserver.io
|
||||||
@@ -322,7 +322,7 @@ jobs:
|
|||||||
sleep 2
|
sleep 2
|
||||||
|
|
||||||
- name: testing id_ed25519 key
|
- name: testing id_ed25519 key
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ env.REMOTE_HOST }}
|
host: ${{ env.REMOTE_HOST }}
|
||||||
username: linuxserver.io
|
username: linuxserver.io
|
||||||
@@ -375,7 +375,7 @@ jobs:
|
|||||||
sleep 2
|
sleep 2
|
||||||
|
|
||||||
- name: testing id_ed25519 key
|
- name: testing id_ed25519 key
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ env.REMOTE_HOST }}
|
host: ${{ env.REMOTE_HOST }}
|
||||||
username: linuxserver.io
|
username: linuxserver.io
|
||||||
@@ -386,7 +386,7 @@ jobs:
|
|||||||
ls -al
|
ls -al
|
||||||
|
|
||||||
- name: pass environment
|
- name: pass environment
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
env:
|
env:
|
||||||
FOO: "BAR"
|
FOO: "BAR"
|
||||||
with:
|
with:
|
||||||
@@ -400,7 +400,7 @@ jobs:
|
|||||||
echo "I am $BAR, thanks"
|
echo "I am $BAR, thanks"
|
||||||
|
|
||||||
- name: pass multiple environment
|
- name: pass multiple environment
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
env:
|
env:
|
||||||
FOO: "BAR"
|
FOO: "BAR"
|
||||||
BAR: "FOO"
|
BAR: "FOO"
|
||||||
@@ -419,7 +419,7 @@ jobs:
|
|||||||
echo "port: $PORT"
|
echo "port: $PORT"
|
||||||
|
|
||||||
- name: custom envs format
|
- name: custom envs format
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
env:
|
env:
|
||||||
FOO: "BAR"
|
FOO: "BAR"
|
||||||
AAA: "BBB"
|
AAA: "BBB"
|
||||||
@@ -437,7 +437,7 @@ jobs:
|
|||||||
echo "I am $TEST_AAA, thanks"
|
echo "I am $TEST_AAA, thanks"
|
||||||
|
|
||||||
- name: pass all ENV variables to script
|
- name: pass all ENV variables to script
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
env:
|
env:
|
||||||
INPUT_FOO: "BAR"
|
INPUT_FOO: "BAR"
|
||||||
INPUT_AAA: "BBB"
|
INPUT_AAA: "BBB"
|
||||||
@@ -454,7 +454,7 @@ jobs:
|
|||||||
echo "$GITHUB_REF"
|
echo "$GITHUB_REF"
|
||||||
|
|
||||||
- name: switch to root user
|
- name: switch to root user
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ env.REMOTE_HOST }}
|
host: ${{ env.REMOTE_HOST }}
|
||||||
username: linuxserver.io
|
username: linuxserver.io
|
||||||
|
26
README.md
26
README.md
@@ -43,7 +43,7 @@ See [action.yml](./action.yml) for more detailed information.
|
|||||||
| proxy_cipher | Allowed cipher algorithms for the proxy | |
|
| proxy_cipher | Allowed cipher algorithms for the proxy | |
|
||||||
| proxy_use_insecure_cipher | Include more ciphers with use_insecure_cipher for the proxy | false |
|
| proxy_use_insecure_cipher | Include more ciphers with use_insecure_cipher for the proxy | false |
|
||||||
| script | Execute commands | |
|
| script | Execute commands | |
|
||||||
| script_path | Execute commands from a file | |
|
| script_file | Execute commands from a file | |
|
||||||
| envs | Pass environment variables to shell script | |
|
| envs | Pass environment variables to shell script | |
|
||||||
| envs_format | Flexible configuration of environment value transfer | |
|
| envs_format | Flexible configuration of environment value transfer | |
|
||||||
| debug | Enable debug mode | false |
|
| debug | Enable debug mode | false |
|
||||||
@@ -63,7 +63,7 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: executing remote ssh commands using password
|
- name: executing remote ssh commands using password
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: linuxserver.io
|
username: linuxserver.io
|
||||||
@@ -179,7 +179,7 @@ ssh-keygen -t ed25519 -a 200 -C "your_email@example.com"
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- name: executing remote ssh commands using password
|
- name: executing remote ssh commands using password
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -192,7 +192,7 @@ ssh-keygen -t ed25519 -a 200 -C "your_email@example.com"
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- name: executing remote ssh commands using ssh key
|
- name: executing remote ssh commands using ssh key
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -205,7 +205,7 @@ ssh-keygen -t ed25519 -a 200 -C "your_email@example.com"
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- name: multiple command
|
- name: multiple command
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -222,7 +222,7 @@ ssh-keygen -t ed25519 -a 200 -C "your_email@example.com"
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- name: file commands
|
- name: file commands
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -235,7 +235,7 @@ ssh-keygen -t ed25519 -a 200 -C "your_email@example.com"
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: multiple host
|
- name: multiple host
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
- host: "foo.com"
|
- host: "foo.com"
|
||||||
+ host: "foo.com,bar.com"
|
+ host: "foo.com,bar.com"
|
||||||
@@ -253,7 +253,7 @@ The default value of `port` is `22`.
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: multiple host
|
- name: multiple host
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
- host: "foo.com"
|
- host: "foo.com"
|
||||||
+ host: "foo.com:1234,bar.com:5678"
|
+ host: "foo.com:1234,bar.com:5678"
|
||||||
@@ -268,7 +268,7 @@ The default value of `port` is `22`.
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: multiple host
|
- name: multiple host
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: "foo.com,bar.com"
|
host: "foo.com,bar.com"
|
||||||
+ sync: true
|
+ sync: true
|
||||||
@@ -284,7 +284,7 @@ The default value of `port` is `22`.
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: pass environment
|
- name: pass environment
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
+ env:
|
+ env:
|
||||||
+ FOO: "BAR"
|
+ FOO: "BAR"
|
||||||
+ BAR: "FOO"
|
+ BAR: "FOO"
|
||||||
@@ -331,7 +331,7 @@ Host FooServer
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: ssh proxy command
|
- name: ssh proxy command
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -354,7 +354,7 @@ It is not uncommon for files to leak from backups or decommissioned hardware, an
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: ssh key passphrase
|
- name: ssh key passphrase
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -380,7 +380,7 @@ Now you can adjust you config:
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: ssh key passphrase
|
- name: ssh key passphrase
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
|
@@ -43,7 +43,7 @@
|
|||||||
| proxy_cipher | 代理允许的密码算法 | |
|
| proxy_cipher | 代理允许的密码算法 | |
|
||||||
| proxy_use_insecure_cipher | 使用不安全的密码算法 | false |
|
| proxy_use_insecure_cipher | 使用不安全的密码算法 | false |
|
||||||
| script | 执行命令 | |
|
| script | 执行命令 | |
|
||||||
| script_path | 从文件执行命令 | |
|
| script_file | 从文件执行命令 | |
|
||||||
| envs | 传递环境变量到 shell 脚本 | |
|
| envs | 传递环境变量到 shell 脚本 | |
|
||||||
| envs_format | 环境变量传递的灵活配置 | |
|
| envs_format | 环境变量传递的灵活配置 | |
|
||||||
| debug | 启用调试模式 | false |
|
| debug | 启用调试模式 | false |
|
||||||
@@ -63,7 +63,7 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: executing remote ssh commands using password
|
- name: executing remote ssh commands using password
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -162,7 +162,7 @@ ssh-keygen -t ed25519 -a 200 -C ”your_email@example.com“
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- name: executing remote ssh commands using password
|
- name: executing remote ssh commands using password
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -175,7 +175,7 @@ ssh-keygen -t ed25519 -a 200 -C ”your_email@example.com“
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- name: executing remote ssh commands using ssh key
|
- name: executing remote ssh commands using ssh key
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -188,7 +188,7 @@ ssh-keygen -t ed25519 -a 200 -C ”your_email@example.com“
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- name: multiple command
|
- name: multiple command
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -205,7 +205,7 @@ ssh-keygen -t ed25519 -a 200 -C ”your_email@example.com“
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: multiple host
|
- name: multiple host
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
- host: ”foo.com“
|
- host: ”foo.com“
|
||||||
+ host: ”foo.com,bar.com“
|
+ host: ”foo.com,bar.com“
|
||||||
@@ -221,7 +221,7 @@ ssh-keygen -t ed25519 -a 200 -C ”your_email@example.com“
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- name: file commands
|
- name: file commands
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -234,7 +234,7 @@ ssh-keygen -t ed25519 -a 200 -C ”your_email@example.com“
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: multiple host
|
- name: multiple host
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
- host: ”foo.com“
|
- host: ”foo.com“
|
||||||
+ host: ”foo.com:1234,bar.com:5678“
|
+ host: ”foo.com:1234,bar.com:5678“
|
||||||
@@ -249,7 +249,7 @@ ssh-keygen -t ed25519 -a 200 -C ”your_email@example.com“
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: multiple host
|
- name: multiple host
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ”foo.com,bar.com“
|
host: ”foo.com,bar.com“
|
||||||
+ sync: true
|
+ sync: true
|
||||||
@@ -265,7 +265,7 @@ ssh-keygen -t ed25519 -a 200 -C ”your_email@example.com“
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: pass environment
|
- name: pass environment
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
+ env:
|
+ env:
|
||||||
+ FOO: ”BAR“
|
+ FOO: ”BAR“
|
||||||
+ BAR: ”FOO“
|
+ BAR: ”FOO“
|
||||||
@@ -312,7 +312,7 @@ Host FooServer
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: ssh proxy command
|
- name: ssh proxy command
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -333,7 +333,7 @@ Host FooServer
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: ssh key passphrase
|
- name: ssh key passphrase
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -359,7 +359,7 @@ ssh example.com ssh-keygen -l -f /etc/ssh/ssh_host_ed25519_key.pub | cut -d ’
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: ssh key passphrase
|
- name: ssh key passphrase
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
|
@@ -43,7 +43,7 @@
|
|||||||
| proxy_cipher | 代理允許的加密算法 | |
|
| proxy_cipher | 代理允許的加密算法 | |
|
||||||
| proxy_use_insecure_cipher | 包含更多不安全的加密算法 | false |
|
| proxy_use_insecure_cipher | 包含更多不安全的加密算法 | false |
|
||||||
| script | 執行命令 | |
|
| script | 執行命令 | |
|
||||||
| script_path | 從文件中執行命令 | |
|
| script_file | 從文件中執行命令 | |
|
||||||
| envs | 將環境變數傳遞給 shell 腳本 | |
|
| envs | 將環境變數傳遞給 shell 腳本 | |
|
||||||
| envs_format | 環境值傳遞的靈活配置 | |
|
| envs_format | 環境值傳遞的靈活配置 | |
|
||||||
| debug | 啟用調試模式 | false |
|
| debug | 啟用調試模式 | false |
|
||||||
@@ -63,7 +63,7 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: executing remote ssh commands using password
|
- name: executing remote ssh commands using password
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -162,7 +162,7 @@ ssh-keygen -t ed25519 -a 200 -C "your_email@example.com"
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- name: executing remote ssh commands using password
|
- name: executing remote ssh commands using password
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -175,7 +175,7 @@ ssh-keygen -t ed25519 -a 200 -C "your_email@example.com"
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- name: executing remote ssh commands using ssh key
|
- name: executing remote ssh commands using ssh key
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -188,7 +188,7 @@ ssh-keygen -t ed25519 -a 200 -C "your_email@example.com"
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- name: multiple command
|
- name: multiple command
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -205,7 +205,7 @@ ssh-keygen -t ed25519 -a 200 -C "your_email@example.com"
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- name: file commands
|
- name: file commands
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -218,7 +218,7 @@ ssh-keygen -t ed25519 -a 200 -C "your_email@example.com"
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: multiple host
|
- name: multiple host
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
- host: "foo.com"
|
- host: "foo.com"
|
||||||
+ host: "foo.com,bar.com"
|
+ host: "foo.com,bar.com"
|
||||||
@@ -234,7 +234,7 @@ ssh-keygen -t ed25519 -a 200 -C "your_email@example.com"
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: multiple host
|
- name: multiple host
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
- host: "foo.com"
|
- host: "foo.com"
|
||||||
+ host: "foo.com:1234,bar.com:5678"
|
+ host: "foo.com:1234,bar.com:5678"
|
||||||
@@ -249,7 +249,7 @@ ssh-keygen -t ed25519 -a 200 -C "your_email@example.com"
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: multiple host
|
- name: multiple host
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: "foo.com,bar.com"
|
host: "foo.com,bar.com"
|
||||||
+ sync: true
|
+ sync: true
|
||||||
@@ -265,7 +265,7 @@ ssh-keygen -t ed25519 -a 200 -C "your_email@example.com"
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: pass environment
|
- name: pass environment
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
+ env:
|
+ env:
|
||||||
+ FOO: "BAR"
|
+ FOO: "BAR"
|
||||||
+ BAR: "FOO"
|
+ BAR: "FOO"
|
||||||
@@ -312,7 +312,7 @@ Host FooServer
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: ssh proxy command
|
- name: ssh proxy command
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -333,7 +333,7 @@ Host FooServer
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: ssh key passphrase
|
- name: ssh key passphrase
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
@@ -359,7 +359,7 @@ ssh example.com ssh-keygen -l -f /etc/ssh/ssh_host_ed25519_key.pub | cut -d ' '
|
|||||||
|
|
||||||
```diff
|
```diff
|
||||||
- name: ssh key passphrase
|
- name: ssh key passphrase
|
||||||
uses: appleboy/ssh-action@v1.2.1
|
uses: appleboy/ssh-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
host: ${{ secrets.HOST }}
|
host: ${{ secrets.HOST }}
|
||||||
username: ${{ secrets.USERNAME }}
|
username: ${{ secrets.USERNAME }}
|
||||||
|
Reference in New Issue
Block a user