This repository was archived by the owner on Jul 18, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 41
64 lines (54 loc) · 1.57 KB
/
build-pr.yml
File metadata and controls
64 lines (54 loc) · 1.57 KB
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
name: Build PR
on: [push]
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
env:
GO111MODULE: "on"
steps:
- name: Checkout code into the Go module directory
uses: actions/checkout@v2
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version-file: go.mod
check-latest: true
cache: true
id: go
- name: Check license headers
run: make validate
- name: Run golangci-lint
run: |
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b . v1.51.1
./golangci-lint run
build-linux:
name: Build Linux
runs-on: ubuntu-latest
env:
GO111MODULE: "on"
E2E_TEST_AUTH_TOKEN: ${{ secrets.E2E_TEST_AUTH_TOKEN }}
E2E_HUB_URL: ${{ secrets.E2E_HUB_URL }}
E2E_HUB_USERNAME: ${{ secrets.E2E_HUB_USERNAME }}
E2E_HUB_TOKEN: ${{ secrets.E2E_HUB_TOKEN }}
steps:
- name: Docker version
run: docker version
- name: Checkout code into the Go module directory
uses: actions/checkout@v2
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version-file: go.mod
check-latest: true
cache: true
id: go
- name: Build binary
run: make TAG_NAME=${{ github.event.inputs.tag }} -f builder.Makefile build
- name: Build Cross
run: make cross
- name: Upload binary artifact
uses: actions/upload-artifact@v2
with:
name: docker-scan
path: ./dist/