2021-03-31 12:34:44 -04:00
|
|
|
variable "NODE_VERSION" {
|
2022-02-28 02:28:55 -05:00
|
|
|
default = "16"
|
2021-03-31 12:34:44 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
target "node-version" {
|
|
|
|
args = {
|
|
|
|
NODE_VERSION = NODE_VERSION
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
group "default" {
|
|
|
|
targets = ["build"]
|
|
|
|
}
|
|
|
|
|
|
|
|
group "pre-checkin" {
|
|
|
|
targets = ["vendor-update", "format", "build"]
|
|
|
|
}
|
|
|
|
|
|
|
|
group "validate" {
|
|
|
|
targets = ["format-validate", "build-validate", "vendor-validate"]
|
|
|
|
}
|
|
|
|
|
|
|
|
target "build" {
|
|
|
|
inherits = ["node-version"]
|
|
|
|
dockerfile = "./hack/build.Dockerfile"
|
|
|
|
target = "build-update"
|
|
|
|
output = ["."]
|
|
|
|
}
|
|
|
|
|
|
|
|
target "build-validate" {
|
|
|
|
inherits = ["node-version"]
|
|
|
|
dockerfile = "./hack/build.Dockerfile"
|
|
|
|
target = "build-validate"
|
2021-11-16 15:38:44 -05:00
|
|
|
output = ["type=cacheonly"]
|
2021-03-31 12:34:44 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
target "format" {
|
|
|
|
inherits = ["node-version"]
|
|
|
|
dockerfile = "./hack/build.Dockerfile"
|
|
|
|
target = "format-update"
|
|
|
|
output = ["."]
|
|
|
|
}
|
|
|
|
|
|
|
|
target "format-validate" {
|
|
|
|
inherits = ["node-version"]
|
|
|
|
dockerfile = "./hack/build.Dockerfile"
|
|
|
|
target = "format-validate"
|
2021-11-16 15:38:44 -05:00
|
|
|
output = ["type=cacheonly"]
|
2021-03-31 12:34:44 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
target "vendor-update" {
|
|
|
|
inherits = ["node-version"]
|
2021-11-16 15:38:44 -05:00
|
|
|
dockerfile = "./hack/build.Dockerfile"
|
|
|
|
target = "vendor-update"
|
2021-03-31 12:34:44 -04:00
|
|
|
output = ["."]
|
|
|
|
}
|
|
|
|
|
|
|
|
target "vendor-validate" {
|
|
|
|
inherits = ["node-version"]
|
2021-11-16 15:38:44 -05:00
|
|
|
dockerfile = "./hack/build.Dockerfile"
|
|
|
|
target = "vendor-validate"
|
|
|
|
output = ["type=cacheonly"]
|
2021-03-31 12:34:44 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
target "test" {
|
|
|
|
inherits = ["node-version"]
|
2021-11-16 15:38:44 -05:00
|
|
|
dockerfile = "./hack/build.Dockerfile"
|
2021-03-31 12:34:44 -04:00
|
|
|
target = "test-coverage"
|
|
|
|
output = ["./coverage"]
|
|
|
|
}
|