-
Notifications
You must be signed in to change notification settings - Fork 0
83 lines (77 loc) · 2.22 KB
/
integration.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
80
81
82
83
# Code generated by craft; DO NOT EDIT.
name: Integration
run-name: Integration
on:
pull_request:
push:
branches:
- main
- staging
- develop
- v[0-9]+
- v[0-9]+.[0-9]+
workflow_dispatch:
jobs:
go-lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
cache: false
go-version-file: go.mod
token: ${{ secrets.GITHUB_TOKEN }}
- uses: golangci/golangci-lint-action@v4
with:
args: --config .golangci.yml --timeout 240s --fast --sort-results --out-format colored-line-number
go-test:
strategy:
fail-fast: false
matrix:
os:
- on: macos-latest
args: CGO_ENABLED="0"
- on: ubuntu-latest
args: CGO_ENABLED="0"
- on: windows-latest
args: env CGO_ENABLED="0"
runs-on: ${{ matrix.os.on }}
env:
OS: ${{ matrix.os.on }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version-file: go.mod
token: ${{ secrets.GITHUB_TOKEN }}
- run: ${{ matrix.os.args }} go test ./... -coverpkg="./..." -covermode="count" -coverprofile="coverage.out"
- uses: codecov/codecov-action@v4
if: ${{ ! startsWith(github.ref_name, 'dependabot') }} # ignore codecov on dependabot branches
with:
codecov_yml_path: codecov.yml
disable_search: true
env_vars: OS
fail_ci_if_error: true
file: coverage.out
slug: ${{ github.repository }}
token: ${{ secrets.CODECOV_TOKEN }}
docker-hadolint:
runs-on: ubuntu-latest
permissions:
pull-requests: write
security-events: write
steps:
- uses: actions/checkout@v3
- uses: hadolint/[email protected]
continue-on-error: true # enforce scan upload to codeql
with:
format: sarif
output-file: hadolint-results.sarif
- uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: hadolint-results.sarif
category: docker-hadolint
- id: hadolint
uses: hadolint/[email protected]
with:
format: tty