File tree Expand file tree Collapse file tree 1 file changed +49
-0
lines changed Expand file tree Collapse file tree 1 file changed +49
-0
lines changed Original file line number Diff line number Diff line change
1
+ # This workflow will compile e2e tests and release them
2
+
3
+ name : ODH Release
4
+ on :
5
+ workflow_dispatch :
6
+ inputs :
7
+ version :
8
+ description : ' Tag to be used for release, i.e.: v0.0.1'
9
+ required : true
10
+
11
+ jobs :
12
+ release-odh :
13
+ runs-on : ubuntu-latest
14
+
15
+ # Permission required to create a release
16
+ permissions :
17
+ contents : write
18
+
19
+ steps :
20
+ - uses : actions/checkout@v4
21
+
22
+ - name : Set Go
23
+ uses : actions/setup-go@v5
24
+ with :
25
+ go-version : v1.20
26
+
27
+ - name : Verify that release doesn't exist yet
28
+ shell : bash {0}
29
+ run : |
30
+ gh release view ${{ github.event.inputs.version }}
31
+ status=$?
32
+ if [[ $status -eq 0 ]]; then
33
+ echo "Release ${{ github.event.inputs.version }} already exists."
34
+ exit 1
35
+ fi
36
+ env :
37
+ GITHUB_TOKEN : ${{ github.TOKEN }}
38
+
39
+ - name : Compile tests
40
+ run : |
41
+ go test -c -o compiled-tests/e2e ./test/e2e/
42
+ go test -c -o compiled-tests/odh ./test/odh/
43
+
44
+ - name : Creates a release in GitHub
45
+ run : |
46
+ gh release create ${{ github.event.inputs.version }} --target ${{ github.ref }} compiled-tests/*
47
+ env :
48
+ GITHUB_TOKEN : ${{ secrets.CODEFLARE_MACHINE_ACCOUNT_TOKEN }}
49
+ shell : bash
You can’t perform that action at this time.
0 commit comments