This is an automated email from the ASF dual-hosted git repository.
tison pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pulsar.git
The following commit(s) were added to refs/heads/master by this push:
new 4028ad3d224 [improve][ci] Improve CI ssh access in forks, don't fail
build if setting up ssh access fails (#19127)
4028ad3d224 is described below
commit 4028ad3d2246b4d1a6af870a5a8c4d8dae64ace0
Author: Lari Hotari <[email protected]>
AuthorDate: Fri Jan 6 01:20:34 2023 +0200
[improve][ci] Improve CI ssh access in forks, don't fail build if setting
up ssh access fails (#19127)
---
.github/actions/ssh-access/action.yml | 16 +++++++++++++++-
.github/workflows/pulsar-ci-flaky.yaml | 1 +
.github/workflows/pulsar-ci.yaml | 8 ++++++++
3 files changed, 24 insertions(+), 1 deletion(-)
diff --git a/.github/actions/ssh-access/action.yml
b/.github/actions/ssh-access/action.yml
index 582d5b17440..b4ad4a8555e 100644
--- a/.github/actions/ssh-access/action.yml
+++ b/.github/actions/ssh-access/action.yml
@@ -121,8 +121,22 @@ runs:
tmux set -t upterm window-size largest
echo '::endgroup::'
echo -e "\nSSH connection information"
+ # wait up to 10 seconds for upterm admin socket to appear
+ for i in {1..10}; do
+ ADMIN_SOCKET=$(find $HOME/.upterm -name "*.sock")
+ if [ ! -S "$ADMIN_SOCKET" ]; then
+ echo "Waiting for upterm admin socket to appear in
~/.upterm/*.sock ..."
+ sleep 1
+ else
+ echo "upterm admin socket available in $ADMIN_SOCKET"
+ break
+ fi
+ done
shopt -s nullglob
- upterm session current --admin-socket ~/.upterm/*.sock
+ upterm session current --admin-socket ~/.upterm/*.sock || {
+ echo "Starting upterm failed."
+ exit 0
+ }
elif [[ "${{ inputs.action }}" == "wait" ]]; then
# only wait if upterm was installed
if command -v upterm &>/dev/null; then
diff --git a/.github/workflows/pulsar-ci-flaky.yaml
b/.github/workflows/pulsar-ci-flaky.yaml
index 9c52cfe77d6..35315d07a7b 100644
--- a/.github/workflows/pulsar-ci-flaky.yaml
+++ b/.github/workflows/pulsar-ci-flaky.yaml
@@ -83,6 +83,7 @@ jobs:
# ssh access is enabled for builds in own forks
if: ${{ github.repository != 'apache/pulsar' && github.event_name ==
'pull_request' }}
uses: ./.github/actions/ssh-access
+ continue-on-error: true
with:
limit-access-to-actor: true
diff --git a/.github/workflows/pulsar-ci.yaml b/.github/workflows/pulsar-ci.yaml
index 3741d3c8424..3570bdc8a78 100644
--- a/.github/workflows/pulsar-ci.yaml
+++ b/.github/workflows/pulsar-ci.yaml
@@ -89,6 +89,7 @@ jobs:
# ssh access is enabled for builds in own forks
if: ${{ github.repository != 'apache/pulsar' && github.event_name ==
'pull_request' }}
uses: ./.github/actions/ssh-access
+ continue-on-error: true
with:
limit-access-to-actor: true
@@ -184,6 +185,7 @@ jobs:
# ssh access is enabled for builds in own forks
if: ${{ github.repository != 'apache/pulsar' && github.event_name ==
'pull_request' }}
uses: ./.github/actions/ssh-access
+ continue-on-error: true
with:
limit-access-to-actor: true
@@ -285,6 +287,7 @@ jobs:
# ssh access is enabled for builds in own forks
if: ${{ github.repository != 'apache/pulsar' && github.event_name ==
'pull_request' }}
uses: ./.github/actions/ssh-access
+ continue-on-error: true
with:
limit-access-to-actor: true
@@ -383,6 +386,7 @@ jobs:
# ssh access is enabled for builds in own forks
if: ${{ github.repository != 'apache/pulsar' && github.event_name ==
'pull_request' }}
uses: ./.github/actions/ssh-access
+ continue-on-error: true
with:
limit-access-to-actor: true
@@ -512,6 +516,7 @@ jobs:
# ssh access is enabled for builds in own forks
if: ${{ github.repository != 'apache/pulsar' && github.event_name ==
'pull_request' }}
uses: ./.github/actions/ssh-access
+ continue-on-error: true
with:
limit-access-to-actor: true
@@ -638,6 +643,7 @@ jobs:
# ssh access is enabled for builds in own forks
if: ${{ github.repository != 'apache/pulsar' && github.event_name ==
'pull_request' }}
uses: ./.github/actions/ssh-access
+ continue-on-error: true
with:
limit-access-to-actor: true
@@ -749,6 +755,7 @@ jobs:
# ssh access is enabled for builds in own forks
if: ${{ github.repository != 'apache/pulsar' && github.event_name ==
'pull_request' }}
uses: ./.github/actions/ssh-access
+ continue-on-error: true
with:
limit-access-to-actor: true
@@ -903,6 +910,7 @@ jobs:
# ssh access is enabled for builds in own forks
if: ${{ github.repository != 'apache/pulsar' && github.event_name ==
'pull_request' }}
uses: ./.github/actions/ssh-access
+ continue-on-error: true
with:
limit-access-to-actor: true