Merge pull request #1457 from hashicorp/f-kill-event

Add killing event and mark task as not running when killed
This commit is contained in:
Alex Dadgar
2016-07-22 17:33:18 -07:00
committed by GitHub
5 changed files with 30 additions and 0 deletions

View File

@@ -223,6 +223,12 @@ func (c *AllocStatusCommand) outputTaskStatus(state *api.TaskState) {
} else {
desc = "Failed to download artifacts"
}
case api.TaskKilling:
if event.KillTimeout != 0 {
desc = fmt.Sprintf("Sent interupt. Waiting %v before force killing", event.KillTimeout)
} else {
desc = "Sent interupt"
}
case api.TaskKilled:
if event.KillError != "" {
desc = event.KillError