website: document registering checks and services better. Fixes #6

This commit is contained in:
Armon Dadgar 2014-02-22 18:53:31 -08:00
parent 5726da7b59
commit 0a19fdd10a
3 changed files with 14 additions and 1 deletions

View File

@ -60,6 +60,12 @@ readable descriptions. The field is set to any output that a script
generates, and similarly the TTL update hooks can update the `notes`
as well.
To configure a check, either provide it as a `-config-file` option to the
agent, or place it inside the `-config-dir` of the agent. The file must
end in the ".json" extension to be loaded by Consul. Check definitions can
also be updated by sending a `SIGHUP` to the agent. Alternatively, the
check can be registered dynamically using the [HTTP API](/docs/agent/http.html).
## Check Scripts
A check script is generally free to do anything to determine the status

View File

@ -132,7 +132,8 @@ Configuration files are used for more than just setting up the agent,
they are also used to provide check and service definitions. These are used
to announce the availability of system servers to the rest of the cluster.
They are documented seperately under [check configuration](/docs/agent/checks.html) and
[service configuration](/docs/agent/services.html) respectively.
[service configuration](/docs/agent/services.html) respectively. The service and check
definitions support being updated during a reload.
#### Example Configuration File

View File

@ -52,3 +52,9 @@ check must be of the script or TTL type. If it is a script type, `script` and
`interval` must be provided. If it is a TTL type, then only `ttl` must be
provided. The check name is automatically generated as "service:<service-id>".
To configure a service, either provide it as a `-config-file` option to the
agent, or place it inside the `-config-dir` of the agent. The file must
end in the ".json" extension to be loaded by Consul. Check definitions can
also be updated by sending a `SIGHUP` to the agent. Alternatively, the
service can be registered dynamically using the [HTTP API](/docs/agent/http.html).