From 3cd1bcf7713f758a2c03f1fa7b0401826d0b1dcf Mon Sep 17 00:00:00 2001 From: Bo-Yi Wu Date: Tue, 4 Apr 2023 17:25:53 +0800 Subject: [PATCH] feat: refactor code for parallel execution on multiple hosts (#237) - Update Dockerfile to use a newer version of `drone-ssh` - Modify `ci.yml` to use `continue-on-error` instead of commenting out code fix https://github.com/appleboy/ssh-action/issues/233 --- .github/workflows/ci.yml | 26 ++++++++++++++------------ Dockerfile | 2 +- 2 files changed, 15 insertions(+), 13 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2c44c53..8494f9c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -63,18 +63,20 @@ jobs: whoami ls -al - # - name: stop script if command error - # if: always() - # uses: ./ - # with: - # host: ${{ secrets.HOST }} - # username: ${{ secrets.USERNAME }} - # key: ${{ secrets.KEY }} - # port: ${{ secrets.PORT }} - # script_stop: true - # script: | - # mkdir abc/def - # ls -al + - name: stop script if command error + uses: ./ + continue-on-error: true + with: + host: ${{ secrets.HOST }} + username: ${{ secrets.USERNAME }} + key: ${{ secrets.KEY }} + port: ${{ secrets.PORT }} + script_stop: true + sync: true + debug: true + script: | + mkdir abc/def + ls -al - name: pass environment uses: ./ diff --git a/Dockerfile b/Dockerfile index 0f1e3c8..6cd936d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM appleboy/drone-ssh:1.6.10 +FROM ghcr.io/appleboy/drone-ssh:1.6.12 COPY entrypoint.sh /entrypoint.sh RUN chmod +x /entrypoint.sh