mirror of
https://github.com/kemko/nomad.git
synced 2026-01-04 09:25:46 +03:00
parse service check body
This commit is contained in:
@@ -994,6 +994,7 @@ func parseChecks(service *api.Service, checkObjs *ast.ObjectList) error {
|
||||
"success_before_passing",
|
||||
"failures_before_critical",
|
||||
"on_update",
|
||||
"body",
|
||||
}
|
||||
if err := checkHCLKeys(co.Val, valid); err != nil {
|
||||
return multierror.Prefix(err, "check ->")
|
||||
|
||||
@@ -1198,6 +1198,7 @@ func TestParse(t *testing.T) {
|
||||
InitialStatus: "passing",
|
||||
TaskName: "foo",
|
||||
OnUpdate: "ignore",
|
||||
Body: "post body",
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
@@ -25,6 +25,7 @@ job "group_service_check_script" {
|
||||
initial_status = "passing"
|
||||
task = "foo"
|
||||
on_update = "ignore"
|
||||
body = "post body"
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user