2018-03-29 16:35:45 +00:00
|
|
|
job "demo2" {
|
|
|
|
datacenters = ["dc1"]
|
|
|
|
type = "service"
|
|
|
|
|
|
|
|
group "t2" {
|
|
|
|
count = 3
|
|
|
|
|
|
|
|
task "t2" {
|
|
|
|
driver = "raw_exec"
|
|
|
|
|
|
|
|
config {
|
|
|
|
command = "bash"
|
2018-03-30 00:04:18 +00:00
|
|
|
args = ["-c", "sleep 7000"]
|
2018-03-29 16:35:45 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
update {
|
|
|
|
max_parallel = 1
|
2018-03-30 00:04:18 +00:00
|
|
|
min_healthy_time = "1s"
|
|
|
|
healthy_deadline = "1m"
|
2018-03-29 16:35:45 +00:00
|
|
|
auto_revert = false
|
|
|
|
}
|
|
|
|
|
|
|
|
restart {
|
|
|
|
attempts = 0
|
|
|
|
mode = "fail"
|
|
|
|
}
|
|
|
|
|
|
|
|
reschedule {
|
|
|
|
unlimited = "true"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|