Initial commit

This commit is contained in:
Никита Сычев
2026-01-03 23:09:01 +01:00
commit d0cb02102e
14 changed files with 389 additions and 0 deletions
+62
View File
@@ -0,0 +1,62 @@
variable "registry" {
default = "repo.nstart.local"
}
variable "base_repo" {
default = "repo.nstart.local/"
}
variable "VERSION" {
default = "1.0.1"
}
function "oci_labels" {
params = [name]
result = {
"org.opencontainers.image.version" = VERSION,
"org.opencontainers.image.vendor" = "New Start",
"org.opencontainers.image.authors" = "Sychev Nikita <Sychev.NA@nstart.space>",
}
}
function "image_ref" {
params = [name]
result = registry != "" ? "${registry}/nstart/vaultwarden-${name}" : "nstart/vaultwarden-${name}"
}
target "image" {
name = combo.image
matrix = {
combo = [
{ image = "server" },
{ image = "backup" },
{ image = "proxy" }
]
}
platforms = ["linux/amd64"]
output = ["type=image"]
attest = [
"type=sbom,generator=${registry}/docker/buildkit-syft-scanner:stable-1",
"type=provenance,mode=max"
]
context = combo.image
dockerfile = "Dockerfile"
args = {
BASE_REPO = base_repo
}
tags = [
"${image_ref(combo.image)}:${VERSION}",
"${image_ref(combo.image)}:latest",
]
labels = oci_labels(combo.image)
}
group "all" {
targets = ["image"]
}