forked from raidensakura/modmail
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-bake.hcl
More file actions
28 lines (26 loc) · 959 Bytes
/
Copy pathdocker-bake.hcl
File metadata and controls
28 lines (26 loc) · 959 Bytes
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
target "_common" {
args = {
PYTHON_VERSION = "3.12"
}
platforms = ["linux/amd64", "linux/arm64"]
}
# placeholder for docker-metadata-action target data
target "docker-metadata-action" {
tags = []
}
target "openmodmail" {
name = "openmodmail${notequal("true",include-supportutils) ? "" : "-supportutils"}${notequal("true",include-pip) ? "" : "-pip"}"
inherits = ["_common", "docker-metadata-action"]
context = "."
dockerfile = "Dockerfile"
matrix = {
include-supportutils = ["true", "false"]
include-pip = ["true", "false"]
}
args = {
INCLUDE_SUPPORTUTILS = include-supportutils
INCLUDE_PIP = include-pip
}
# take the tags from the docker-metadata-action target and append the suffixes based on the matrix values
tags = [for tag in target.docker-metadata-action.tags : "${tag}${notequal("true",include-supportutils) ? "" : "-supportutils"}${notequal("true",include-pip) ? "" : "-pip"}"]
}