Skip to content

Commit 6752a29

Browse files
committed
refactor(ci): split CI files more granular
1 parent d7ba5e1 commit 6752a29

4 files changed

Lines changed: 77 additions & 60 deletions

File tree

.github/workflows/build.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Build
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
9+
jobs:
10+
11+
nri-plugin:
12+
name: Build NRI Plugin
13+
runs-on: ubuntu-latest
14+
permissions:
15+
id-token: write
16+
pull-requests: write
17+
contents: write
18+
19+
steps:
20+
- name: Checkout code
21+
uses: actions/checkout@v4
22+
23+
- name: Hub login
24+
uses: docker/login-action@v3
25+
with:
26+
username: ${{ vars.DOCKERBUILDBOT_USERNAME }}
27+
password: ${{ secrets.DOCKERBUILDBOT_WRITE_PAT }}
28+
29+
- name: Set up Docker Buildx
30+
id: buildx
31+
uses: docker/setup-buildx-action@v3
32+
with:
33+
driver: cloud
34+
endpoint: "docker/secrets-engine"
35+
install: true
36+
37+
- name: Build NRI Plugin
38+
run: make BUILDER=${{ steps.buildx.outputs.name }} nri-plugin-package

.github/workflows/ci.yml

Lines changed: 1 addition & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: CI
1+
name: Unit Tests
22

33
on:
44
push:
@@ -7,35 +7,6 @@ on:
77
pull_request:
88

99
jobs:
10-
lint:
11-
name: Lint
12-
runs-on: ubuntu-latest
13-
permissions:
14-
id-token: write
15-
pull-requests: write
16-
contents: write
17-
18-
steps:
19-
- name: Checkout code
20-
uses: actions/checkout@v4
21-
22-
- name: Hub login
23-
uses: docker/login-action@v3
24-
with:
25-
username: ${{ vars.DOCKERBUILDBOT_USERNAME }}
26-
password: ${{ secrets.DOCKERBUILDBOT_WRITE_PAT }}
27-
28-
- name: Set up Docker Buildx
29-
id: buildx
30-
uses: docker/setup-buildx-action@v3
31-
with:
32-
driver: cloud
33-
endpoint: "docker/secrets-engine"
34-
install: true
35-
36-
- name: Lint
37-
run: make BUILDER=${{ steps.buildx.outputs.name }} lint
38-
3910
unit-tests:
4011
name: Unit Tests
4112
runs-on: ubuntu-latest
@@ -45,32 +16,3 @@ jobs:
4516

4617
- name: Unit Tests
4718
run: make unit-tests
48-
49-
nri-plugin:
50-
name: Build NRI Plugin
51-
runs-on: ubuntu-latest
52-
permissions:
53-
id-token: write
54-
pull-requests: write
55-
contents: write
56-
57-
steps:
58-
- name: Checkout code
59-
uses: actions/checkout@v4
60-
61-
- name: Hub login
62-
uses: docker/login-action@v3
63-
with:
64-
username: ${{ vars.DOCKERBUILDBOT_USERNAME }}
65-
password: ${{ secrets.DOCKERBUILDBOT_WRITE_PAT }}
66-
67-
- name: Set up Docker Buildx
68-
id: buildx
69-
uses: docker/setup-buildx-action@v3
70-
with:
71-
driver: cloud
72-
endpoint: "docker/secrets-engine"
73-
install: true
74-
75-
- name: Build NRI Plugin
76-
run: make BUILDER=${{ steps.buildx.outputs.name }} nri-plugin-package

.github/workflows/engine.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Engine
1+
name: Engine (cross platform)
22

33
on:
44
push:

.github/workflows/lint.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Lint
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
9+
jobs:
10+
lint:
11+
name: Lint
12+
runs-on: ubuntu-latest
13+
permissions:
14+
id-token: write
15+
pull-requests: write
16+
contents: write
17+
18+
steps:
19+
- name: Checkout code
20+
uses: actions/checkout@v4
21+
22+
- name: Hub login
23+
uses: docker/login-action@v3
24+
with:
25+
username: ${{ vars.DOCKERBUILDBOT_USERNAME }}
26+
password: ${{ secrets.DOCKERBUILDBOT_WRITE_PAT }}
27+
28+
- name: Set up Docker Buildx
29+
id: buildx
30+
uses: docker/setup-buildx-action@v3
31+
with:
32+
driver: cloud
33+
endpoint: "docker/secrets-engine"
34+
install: true
35+
36+
- name: Lint
37+
run: make BUILDER=${{ steps.buildx.outputs.name }} lint

0 commit comments

Comments
 (0)