Skip to content

Commit

Permalink
ci: run tmate session only on PR
Browse files Browse the repository at this point in the history
run tmate only for `pull_request` event and
remove for other events. As during release
when tests fail it takes extra 30 min to fail the
test or someone manually has to end the test
which is painfully especially during release time.

Signed-off-by: subhamkrai <srai@redhat.com>
  • Loading branch information
subhamkrai committed Sep 27, 2021
1 parent ccdc5e9 commit fb13b5c
Show file tree
Hide file tree
Showing 8 changed files with 34 additions and 59 deletions.
44 changes: 22 additions & 22 deletions .github/workflows/canary-integration-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,8 @@ jobs:
name: canary
path: test

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60

Expand Down Expand Up @@ -171,8 +171,8 @@ jobs:
name: pvc
path: test

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60

Expand Down Expand Up @@ -238,8 +238,8 @@ jobs:
name: pvc-db
path: test

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60

Expand Down Expand Up @@ -309,8 +309,8 @@ jobs:
name: pvc-db-wal
path: test

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60

Expand Down Expand Up @@ -379,8 +379,8 @@ jobs:
name: encryption-pvc
path: test

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60

Expand Down Expand Up @@ -449,8 +449,8 @@ jobs:
name: encryption-pvc-db-wal
path: test

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60

Expand Down Expand Up @@ -520,8 +520,8 @@ jobs:
name: encryption-pvc-db
path: test

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60

Expand Down Expand Up @@ -608,8 +608,8 @@ jobs:
name: encryption-pvc-kms-vault-token-auth
path: test

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60

Expand Down Expand Up @@ -673,8 +673,8 @@ jobs:
name: lvm-pvc
path: test

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60

Expand Down Expand Up @@ -878,8 +878,8 @@ jobs:
name: multi-cluster-mirroring
path: test

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60

Expand Down Expand Up @@ -960,7 +960,7 @@ jobs:
name: rgw-multisite-testing
path: test

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60
4 changes: 2 additions & 2 deletions .github/workflows/integration-test-helm-suite.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ jobs:
name: ceph-helm-suite-artifact
path: /home/runner/work/rook/rook/tests/integration/_output/tests/

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60
4 changes: 2 additions & 2 deletions .github/workflows/integration-test-mgr-suite.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
name: ceph-mgr-suite-artifact
path: /home/runner/work/rook/rook/tests/integration/_output/tests/

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60
4 changes: 2 additions & 2 deletions .github/workflows/integration-test-multi-cluster-suite.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ jobs:
name: ceph-multi-cluster-deploy-suite-artifact
path: /home/runner/work/rook/rook/tests/integration/_output/tests/

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60
4 changes: 2 additions & 2 deletions .github/workflows/integration-test-object-suite.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ jobs:
name: ceph-smoke-suite-artifact
path: /home/runner/work/rook/rook/tests/integration/_output/tests/

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60
4 changes: 2 additions & 2 deletions .github/workflows/integration-test-smoke-suite.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ jobs:
name: ceph-smoke-suite-artifact
path: /home/runner/work/rook/rook/tests/integration/_output/tests/

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60
4 changes: 2 additions & 2 deletions .github/workflows/integration-test-upgrade-suite.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ jobs:
name: ceph-upgrade-suite-artifact
path: /home/runner/work/rook/rook/tests/integration/_output/tests/

- name: setup tmate session for debugging
if: failure()
- name: setup tmate session for debugging when event is PR
if: failure() && github.event_name == 'pull_request'
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60
25 changes: 0 additions & 25 deletions .github/workflows/integration-tests-on-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -64,11 +64,6 @@ jobs:
name: ceph-helm-suite-artifact
path: /home/runner/work/rook/rook/tests/integration/_output/tests/

- name: setup tmate session for debugging
if: failure()
uses: mxschmitt/action-tmate@v3
timeout-minutes: 30

TestCephMultiClusterDeploySuite:
runs-on: ubuntu-18.04
strategy:
Expand Down Expand Up @@ -116,11 +111,6 @@ jobs:
name: ceph-multi-cluster-deploy-suite-artifact
path: /home/runner/work/rook/rook/tests/integration/_output/tests/

- name: setup tmate session for debugging
if: failure()
uses: mxschmitt/action-tmate@v3
timeout-minutes: 30

TestCephSmokeSuite:
runs-on: ubuntu-18.04
strategy:
Expand Down Expand Up @@ -167,11 +157,6 @@ jobs:
name: ceph-smoke-suite-artifact
path: /home/runner/work/rook/rook/tests/integration/_output/tests/

- name: setup tmate session for debugging
if: failure()
uses: mxschmitt/action-tmate@v3
timeout-minutes: 30

TestCephUpgradeSuite:
runs-on: ubuntu-18.04
strategy:
Expand Down Expand Up @@ -218,11 +203,6 @@ jobs:
name: ceph-upgrade-suite-artifact
path: /home/runner/work/rook/rook/tests/integration/_output/tests/

- name: setup tmate session for debugging
if: failure()
uses: mxschmitt/action-tmate@v3
timeout-minutes: 30

TestCephObjectSuite:
if: ${{ github.event_name == 'pull_request' && github.ref != 'refs/heads/master' && !contains(github.event.pull_request.labels.*.name, 'skip-ci') }}
runs-on: ubuntu-18.04
Expand Down Expand Up @@ -269,8 +249,3 @@ jobs:
with:
name: ceph-smoke-suite-artifact
path: /home/runner/work/rook/rook/tests/integration/_output/tests/

- name: setup tmate session for debugging
if: failure()
uses: mxschmitt/action-tmate@v3
timeout-minutes: 60

0 comments on commit fb13b5c

Please sign in to comment.