-
Notifications
You must be signed in to change notification settings - Fork 0
79 lines (63 loc) · 2.01 KB
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
name: Release
on:
release:
types: [published]
workflow_dispatch:
jobs:
run-tests:
uses: ./.github/workflows/tests.yml
secrets: inherit
check-version:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Get sbx version
shell: bash
run: |
SBX_VER=$(cat VERSION)
echo "SBX_VER=$SBX_VER" >> $GITHUB_ENV
- id: get_version
uses: battila7/get-version-action@v2
- name: Check version
shell: bash
run: |
RELEASE_VERSION=${{ steps.get_version.outputs.version-without-v }}
echo "Release version: ${RELEASE_VERSION}"
echo "Sbx version: ${{ env.SBX_VER }}"
if [[ $RELEASE_VERSION == ${{ env.SBX_VER }} ]]; then
echo "Versions match, continuing..."
else
echo "Versions don't match, exiting..."
exit 1
fi
push-to-dockerhub:
uses: ./.github/workflows/docker.yml
secrets: inherit
needs:
- run-tests
- check-version
test-apptainer:
name: Apptainer Test
runs-on: ubuntu-latest
needs: push-to-dockerhub
steps:
- name: Checkout Code
uses: actions/checkout@v4
- name: Set test env
run: echo "SUNBEAM_TEST_PROFILE=apptainer" >> $GITHUB_ENV
- uses: eWaterCycle/setup-apptainer@v2
with:
apptainer-version: 1.1.2
- name: Test with Sunbeam
uses: sunbeam-labs/sbx_test_action@v1
with:
test-directory: ".tests/e2e/"
- name: Dump Logs
shell: bash
if: always()
run: tail -n +1 logs/*
- name: Dump Stats
shell: bash
if: always()
run: cat stats/*