Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix kubernetes provider documentation #817

Merged
merged 4 commits into from
Jan 18, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -68,12 +68,17 @@ will be excluded from the event.
By default it is `true`.
`annotations.dedot`:: (Optional) If set to be `true` in the provider config, then `.` in annotations will be replaced
with `_`. By default it is `true`.
`add_resource_metadata`:: (Optional) Specify labels and annotations filters for the extra metadata coming from node and namespace.
`add_resource_metadata` can be done for `node` or `namespace`. By default all labels are included
while annotations are not. These settings are useful when storing labels and annotations
that require special handling to avoid overloading the storage output. The enrichment of `node` or `namespace` metadata
can be individually disabled by setting `enabled: false`.
Example:

`add_resource_metadata`:: (Optional) Specify filters and configration for the extra metadata, that will be added to the event.
Configuration parameters:
* `node` or `namespace`: Specify labels and annotations filters for the extra metadata coming from node and namespace. By default
all labels are included while annotations are not. To change default behaviour `include_labels`, `exclude_labels` and `include_annotations`
can be defined. Those settings are useful when storing labels and annotations that require special handling to avoid overloading the storage output.
tetianakravchenko marked this conversation as resolved.
Show resolved Hide resolved
Note: wildcards are not supported for those settings.
The enrichment of `node` or `namespace` metadata can be individually disabled by setting `enabled: false`.
* `deployment`: If resource is `pod` and it is created from a `deployment`, by default the deployment name isn't added, this can be enabled by setting `deployment: true`.
* `cronjob`: If resource is `pod` and it is created from a `cronjob`, by default the cronjob name isn't added, this can be enabled by setting `cronjob: true`.
Example:

["source","yaml",subs="attributes"]
-------------------------------------------------------------------------------------
Expand All @@ -83,6 +88,8 @@ Example:
node:
include_labels: ["nodelabel2"]
include_annotations: ["nodeannotation1"]
deployment: true
tetianakravchenko marked this conversation as resolved.
Show resolved Hide resolved
cronjob: true
tetianakravchenko marked this conversation as resolved.
Show resolved Hide resolved
-------------------------------------------------------------------------------------


Expand All @@ -94,29 +101,29 @@ The available keys are:
|===
|Key |Type |Description

|`kubernetes.namespace.name`
|`kubernetes.namespace`
|`string`
|Namespace of the Pod

|`kubernetes.namespace.uuid`
|`kubernetes.namespace_uid`
|`string`
|UUID of the Namespace of the Pod
|UID of the Namespace of the Pod

|`kubernetes.namespace.labels.*`
|`kubernetes.namespace_labels.*`
|`object`
|Labels of the Namespace of the Pod

|`kubernetes.namespace.annotations.*`
|`kubernetes.namespace_annotations.*`
|`object`
|Annotations of the Namespace of the Pod

|`kubernetes.pod.name`
|`string`
|Name of the Pod

|`kubernetes.pod.uuid`
|`kubernetes.pod.uid`
|`string`
|UUID of the Pod
|UID of the Pod

|`kubernetes.pod.ip`
|`string`
Expand All @@ -128,7 +135,7 @@ The available keys are:

|`kubernetes.annotations.*`
|`object`
|Object of labels of the Pod
|Object of annotations of the Pod

|`kubernetes.container.name`
|`string`
Expand Down Expand Up @@ -295,19 +302,19 @@ The available keys are:
|===
|Key |Type |Description

|`kubernetes.namespace.name`
|`kubernetes.namespace`
|`string`
|Namespace of the Service

|`kubernetes.namespace.uuid`
|`kubernetes.namespace_uid`
|`string`
|UUID of the Namespace of the Service
|UID of the Namespace of the Service

|`kubernetes.namespace.labels.*`
|`kubernetes.namespace_labels.*`
|`object`
|Labels of the Namespace of the Service

|`kubernetes.namespace.annotations.*`
|`kubernetes.namespace_annotations.*`
|`object`
|Annotations of the Namespace of the Service

Expand All @@ -333,4 +340,4 @@ The available keys are:
|===

Refer to <<elastic-agent-kubernetes-autodiscovery,kubernetes autodiscovery with Elastic Agent>>
for more information about shaping dynamic inputs for autodiscovery.
for more information about shaping dynamic inputs for autodiscovery.