-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathdocker-bake.hcl
190 lines (157 loc) · 3.43 KB
/
docker-bake.hcl
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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
variable DEBUG {
default = false
}
variable DEFCONFIG {
default = null
}
variable CHIP {
default = null
}
variable BOARD {
default = null
}
group default {
targets = ["kernel", "u-boot"]
}
group u-boot {
targets = ["u-boot-radxa", "u-boot-collabora"]
}
# virtual target for CI
# https://github.com/docker/metadata-action#bake-definition
target "docker-metadata-action" {}
target sdk {
target = "sdk"
inherits = ["docker-metadata-action"]
tags = ["docker.io/milas/rock5-sdk"]
}
target rkdeveloptool {
target = "rkdeveloptool"
inherits = ["docker-metadata-action"]
tags = ["docker.io/milas/rkdeveloptool"]
}
variable KERNEL_REPO {
default = null
}
variable KERNEL_REF {
default = null
}
target kernel {
target = "kernel"
output = ["type=local,dest=./out/kernel"]
inherits = ["kernel-config"]
}
target kernel-config {
target = "kernel-build-config"
inherits = ["docker-metadata-action"]
tags = ["milas/rock5-toolchain:kernel-config"]
contexts = notequal(null, DEFCONFIG) ? { defconfig = DEFCONFIG } : {}
args = {
KERNEL_REPO = KERNEL_REPO
KERNEL_REF = KERNEL_REF
}
}
target radxa-kernel-patches {
target = "kernel-radxa-patches"
output = ["type=local,dest=./out/kernel/patches"]
}
target spl {
target = "rkbin-spl"
output = ["type=local,dest=./out"]
}
target u-boot-radxa {
target = "u-boot-radxa"
output = ["type=local,dest=./out/u-boot/radxa"]
args = {
CHIP = CHIP
BOARD = BOARD
}
}
target u-boot-collabora {
target = "u-boot-collabora"
output = ["type=local,dest=./out/u-boot/collabora"]
args = {
CHIP = CHIP
BOARD = BOARD
}
}
target edk2 {
target = "edk2"
output = ["type=local,dest=./out/edk2"]
args = {
CHIP = CHIP
BOARD = BOARD
}
}
group yolov8 {
targets = ["yolov8-model-onnx", "yolov8-model-rknn"]
}
target _yolov8-model {
context = "./rknn"
output = ["type=local,dest=./out/rknn"]
args = {
YOLO_MODEL = "yolov8s"
}
}
target yolov8-model-onnx {
inherits = ["_yolov8-model"]
target = "yolo-model-onnx"
}
target yolov8-model-rknn {
inherits = ["_yolov8-model"]
target = "yolo-model-rknn"
}
variable YOLO_MODEL {
default = null
}
target rknn-benchmark {
context = "./rknn"
target = "rknn-benchmark"
platforms = ["linux/arm64"]
tags = ["docker.io/milas/rknn-benchmark:yolov8s"]
contexts = notequal(null, YOLO_MODEL) ? { yolo-model-rknn = YOLO_MODEL } : {}
}
target rknn-toolkit2 {
context = "./rknn"
target = "rknn-toolkit2"
platforms = ["linux/amd64"]
tags = ["docker.io/milas/rknn-toolkit2"]
}
group rkmpp {
targets = ["rkmpp-libs", "rkmpp-debian"]
}
target _rkmpp {
context = "./rkmpp"
platforms = ["linux/arm64"]
}
group rkmpp-libs {
targets = ["rkmpp-rga", "rkmpp-mpp", "rkmpp-gstreamer-plugin"]
}
target rkmpp-rga {
inherits = ["_rkmpp"]
target = "rockchip-rga"
output = ["type=local,dest=./out/rkmpp/rga"]
}
target rkmpp-mpp {
inherits = ["_rkmpp"]
target = "rockchip-mpp"
output = ["type=local,dest=./out/rkmpp/mpp"]
}
target rkmpp-gstreamer-plugin {
inherits = ["_rkmpp"]
target = "rockchip-gstreamer-plugin"
output = ["type=local,dest=./out/rkmpp/gstreamer"]
}
target rkmpp-debian {
inherits = ["_rkmpp"]
target = "os"
args = {
OS_BASE = "docker.io/debian:bullseye"
}
tags = ["docker.io/milas/rkmpp-debian:bullseye"]
}
target rpm {
target = "kernel-rpm"
output = ["type=local,dest=./out/kernel"]
inherits = ["kernel-config"]
tags = []
}