Skip to content

Commit 9c3448b

Browse files
authored
[gha] fix ide integration tests (#16898)
1 parent 0187678 commit 9c3448b

File tree

1 file changed

+35
-14
lines changed

1 file changed

+35
-14
lines changed

.github/workflows/ide-integration-tests.yml

Lines changed: 35 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -58,29 +58,43 @@ jobs:
5858
SLACK_WEBHOOK: ${{ secrets.IDE_SLACK_WEBHOOK }}
5959
SLACK_COLOR: ${{ job.status }}
6060
SLACK_MESSAGE: main branch build failed
61-
check:
62-
name: Check for regressions
63-
needs: [configuration]
64-
runs-on: [self-hosted]
65-
container:
66-
image: eu.gcr.io/gitpod-core-dev/dev/dev-environment:kylos101-kubecdl-home.1
61+
62+
infrastructure:
63+
name: Create preview environment infrastructure
64+
needs: [ configuration ]
65+
runs-on: [ self-hosted ]
66+
concurrency:
67+
group: ${{ github.head_ref || github.ref_name }}-infrastructure
6768
steps:
6869
- uses: actions/checkout@v3
6970
- name: Create preview environment infrastructure
71+
id: create
7072
uses: ./.github/actions/preview-create
7173
with:
7274
name: ${{ needs.configuration.outputs.name }}
75+
sa_key: ${{ secrets.GCP_CREDENTIALS }}
7376
infrastructure_provider: harvester
7477
large_vm: true
75-
sa_key: ${{ secrets.GCP_CREDENTIALS }}
7678
- name: Deploy Gitpod to the preview environment
77-
if: github.event.inputs.skip_deploy != 'true'
7879
id: deploy-gitpod
80+
if: github.event.inputs.skip_deploy != 'true'
7981
uses: ./.github/actions/deploy-gitpod
8082
with:
8183
name: ${{ needs.configuration.outputs.name }}
8284
sa_key: ${{ secrets.GCP_CREDENTIALS }}
8385
version: ${{ needs.configuration.outputs.version}}
86+
87+
check:
88+
name: Check for regressions
89+
needs: [configuration, infrastructure]
90+
runs-on: [self-hosted]
91+
container:
92+
image: eu.gcr.io/gitpod-core-dev/dev/dev-environment:kylos101-kubecdl-home.1
93+
volumes:
94+
- /var/tmp:/var/tmp
95+
- /tmp:/tmp
96+
steps:
97+
- uses: actions/checkout@v3
8498
- name: Integration Test
8599
shell: bash
86100
env:
@@ -153,9 +167,16 @@ jobs:
153167
SLACK_WEBHOOK: ${{ secrets.IDE_SLACK_WEBHOOK }}
154168
SLACK_COLOR: ${{ job.status }}
155169
SLACK_MESSAGE: ${{ steps.test_summary.outputs.passed }}/${{ steps.test_summary.outputs.total }} tests passed
156-
- name: Delete preview environment
157-
if: github.event.inputs.skip_delete != 'true' && (success() || failure())
158-
uses: ./.github/actions/delete-preview
159-
with:
160-
name: ${{ needs.configuration.outputs.name }}
161-
sa_key: ${{ secrets.GCP_CREDENTIALS }}
170+
171+
delete:
172+
name: Delete preview environment
173+
needs: [ configuration, infrastructure, check ]
174+
if: github.event.inputs.skip_delete != 'true' && always()
175+
runs-on: [ self-hosted ]
176+
steps:
177+
- uses: actions/checkout@v3
178+
- name: Delete preview environment
179+
uses: ./.github/actions/delete-preview
180+
with:
181+
name: ${{ needs.configuration.outputs.name }}
182+
sa_key: ${{ secrets.GCP_CREDENTIALS }}

0 commit comments

Comments
 (0)