-
Notifications
You must be signed in to change notification settings - Fork 19
/
Copy pathmain.tf
34 lines (29 loc) · 862 Bytes
/
main.tf
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
terraform {
required_providers {
apko = {
source = "chainguard-dev/apko"
configuration_aliases = [apko.local]
}
oci = { source = "chainguard-dev/oci" }
}
}
variable "target_repository" {
description = "The docker repo into which the image and attestations should be published."
}
module "latest" {
providers = { apko = apko.local }
source = "chainguard-dev/apko/publisher"
version = "0.0.17"
target_repository = var.target_repository
config = file("${path.module}/configs/latest.apko.yaml")
check_sbom = false // chainctl doesn't use SPDX compliant license
}
module "test-latest" {
source = "./tests"
digest = module.latest.image_ref
}
resource "oci_tag" "version-tags" {
depends_on = [module.test-latest]
digest_ref = module.latest.image_ref
tag = "latest"
}