Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions command/asset/connect-short.nomad.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ job "countdash" {
}

task "web" {
driver = "docker"
driver = "docker"
shutdown_delay = "10s"

config {
image = "hashicorpdev/counter-api:v3"
Expand Down Expand Up @@ -51,7 +52,8 @@ job "countdash" {
}

task "dashboard" {
driver = "docker"
driver = "docker"
shutdown_delay = "10s"

env {
COUNTING_SERVICE_URL = "http://${NOMAD_UPSTREAM_ADDR_count_api}"
Expand Down
22 changes: 22 additions & 0 deletions command/asset/connect.nomad.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,17 @@ job "countdash" {
auth_soft_fail = true
}

# Specifies the duration to wait when killing a task between removing its
# service registrations from Consul or Nomad, and sending it a shutdown
# signal. Ideally services would fail health checks once they receive a
# shutdown signal.
#
# For more information on the "shutdown_delay" parameter, refer to:
#
# https://developer.hashicorp.com/nomad/docs/job-specification/task#shutdown_delay
#
shutdown_delay = "10s"

# The "resources" block describes the requirements a task needs to
# execute. Resource requirements include attributes such as memory, cpu,
# cores, and devices.
Expand Down Expand Up @@ -232,6 +243,17 @@ job "countdash" {
image = "hashicorpdev/counter-dashboard:v3"
auth_soft_fail = true
}

# Specifies the duration to wait when killing a task between removing its
# service registrations from Consul or Nomad, and sending it a shutdown
# signal. Ideally services would fail health checks once they receive a
# shutdown signal.
#
# For more information on the "shutdown_delay" parameter, refer to:
#
# https://developer.hashicorp.com/nomad/docs/job-specification/task#shutdown_delay
#
shutdown_delay = "10s"
}
}
}
11 changes: 11 additions & 0 deletions command/asset/example.nomad.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -300,6 +300,17 @@ job "example" {
auth_soft_fail = true
}

# Specifies the duration to wait when killing a task between removing its
# service registrations from Consul or Nomad, and sending it a shutdown
# signal. Ideally services would fail health checks once they receive a
# shutdown signal.
#
# For more information on the "shutdown_delay" parameter, refer to:
#
# https://developer.hashicorp.com/nomad/docs/job-specification/task#shutdown_delay
#
shutdown_delay = "10s"

# The "artifact" block instructs Nomad to download an artifact from a
# remote source prior to starting the task. This provides a convenient
# mechanism for downloading configuration files or data needed to run the
Expand Down
Loading