-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-bake.hcl
65 lines (56 loc) · 1.59 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
variable "IMAGE_NAME" {
default = "ars-408"
}
variable "CONTAINER_REGISTRY" {
default = "registry.gitlab.com/polymathrobotics/sensors"
}
variable "LOCAL_PLATFORM" {
default = regex_replace("${BAKE_LOCAL_PLATFORM}", "^(darwin)", "linux")
}
variable "SRC_DIR"{
default = "/src"
}
variable "TAG_ADENDUM"{
default=""
}
target "_common" {
dockerfile = "Containerfile"
args = {
BASE_IMAGE = "registry.gitlab.com/polymathrobotics/ros_base:humble"
SRC_DIR="${SRC_DIR}"
}
tags = ["${CONTAINER_REGISTRY}/${IMAGE_NAME}:humble${TAG_ADENDUM}"]
labels = {
"org.opencontainers.image.source" = "https://github.com/polymathrobotics/sensors/ars-408"
"org.opencontainers.image.licenses" = "Apache-2.0"
"org.opencontainers.image.description" = "Driver for Continental ARS-408"
"org.opencontainers.image.title" = "${IMAGE_NAME}"
"dev.polymathrobotics.image.readme-filepath" = "README.md"
}
}
target "local" {
inherits = ["_common"]
platforms = ["${LOCAL_PLATFORM}"]
}
target "amd64" {
inherits = ["_common"]
args = {
BASE_IMAGE = "registry.gitlab.com/polymathrobotics/ros_base:humble"
SRC_DIR="${SRC_DIR}"
}
tags=["${CONTAINER_REGISTRY}/${IMAGE_NAME}/amd64:humble${TAG_ADENDUM}"]
platforms = ["linux/amd64"]
}
target "arm64" {
inherits = ["_common"]
args = {
BASE_IMAGE = "registry.gitlab.com/polymathrobotics/ros_base/arm64:humble"
SRC_DIR="${SRC_DIR}"
}
tags=["${CONTAINER_REGISTRY}/${IMAGE_NAME}/arm64:humble${TAG_ADENDUM}"]
platforms = ["linux/arm64/v8"]
}
target "default" {
inherits = ["_common"]
platforms = ["linux/amd64", "linux/arm64/v8"]
}