From da612c801589d64bea89ca943c84fe1aae7a1d06 Mon Sep 17 00:00:00 2001 From: Bo-Yi Wu Date: Wed, 5 Jun 2024 15:54:35 +0800 Subject: [PATCH] refactor: optimize CI pipeline for faster execution - Reduce sleep duration from 3 seconds to 2 seconds - Rename SSH job steps for clarity - Change port mapping from 2223 to 2222 Signed-off-by: Bo-Yi Wu --- .github/workflows/ssh-server.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ssh-server.yml b/.github/workflows/ssh-server.yml index 98bbd69..0a19104 100644 --- a/.github/workflows/ssh-server.yml +++ b/.github/workflows/ssh-server.yml @@ -28,9 +28,9 @@ jobs: echo "======= container ip address =========" cat ip.txt echo "======================================" - sleep 3 + sleep 2 - - name: executing remote ssh commands using password (1.0.3) + - name: ssh by username and password uses: appleboy/ssh-action@v1.0.3 with: host: ${{ env.REMOTE_HOST }} @@ -65,7 +65,7 @@ jobs: docker run -d \ --name=openssh-server \ --hostname=openssh-server \ - -p 2223:2222 \ + -p 2222:2222 \ -e PUBLIC_KEY="${{ env.PUBLIC_KEY }}" \ -e SUDO_ACCESS=false \ -e PASSWORD_ACCESS=true \ @@ -80,13 +80,13 @@ jobs: echo "======= container ip address =========" cat ip.txt echo "======================================" - sleep 3 + sleep 2 - - name: executing remote ssh commands using password (1.0.3) + - name: ssh by private uses: appleboy/ssh-action@v1.0.3 with: host: ${{ env.REMOTE_HOST }} username: linuxserver.io key: ${{ env.PRIVATE_KEY }} - port: 2223 + port: 2222 script: whoami