Created
February 28, 2023 10:46
-
-
Save carobme/d55fd1f5e71d288b16e4af1490987074 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
job "test" { | |
namespace = "test" | |
datacenters = ["dc1"] | |
type = "service" | |
group "test" { | |
task "test" { | |
driver = "exec" | |
config { | |
command = "/bin/sleep" | |
args = [900] | |
} | |
env { | |
FOO = "bar" | |
} | |
template { | |
destination = "${NOMAD_SECRETS_DIR}/test" | |
change_mode = "noop" | |
data = <<EOF | |
pwd={{ with nomadVar "nomad/jobs/test" }}{{ .foo }}{{ end }} | |
EOF | |
} | |
resources { | |
cpu = 50 | |
memory = 128 | |
memory_max = 2048 | |
} | |
restart { | |
attempts = -1 | |
delay = "15s" | |
} | |
kill_timeout = "10s" | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment