forked from gravitational/teleport
-
Notifications
You must be signed in to change notification settings - Fork 0
46 lines (39 loc) · 958 Bytes
/
build-api.yaml
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
name: Build API Module
run-name: Build API Module
on:
pull_request:
paths:
- .github/workflows/build-api.yaml
- 'api/**/*.go'
- 'api/go.mod'
- 'api/go.sum'
- 'go.mod'
- 'go.sum'
merge_group:
paths:
- .github/workflows/build-api.yaml
- 'api/**/*.go'
- 'api/go.mod'
- 'api/go.sum'
- 'go.mod'
- 'go.sum'
jobs:
build:
name: Build API
if: ${{ !startsWith(github.head_ref, 'dependabot/') }}
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: Checkout Teleport
uses: actions/checkout@v3
- name: Setup Go
uses: actions/setup-go@v4
with:
# use the version declared in API's go.mod
go-version-file: api/go.mod
cache-dependency-path: api/go.sum
- name: Init workspace
run: go work init . ./api/
- name: Build
run: go build ./api/...