-
Notifications
You must be signed in to change notification settings - Fork 78
/
docker-bake.hcl
120 lines (93 loc) · 1.97 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
variable "POSTGRES_REPO" {
default = "ghcr.io/hydradatabase/hydra"
}
variable "SPILO_REPO" {
default = "011789831835.dkr.ecr.us-east-1.amazonaws.com/spilo"
}
variable "SPILO_VERSION" {
default = "hydra-2.1-p9"
}
variable "POSTGRES_BASE_VERSION" {
default = "14"
}
variable "SPILO_POSTGRES_VERSION" {
default = "14"
}
variable "SPILO_POSTGRES_OLD_VERSIONS" {
default = "13"
}
group "default" {
targets = ["postgres", "spilo"]
}
target "shared" {
platforms = [
"linux/amd64",
"linux/arm64"
]
args = {
TIMESTAMP = "${timestamp()}"
}
}
target "postgres" {
inherits = ["shared"]
contexts = {
columnar = "target:columnar_${POSTGRES_BASE_VERSION}"
postgres_base = "docker-image://postgres:${POSTGRES_BASE_VERSION}-bookworm"
}
args = {
POSTGRES_BASE_VERSION = "${POSTGRES_BASE_VERSION}"
}
tags = [
"${POSTGRES_REPO}:latest",
"${POSTGRES_REPO}:${POSTGRES_BASE_VERSION}"
]
}
target "spilo" {
inherits = ["shared"]
dockerfile = "Dockerfile.spilo"
contexts = {
spilo_base = "target:spilo_base"
columnar_13 = "target:columnar_13"
columnar_14 = "target:columnar_14"
columnar_15 = "target:columnar_15"
}
args = {
POSTGRES_BASE_VERSION = "${SPILO_POSTGRES_VERSION}"
}
tags = [
"${SPILO_REPO}:latest",
"${SPILO_REPO}:${SPILO_VERSION}-latest"
]
}
target "spilo_base" {
inherits = ["shared"]
context = "https://github.com/hydradatabase/spilo.git#${SPILO_VERSION}:postgres-appliance"
args = {
TIMESCALEDB = ""
PGVERSION = "${SPILO_POSTGRES_VERSION}"
PGOLDVERSIONS = "${SPILO_POSTGRES_OLD_VERSIONS}"
}
}
target "columnar" {
inherits = ["shared"]
context = "columnar"
target = "output"
}
target "columnar_13" {
inherits = ["columnar"]
args = {
POSTGRES_BASE_VERSION = 13
}
}
target "columnar_14" {
inherits = ["columnar"]
args = {
POSTGRES_BASE_VERSION = 14
}
}
target "columnar_15" {
inherits = ["columnar"]
args = {
POSTGRES_BASE_VERSION = 15
}
}