Compare commits

...

9 Commits

Author SHA1 Message Date
Jesse
959b1cbd4d
Merge 5b73b09c92 into 8b84eaec3a 2024-10-23 19:17:29 +00:00
Jesse
5b73b09c92
Merge branch 'appleboy:master' into master 2024-10-23 19:17:26 +00:00
appleboy
8b84eaec3a
ci(script): improve CI robustness and coverage across environments
- Change single-line script to multi-line bash script with error handling in GitHub Actions workflow

Signed-off-by: appleboy <appleboy.tw@gmail.com>
2024-10-24 01:27:03 +08:00
appleboy
2763143a97
ci(script): enhance CI workflows and API integration
- Change script execution to a multi-line bash script with error handling in GitHub workflow

Signed-off-by: appleboy <appleboy.tw@gmail.com>
2024-10-24 01:25:46 +08:00
Jesse
aed736182d
Merge pull request #2 from GammaGames/appleboy-master
Appleboy master
2024-07-19 13:54:57 -06:00
GammaGames
332ff99a47 Merge branch 'master' of github.com:appleboy/ssh-action into appleboy-master 2024-07-19 13:52:02 -06:00
Jesse
ec7832be1a
Merge branch 'appleboy:master' into master 2024-07-08 08:15:37 -06:00
GammaGames
396c696e03 syntax fix 2024-04-03 10:12:39 -06:00
GammaGames
27b687e565 rebase with upstream 2024-04-03 10:02:10 -06:00
4 changed files with 23 additions and 3 deletions

View File

@ -37,7 +37,10 @@ jobs:
username: linuxserver.io username: linuxserver.io
password: password password: password
port: 2222 port: 2222
script: whoami script: |
#!/usr/bin/env bash
set -e
whoami
check-ssh-key: check-ssh-key:
runs-on: ubuntu-latest runs-on: ubuntu-latest

View File

@ -37,7 +37,10 @@ jobs:
username: linuxserver.io username: linuxserver.io
password: password password: password
port: 2222 port: 2222
script: whoami script: |
#!/usr/bin/env bash
set -e
whoami
check-ssh-key: check-ssh-key:
runs-on: ubuntu-latest runs-on: ubuntu-latest

View File

@ -73,6 +73,12 @@ inputs:
request_pty: request_pty:
description: "Request a pseudo-terminal from the server." description: "Request a pseudo-terminal from the server."
outputs:
stdout:
description: 'Standard output of the executed commands.'
stderr:
description: 'Standard error of the executed commands.'
runs: runs:
using: "composite" using: "composite"
steps: steps:

View File

@ -63,7 +63,15 @@ TARGET="${GITHUB_ACTION_PATH}/${CLIENT_BINARY}"
echo "Will download ${CLIENT_BINARY} from ${DOWNLOAD_URL_PREFIX}" echo "Will download ${CLIENT_BINARY} from ${DOWNLOAD_URL_PREFIX}"
curl -fsSL --retry 5 --keepalive-time 2 "${DOWNLOAD_URL_PREFIX}/${CLIENT_BINARY}" -o ${TARGET} curl -fsSL --retry 5 --keepalive-time 2 "${DOWNLOAD_URL_PREFIX}/${CLIENT_BINARY}" -o ${TARGET}
chmod +x ${TARGET} chmod +x ${TARGET}
echo "======= CLI Version =======" echo "======= CLI Version ======="
sh -c "${TARGET} --version" # print version sh -c "${TARGET} --version" # print version
echo "===========================" echo "==========================="
sh -c "${TARGET} $*" # run the command {
sh -c "${TARGET} $*" # run the command
} 2> /tmp/errFile | tee /tmp/outFile
stdout=$(cat /tmp/outFile)
stderr=$(cat /tmp/errFile)
echo "stdout=${stdout//$'\n'/\\n}" >> $GITHUB_OUTPUT
echo "stderr=${stderr//$'\n'/\\n}" >> $GITHUB_OUTPUT