File tree Expand file tree Collapse file tree 2 files changed +19
-14
lines changed Expand file tree Collapse file tree 2 files changed +19
-14
lines changed Original file line number Diff line number Diff line change 88 - uses : actions/checkout@v2
99 - name : golangci-lint
1010 uses : golangci/golangci-lint-action@v2
11- check_commit :
12- if : ${{ github.event_name == 'pull_request' }}
13- name : HAProxy check commit message
14- runs-on : ubuntu-latest
15- steps :
16- - uses : actions/checkout@v2
17- with :
18- fetch-depth : 0
19- - name : check-commit
20- uses : docker://haproxytech/check-commit:latest
21- env :
22- API_TOKEN : ${{ secrets.GITHUB_TOKEN }}
2311 go_build :
2412 name : Go build
2513 runs-on : ubuntu-latest
4129 go_test :
4230 name : Go test
4331 runs-on : ubuntu-latest
44- needs : ["go_lint "]
32+ needs : ["go_build "]
4533 steps :
4634 - uses : actions/checkout@v2
4735 - uses : actions/setup-go@v2
5442 - name : Build
5543 run : |
5644 go test ./...
45+ check_commit :
46+ if : ${{ github.event_name == 'pull_request' }}
47+ name : HAProxy check commit message
48+ runs-on : ubuntu-latest
49+ needs : ["go_build"]
50+ steps :
51+ - uses : actions/checkout@v2
52+ with :
53+ fetch-depth : 0
54+ - name : Set up Go 1.17
55+ uses : actions/setup-go@v2
56+ with :
57+ go-version : 1.17
58+ - name : check-commit
59+ run : go build -o check && ./check
60+ env :
61+ API_TOKEN : ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ FROM golang:alpine as builder
22RUN mkdir /build
33ADD . /build/
44WORKDIR /build
5- RUN go build -o check check.go
5+ RUN go build -o check
66
77FROM alpine:latest
88COPY --from=builder /build/check /check
You can’t perform that action at this time.
0 commit comments