Skip to content

Commit

Permalink
Set reference config as config for docs (#6671)
Browse files Browse the repository at this point in the history
Having the reference file as example config in the docs has the advantage that all config options are shown. The assumption here is that users already know the short version of the config from the config file and come here to learn additional details.

* Clean up nginx reference config to be more similar to others
  • Loading branch information
ruflin authored and jsoriano committed Apr 9, 2018
1 parent 6cbb70f commit 2278910
Show file tree
Hide file tree
Showing 32 changed files with 336 additions and 38 deletions.
3 changes: 3 additions & 0 deletions metricbeat/docs/modules/aerospike.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: aerospike
metricsets: ["namespace"]
enabled: true
period: 10s
hosts: ["localhost:3000"]
----

Expand Down
14 changes: 14 additions & 0 deletions metricbeat/docs/modules/apache.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,21 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: apache
metricsets: ["status"]
period: 10s
enabled: true
# Apache hosts
hosts: ["http://127.0.0.1"]
# Path to server status. Default server-status
#server_status_path: "server-status"
# Username of hosts. Empty by default
#username: username
# Password of hosts. Empty by default
#password: password
----

This module supports TLS connection when using `ssl` config field, as described in <<configuration-ssl>>.
Expand Down
8 changes: 3 additions & 5 deletions metricbeat/docs/modules/ceph.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,10 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: ceph
metricsets: ["cluster_health", "cluster_status", "monitor_health"]
metricsets: ["cluster_disk", "cluster_health", "monitor_health", "pool_disk", "osd_tree"]
period: 10s
- module: ceph
metricsets: ["cluster_disk", "osd_tree", "pool_disk"]
period: 1m
hosts: ["localhost:5000"]
enabled: true
----

This module supports TLS connection when using `ssl` config field, as described in <<configuration-ssl>>.
Expand Down
3 changes: 3 additions & 0 deletions metricbeat/docs/modules/couchbase.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,10 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: couchbase
metricsets: ["bucket", "cluster", "node"]
period: 10s
hosts: ["localhost:8091"]
enabled: true
----

This module supports TLS connection when using `ssl` config field, as described in <<configuration-ssl>>.
Expand Down
17 changes: 17 additions & 0 deletions metricbeat/docs/modules/docker.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,27 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: docker
metricsets:
- "container"
- "cpu"
- "diskio"
- "healthcheck"
- "info"
#- "image"
- "memory"
- "network"
hosts: ["unix:///var/run/docker.sock"]
period: 10s
enabled: true
# Replace dots in labels with `_`. Set to false to keep dots
labels.dedot: true
# To connect to Docker over TLS you must specify a client and CA certificate.
#ssl:
#certificate_authority: "/etc/pki/root/ca.pem"
#certificate: "/etc/pki/client/cert.pem"
#key: "/etc/pki/client/cert.key"
----

[float]
Expand Down
3 changes: 3 additions & 0 deletions metricbeat/docs/modules/dropwizard.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,12 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: dropwizard
metricsets: ["collector"]
period: 10s
hosts: ["localhost:8080"]
metrics_path: /metrics/metrics
namespace: example
enabled: true
----

This module supports TLS connection when using `ssl` config field, as described in <<configuration-ssl>>.
Expand Down
2 changes: 2 additions & 0 deletions metricbeat/docs/modules/elasticsearch.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: elasticsearch
metricsets: ["node", "node_stats"]
period: 10s
hosts: ["localhost:9200"]
----

Expand Down
2 changes: 2 additions & 0 deletions metricbeat/docs/modules/etcd.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: etcd
metricsets: ["leader", "self", "store"]
period: 10s
hosts: ["localhost:2379"]
----

Expand Down
21 changes: 21 additions & 0 deletions metricbeat/docs/modules/graphite.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,27 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: graphite
metricsets: ["server"]
enabled: true
# Host address to listen on. Default localhost.
#host: localhost
# Listening port. Default 2003.
#port: 2003
# Protocol to listen on. This can be udp or tcp. Default udp.
#protocol: "udp"
# Receive buffer size in bytes
#receive_buffer_size: 1024
#templates:
# - filter: "test.*.bash.*" # This would match metrics like test.localhost.bash.stats
# namespace: "test"
# template: ".host.shell.metric*" # test.localhost.bash.stats would become metric=stats and tags host=localhost,shell=bash
# delimiter: "_"
----

[float]
Expand Down
3 changes: 3 additions & 0 deletions metricbeat/docs/modules/haproxy.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,10 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: haproxy
metricsets: ["info", "stat"]
period: 10s
hosts: ["tcp://127.0.0.1:14567"]
enabled: true
----

[float]
Expand Down
24 changes: 24 additions & 0 deletions metricbeat/docs/modules/kafka.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,31 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: kafka
metricsets: ["consumergroup", "partition"]
period: 10s
hosts: ["localhost:9092"]
enabled: true
#client_id: metricbeat
#retries: 3
#backoff: 250ms
# List of Topics to query metadata for. If empty, all topics will be queried.
#topics: []
# Optional SSL. By default is off.
# List of root certificates for HTTPS server verifications
#ssl.certificate_authorities: ["/etc/pki/root/ca.pem"]
# Certificate for SSL client authentication
#ssl.certificate: "/etc/pki/client/cert.pem"
# Client Certificate Key
#ssl.key: "/etc/pki/client/cert.key"
# SASL authentication
#username: ""
#password: ""
----

[float]
Expand Down
3 changes: 3 additions & 0 deletions metricbeat/docs/modules/kibana.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,10 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: kibana
metricsets: ["status"]
period: 10s
hosts: ["localhost:5601"]
enabled: default
----

This module supports TLS connection when using `ssl` config field, as described in <<configuration-ssl>>.
Expand Down
25 changes: 25 additions & 0 deletions metricbeat/docs/modules/kubernetes.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,39 @@ in <<configuration-metricbeat>>. Here is an example configuration:
[source,yaml]
----
metricbeat.modules:
# Node metrics, from kubelet:
- module: kubernetes
metricsets:
- container
- node
- pod
- system
- volume
period: 10s
hosts: ["localhost:10255"]
enabled: true
#ssl.certificate_authorities: ["/etc/pki/root/ca.pem"]
#ssl.certificate: "/etc/pki/client/cert.pem"
#ssl.key: "/etc/pki/client/cert.key"
# State metrics from kube-state-metrics service:
- module: kubernetes
enabled: true
metricsets:
- state_node
- state_deployment
- state_replicaset
- state_statefulset
- state_pod
- state_container
period: 10s
hosts: ["kube-state-metrics:8080"]
# Kubernetes events
- module: kubernetes
enabled: true
metricsets:
- event
----

This module supports TLS connection when using `ssl` config field, as described in <<configuration-ssl>>.
Expand Down
3 changes: 3 additions & 0 deletions metricbeat/docs/modules/logstash.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: logstash
metricsets: ["node", "node_stats"]
enabled: true
period: 10s
hosts: ["localhost:9600"]
----

Expand Down
3 changes: 3 additions & 0 deletions metricbeat/docs/modules/memcached.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,10 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: memcached
metricsets: ["stats"]
period: 10s
hosts: ["localhost:11211"]
enabled: true
----

[float]
Expand Down
15 changes: 15 additions & 0 deletions metricbeat/docs/modules/mongodb.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,22 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: mongodb
metricsets: ["dbstats", "status"]
period: 10s
enabled: true
# The hosts must be passed as MongoDB URLs in the format:
# [mongodb://][user:pass@]host[:port].
# The username and password can also be set using the respective configuration
# options. The credentials in the URL take precedence over the username and
# password configuration options.
hosts: ["localhost:27017"]
# Username to use when connecting to MongoDB. Empty by default.
#username: user
# Password to use when connecting to MongoDB. Empty by default.
#password: pass
----

[float]
Expand Down
3 changes: 3 additions & 0 deletions metricbeat/docs/modules/munin.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: munin
metricsets: ["node"]
enabled: true
period: 10s
hosts: ["localhost:4949"]
node.namespace: node
----
Expand Down
17 changes: 16 additions & 1 deletion metricbeat/docs/modules/mysql.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,22 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: mysql
hosts: ["tcp(127.0.0.1:3306)/"]
metricsets: ["status"]
period: 10s
# Host DSN should be defined as "user:pass@tcp(127.0.0.1:3306)/"
# The username and password can either be set in the DSN or using the username
# and password config options. Those specified in the DSN take precedence.
hosts: ["root:secret@tcp(127.0.0.1:3306)/"]
# Username of hosts. Empty by default.
#username: root
# Password of hosts. Empty by default.
#password: secret
# By setting raw to true, all raw fields from the status metricset will be added to the event.
#raw: false
----

[float]
Expand Down
8 changes: 8 additions & 0 deletions metricbeat/docs/modules/nginx.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,15 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: nginx
metricsets: ["stubstatus"]
enabled: true
period: 10s
# Nginx hosts
hosts: ["http://127.0.0.1"]
# Path to server status. Default server-status
server_status_path: "server-status"
----

This module supports TLS connection when using `ssl` config field, as described in <<configuration-ssl>>.
Expand Down
4 changes: 4 additions & 0 deletions metricbeat/docs/modules/php_fpm.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: php_fpm
metricsets: ["pool"]
enabled: true
period: 10s
status_path: "/status"
hosts: ["localhost:8080"]
----

Expand Down
23 changes: 23 additions & 0 deletions metricbeat/docs/modules/postgresql.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,30 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: postgresql
enabled: true
metricsets:
# Stats about every PostgreSQL database
- database
# Stats about the background writer process's activity
- bgwriter
# Stats about every PostgreSQL process
- activity
period: 10s
# The host must be passed as PostgreSQL URL. Example:
# postgres://localhost:5432?sslmode=disable
# The available parameters are documented here:
# https://godoc.org/github.com/lib/pq#hdr-Connection_String_Parameters
hosts: ["postgres://localhost:5432"]
# Username to use when connecting to PostgreSQL. Empty by default.
#username: user
# Password to use when connecting to PostgreSQL. Empty by default.
#password: pass
----

[float]
Expand Down
11 changes: 11 additions & 0 deletions metricbeat/docs/modules/prometheus.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,19 @@ in <<configuration-metricbeat>>. Here is an example configuration:
----
metricbeat.modules:
- module: prometheus
metricsets: ["stats"]
enabled: true
period: 10s
hosts: ["localhost:9090"]
#metrics_path: /metrics
#namespace: example
- module: prometheus
metricsets: ["collector"]
enabled: true
period: 10s
hosts: ["localhost:9090"]
#metrics_path: /metrics
#namespace: example
----

Expand Down
Loading

0 comments on commit 2278910

Please sign in to comment.