mirror of
https://github.com/kemko/nomad.git
synced 2026-01-04 17:35:43 +03:00
The `TestTemplateUpdateTriggers` is flaky because of what turned out to be incompatibility between the Consul agent on the E2E cluster and the HCP Consul server we were running but hadn't upgraded in a while. Upgrading the HCP Consul server seems to have fixed the tests, but while I'm in here I've updated this test suite: * Port all the consul template test suite off of the old framework, and upgrade to using e2e "v3" where feasible. * Clean up some of the assertions in the update triggers test to make the purpose of the test more clear. * Remove unnecessary default fields from the job specs. Closes: #19075
40 lines
629 B
HCL
40 lines
629 B
HCL
# Copyright (c) HashiCorp, Inc.
|
|
# SPDX-License-Identifier: BUSL-1.1
|
|
|
|
job "bad-template-paths" {
|
|
|
|
constraint {
|
|
attribute = "${attr.kernel.name}"
|
|
value = "linux"
|
|
}
|
|
|
|
group "template-paths" {
|
|
|
|
restart {
|
|
attempts = 0
|
|
mode = "fail"
|
|
}
|
|
|
|
task "task" {
|
|
|
|
driver = "docker"
|
|
|
|
config {
|
|
image = "busybox:1"
|
|
command = "/bin/sh"
|
|
args = ["-c", "sleep 300"]
|
|
}
|
|
|
|
template {
|
|
source = "/etc/passwd"
|
|
destination = "${NOMAD_SECRETS_DIR}/foo/dst"
|
|
}
|
|
|
|
resources {
|
|
cpu = 128
|
|
memory = 64
|
|
}
|
|
}
|
|
}
|
|
}
|