24
24
permissions : read-all
25
25
26
26
jobs :
27
- base_image_ubuntu2204 :
27
+ build_and_push_images :
28
28
if : github.repository == 'intel/llvm'
29
- name : Base Ubuntu 22.04 Docker image
29
+ name : Build and Push Docker Images
30
30
runs-on : ubuntu-22.04
31
31
permissions :
32
32
packages : write
33
+ strategy :
34
+ matrix :
35
+ include :
36
+ - name : Base Ubuntu 22.04 Docker image
37
+ file : ubuntu2204_base
38
+ tags : ubuntu2204_base
39
+ build_args : " "
40
+ - name : Build Ubuntu Docker image
41
+ file : ubuntu2204_build
42
+ tags : ubuntu2204_build
43
+ build_args : " "
44
+ - name : Intel Drivers Ubuntu 22.04 Docker image
45
+ file : ubuntu2204_intel_drivers
46
+ tags : ubuntu2204_intel_drivers
47
+ build_args : " use_latest=false"
48
+ - name : Intel Drivers (unstable) Ubuntu 22.04 Docker image
49
+ file : ubuntu2204_intel_drivers
50
+ tags : ubuntu2204_intel_drivers_unstable
51
+ build_args : " use_latest=true"
33
52
steps :
34
53
- name : Checkout
35
54
uses : actions/checkout@v4
@@ -39,83 +58,11 @@ jobs:
39
58
uses : ./devops/actions/build_container
40
59
with :
41
60
push : ${{ github.event_name != 'pull_request' }}
42
- file : ubuntu2204_base
61
+ file : ${{ matrix.file }}
43
62
username : ${{ github.repository_owner }}
44
63
password : ${{ secrets.GITHUB_TOKEN }}
45
64
tags : |
46
- ghcr.io/${{ github.repository }}/ubuntu2204_base:${{ github.sha }}
47
- ghcr.io/${{ github.repository }}/ubuntu2204_base:latest
48
- build_image_ubuntu2204 :
49
- if : github.repository == 'intel/llvm'
50
- name : Build Ubuntu Docker image
51
- runs-on : ubuntu-22.04
52
- permissions :
53
- packages : write
54
- steps :
55
- - name : Checkout
56
- uses : actions/checkout@v4
57
- with :
58
- fetch-depth : 2
59
- - name : Build and Push Container
60
- uses : ./devops/actions/build_container
61
- with :
62
- push : ${{ github.event_name != 'pull_request' }}
63
- file : ubuntu2204_build
64
- username : ${{ github.repository_owner }}
65
- password : ${{ secrets.GITHUB_TOKEN }}
66
- tags : |
67
- ghcr.io/${{ github.repository }}/ubuntu2204_build:${{ github.sha }}
68
- ghcr.io/${{ github.repository }}/ubuntu2204_build:latest
65
+ ghcr.io/${{ github.repository }}/${{ matrix.tags }}-${{ github.sha }}
66
+ ghcr.io/${{ github.repository }}/${{ matrix.tags }}:latest
67
+ build-args : ${{ matrix.build_args }}
69
68
70
- # This job produces a Docker container with the latest versions of Intel
71
- # drivers, that can be found on GitHub.
72
- drivers_image_ubuntu2204 :
73
- if : github.repository == 'intel/llvm'
74
- name : Intel Drivers Ubuntu 22.04 Docker image
75
- runs-on : ubuntu-22.04
76
- permissions :
77
- packages : write
78
- needs : base_image_ubuntu2204
79
- steps :
80
- - name : Checkout
81
- uses : actions/checkout@v4
82
- with :
83
- fetch-depth : 2
84
- - name : Build and Push Container
85
- uses : ./devops/actions/build_container
86
- with :
87
- push : ${{ github.event_name != 'pull_request' }}
88
- file : ubuntu2204_intel_drivers
89
- username : ${{ github.repository_owner }}
90
- password : ${{ secrets.GITHUB_TOKEN }}
91
- tags : |
92
- ghcr.io/${{ github.repository }}/ubuntu2204_intel_drivers:latest-${{ github.sha }}
93
- ghcr.io/${{ github.repository }}/ubuntu2204_intel_drivers:latest
94
- build-args : |
95
- use_latest=false
96
- # This job produces a Docker container with the latest versions of Intel
97
- # drivers, that can be found on GitHub.
98
- drivers_image_ubuntu2204_unstable :
99
- if : github.repository == 'intel/llvm'
100
- name : Intel Drivers (unstable) Ubuntu 22.04 Docker image
101
- runs-on : ubuntu-22.04
102
- permissions :
103
- packages : write
104
- needs : base_image_ubuntu2204
105
- steps :
106
- - name : Checkout
107
- uses : actions/checkout@v4
108
- with :
109
- fetch-depth : 2
110
- - name : Build and Push Container
111
- uses : ./devops/actions/build_container
112
- with :
113
- push : ${{ github.event_name != 'pull_request' }}
114
- file : ubuntu2204_intel_drivers
115
- username : ${{ github.repository_owner }}
116
- password : ${{ secrets.GITHUB_TOKEN }}
117
- tags : |
118
- ghcr.io/${{ github.repository }}/ubuntu2204_intel_drivers:unstable-${{ github.sha }}
119
- ghcr.io/${{ github.repository }}/ubuntu2204_intel_drivers:unstable
120
- build-args : |
121
- use_latest=true
0 commit comments