Skip to content

Commit 4ff9f7b

Browse files
fix workflow
Signed-off-by: Takeshi Yoshimura <[email protected]>
1 parent 2201fa7 commit 4ff9f7b

File tree

4 files changed

+137
-3
lines changed

4 files changed

+137
-3
lines changed
Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
name: Build and push test images
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
paths:
8+
- test/Dockerfile.*
9+
workflow_dispatch:
10+
11+
env:
12+
VERSION: '0.0.1'
13+
IMAGE_REGISTRY: ghcr.io/${{ github.repository_owner }}
14+
15+
jobs:
16+
build-push-gdrcopy:
17+
runs-on: ubuntu-latest
18+
env:
19+
IMAGE_NAME: ghcr.io/foundation-model-stack/gdrcopy-test
20+
steps:
21+
- uses: actions/checkout@v2
22+
- name: Set up Docker
23+
uses: docker/setup-buildx-action@v1
24+
- name: Login to Docker
25+
uses: docker/login-action@v1
26+
with:
27+
registry: ghcr.io
28+
username: ${{ secrets.GH_USERNAME }}
29+
password: ${{ secrets.GH_TOKEN }}
30+
- name: Build and push gdrcopy-test
31+
uses: docker/build-push-action@v2
32+
with:
33+
context: .
34+
push: true
35+
tags: |
36+
${{ env.IMAGE_NAME }}:ocp-efa-v${{ env.VERSION }}
37+
file: ./test/Dockerfile.gdrcopy
38+
39+
build-push-nccl-tests:
40+
runs-on: ubuntu-latest
41+
env:
42+
IMAGE_NAME: ghcr.io/foundation-model-stack/nccl-tests
43+
steps:
44+
- uses: actions/checkout@v2
45+
- name: Set up Docker
46+
uses: docker/setup-buildx-action@v1
47+
- name: Login to Docker
48+
uses: docker/login-action@v1
49+
with:
50+
registry: ghcr.io
51+
username: ${{ secrets.GH_USERNAME }}
52+
password: ${{ secrets.GH_TOKEN }}
53+
- name: Build and push nccl-tests
54+
uses: docker/build-push-action@v2
55+
with:
56+
context: .
57+
push: true
58+
tags: |
59+
${{ env.IMAGE_NAME }}:ocp-efa-v${{ env.VERSION }}
60+
file: ./test/Dockerfile.nccl-tests
61+
62+
build-push-pytorch:
63+
runs-on: ubuntu-latest
64+
env:
65+
IMAGE_NAME: ghcr.io/foundation-model-stack/pytorch
66+
steps:
67+
- uses: actions/checkout@v2
68+
- name: Set up Docker
69+
uses: docker/setup-buildx-action@v1
70+
- name: Login to Docker
71+
uses: docker/login-action@v1
72+
with:
73+
registry: ghcr.io
74+
username: ${{ secrets.GH_USERNAME }}
75+
password: ${{ secrets.GH_TOKEN }}
76+
- name: Build and push pytorch
77+
uses: docker/build-push-action@v2
78+
with:
79+
context: .
80+
push: true
81+
tags: |
82+
${{ env.IMAGE_NAME }}:ocp-efa-v${{ env.VERSION }}
83+
file: ./test/Dockerfile.pytorch

.github/workflows/unittest-dp.yaml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Perform unittest for device plugins
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- api/**
7+
- controllers/**
8+
- ./main.go
9+
- ./go.mod
10+
- ./go.sum
11+
- config/**
12+
push:
13+
paths:
14+
- cmd/**
15+
- ./go.mod
16+
- ./go.sum
17+
18+
jobs:
19+
device-plugin-test:
20+
runs-on: ubuntu-latest
21+
steps:
22+
- uses: actions/checkout@v2
23+
- uses: actions/setup-go@v2
24+
with:
25+
go-version: '1.21'
26+
- name: Tidy
27+
run: |
28+
go mod tidy
29+
- name: Make generate
30+
run: make generate
31+
- name: Test Uploader
32+
run: make dp-test
33+
- name: Archive code coverage results
34+
uses: actions/upload-artifact@v3
35+
with:
36+
name: device-plugin-code-coverage-report
37+
path: dp-cover.html
Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,22 @@
1-
name: Perform unittest
1+
name: Perform unittest for operator
22

33
on:
44
pull_request:
5+
paths:
6+
- api/**
7+
- controllers/**
8+
- ./main.go
9+
- ./go.mod
10+
- ./go.sum
11+
- config/**
512
push:
13+
paths:
14+
- api/**
15+
- controllers/**
16+
- ./main.go
17+
- ./go.mod
18+
- ./go.sum
19+
- config/**
620

721
jobs:
822
operator-test:

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,12 @@ $ oc new-project ocp-efa-operator
3939
$ operator-sdk run bundle ghcr.io/ocp-efa-operator-bundle:v0.0.1 --namespace ocp-efa-operator
4040
```
4141

42-
Deploy a GdrdrvDriver CR
42+
Deploy GdrdrvDriver
4343
```bash
4444
$ oc apply -f config/sample/efa_v1alpha1_gdrdrvdriver.yaml
4545
```
4646

47-
Deploy a EfaDriver CR
47+
Deploy EfaDriver
4848
```bash
4949
$ oc apply -f config/sample/efa_v1alpha1_efadriver.yaml
5050
```

0 commit comments

Comments
 (0)