File tree Expand file tree Collapse file tree 2 files changed +57
-2
lines changed Expand file tree Collapse file tree 2 files changed +57
-2
lines changed Original file line number Diff line number Diff line change
1
+ name : Test and build
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - master
7
+
8
+ pull_request :
9
+ branches :
10
+ - master
11
+
12
+
13
+ permissions : write-all
14
+
15
+ jobs :
16
+ test :
17
+ runs-on : ubuntu-latest
18
+ steps :
19
+ - uses : actions/setup-go@v4
20
+ with :
21
+ go-version : ' 1.19'
22
+
23
+
24
+
25
+ - name : Test With Coverage
26
+ run : go test -v -race -coverprofile=coverage.txt -covermode=atomic ./...
27
+ - name : Upload coverage to Codecov
28
+
29
+ with :
30
+ files : coverage.txt
31
+
32
+ - name : golangci-lint
33
+
34
+ with :
35
+ args : --timeout=5m
36
+ # since go test already does it in a previous step
37
+ skip-pkg-cache : true
38
+
39
+ build-image :
40
+ runs-on : ubuntu-latest
41
+ needs : test
42
+ steps :
43
+ -
44
+ name : Set up QEMU
45
+ uses : docker/setup-qemu-action@v3
46
+ -
47
+ name : Set up Docker Buildx
48
+ uses : docker/setup-buildx-action@v3
49
+ -
50
+ name : Build and push
51
+ uses : docker/build-push-action@v5
52
+ with :
53
+ # Only for CI testing purposes
54
+ push : false
55
+ tags : wfs/k8s-image-availability-exporter:latest
Original file line number Diff line number Diff line change 1
- name : build- and- push-base-image (release)
1
+ name : Build and push image
2
2
3
3
on :
4
4
25
25
context : " ."
26
26
dockerfile : ./Dockerfile
27
27
image_name : ${{ github.repository }}
28
- github_token : ${{ secrets.GITHUB_TOKEN }}
28
+ github_token : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments