This will be needed to make the initial tags. Once merged to main, I will tag with the same module revisions as what exists in the Fleet repo. We can then test the example module using the new settings. Once validated, we'll then update the main fleet repo to redirect here for /terraform and remove everything there. Anything referring to old tags will still work in-place. Additionally any website references will be updated as well to reflect these changes.
33 lines
648 B
Terraform
33 lines
648 B
Terraform
terraform {
|
|
required_providers {
|
|
docker = {
|
|
source = "kreuzwerker/docker"
|
|
version = "3.0.2"
|
|
}
|
|
}
|
|
}
|
|
|
|
# Build the new image
|
|
resource "docker_image" "maxmind_fleet" {
|
|
name = var.destination_image
|
|
|
|
build {
|
|
context = path.module
|
|
platform = "linux/amd64"
|
|
build_args = {
|
|
FLEET_IMAGE = var.fleet_image
|
|
LICENSE_KEY = var.license_key
|
|
}
|
|
pull_parent = true
|
|
}
|
|
}
|
|
|
|
# push it to the specified repo
|
|
resource "docker_registry_image" "maxmind_fleet" {
|
|
triggers = {
|
|
fleet_digest = docker_image.maxmind_fleet.repo_digest
|
|
}
|
|
name = docker_image.maxmind_fleet.name
|
|
keep_remotely = true
|
|
}
|