Improve formatting, order and docs

This commit is contained in:
Aleksandar Puharic 2023-04-09 21:58:01 +02:00
parent ec520c2e42
commit 04f0dc4d93
Signed by: xZero707
GPG Key ID: 3CC53DCAA9C237BB

View File

@ -1,11 +1,39 @@
group "default" { group "default" {
targets = ["5_9_0", "5_9_1", "5_9_2", "5_9_3", "6_0_0", "6_0_1", "6_0_2", "6_0_3", "6_1_0", "6_1_1", "6_2_0"] targets = [
"5_9_0",
"5_9_1",
"5_9_2",
"5_9_3",
"6_0_0",
"6_0_1",
"6_0_2",
"6_0_3",
"6_1_0",
"6_1_1",
"6_2_0"
]
}
target "build-dockerfile" {
dockerfile = "Dockerfile"
}
target "build-platforms" {
platforms = ["linux/amd64", "linux/armhf", "linux/aarch64"]
}
target "build-common" {
pull = true
} }
variable "REGISTRY_CACHE" { variable "REGISTRY_CACHE" {
default = "docker.io/nlss/wordpress-cache" default = "docker.io/nlss/wordpress-cache"
} }
######################
# Define the functions
######################
# Get the arguments for the build # Get the arguments for the build
function "get-args" { function "get-args" {
params = [version] params = [version]
@ -51,17 +79,9 @@ function "get-tags" {
) )
} }
target "build-dockerfile" { ##########################
dockerfile = "Dockerfile" # Define the build targets
} ##########################
target "build-platforms" {
platforms = ["linux/amd64", "linux/armhf", "linux/aarch64"]
}
target "build-common" {
pull = true
}
target "5_9_0" { target "5_9_0" {
inherits = ["build-dockerfile", "build-platforms", "build-common"] inherits = ["build-dockerfile", "build-platforms", "build-common"]