mirror of https://github.com/hashicorp/consul
website: update docs for multiple checks in config
parent
28f31a8dd8
commit
f03bbb8daa
|
@ -85,3 +85,28 @@ a specific meaning. Specifically:
|
||||||
This is the only convention that Consul depends on. Any output of the script
|
This is the only convention that Consul depends on. Any output of the script
|
||||||
will be captured and stored in the `notes` field so that it can be viewed
|
will be captured and stored in the `notes` field so that it can be viewed
|
||||||
by human operators.
|
by human operators.
|
||||||
|
|
||||||
|
## Multiple Check Definitions
|
||||||
|
|
||||||
|
Multiple check definitions can be provided at once using the `checks` (plural)
|
||||||
|
key in your configuration file.
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
{
|
||||||
|
"checks": [
|
||||||
|
{
|
||||||
|
"id": "chk1",
|
||||||
|
"name": "mem",
|
||||||
|
"script": "/bin/check_mem",
|
||||||
|
"interval": "5s",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": "chk2",
|
||||||
|
"name": "cpu",
|
||||||
|
"script": "/bin/check_cpu",
|
||||||
|
"interval": "10s",
|
||||||
|
},
|
||||||
|
...
|
||||||
|
]
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
|
@ -64,7 +64,8 @@ service can be registered dynamically using the [HTTP API](/docs/agent/http.html
|
||||||
|
|
||||||
## Multiple Service Definitions
|
## Multiple Service Definitions
|
||||||
|
|
||||||
Multiple services definitions can be provided at once. Single and mutiple service definitions can't be provided together in one configuration file.
|
Multiple services definitions can be provided at once using the `services`
|
||||||
|
(plural) key in your configuration file.
|
||||||
|
|
||||||
```javascript
|
```javascript
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue