orchestration-tests/nomad/backups/backups.tf
Ian Fijolek 9a315eb2f7 Add lldap backup and templatize backup job
Now oneoff and system jobs are all using the same template
2022-07-27 17:02:29 -07:00

15 lines
367 B
HCL

resource "nomad_job" "backups" {
jobspec = templatefile("${path.module}/backup.nomad", {
module_path = "${path.module}",
batch_node = null,
})
}
resource "nomad_job" "backups-oneoff" {
for_each = toset(["n1", "n2", "n3"])
jobspec = templatefile("${path.module}/backup.nomad", {
module_path = "${path.module}",
batch_node = each.key,
})
}