diff --git a/command/init.go b/command/init.go index 8827f5e9d..851f366be 100644 --- a/command/init.go +++ b/command/init.go @@ -104,8 +104,8 @@ job "example" { # Defaults to 1 # count = 1 - # Restart Policy - This block defines the restart policy for TaskGroups - # attempts defines the number of restarts Nomad will do if Tasks + # Restart Policy - This block defines the restart policy for TaskGroups, + # the attempts value defines the number of restarts Nomad will do if Tasks # in this TaskGroup fails in a rolling window of interval duration # The delay value makes Nomad wait for that duration to restart after a Task # fails or crashes. diff --git a/jobspec/parse.go b/jobspec/parse.go index 1c28d59ee..77f9b819f 100644 --- a/jobspec/parse.go +++ b/jobspec/parse.go @@ -30,7 +30,6 @@ func Parse(r io.Reader) (*structs.Job, error) { // Parse the buffer obj, err := hcl.Parse(buf.String()) - if err != nil { return nil, fmt.Errorf("error parsing: %s", err) } diff --git a/nomad/structs/structs.go b/nomad/structs/structs.go index 8afe1c452..a42a8f822 100644 --- a/nomad/structs/structs.go +++ b/nomad/structs/structs.go @@ -992,7 +992,6 @@ func (tg *TaskGroup) Validate() error { // Validate the tasks for idx, task := range tg.Tasks { - if err := task.Validate(); err != nil { outer := fmt.Errorf("Task %d validation failed: %s", idx+1, err) mErr.Errors = append(mErr.Errors, outer)