Skip to content

Commit fcf3273

Browse files
bardabunSimplychee
andauthored
Refine Fluent Bit env var examples and update Filebeat tab order (#747)
* Improve examples in fluentbit env var table --------- Co-authored-by: Henn Idan <simplychee@gmail.com>
1 parent 62db677 commit fcf3273

File tree

1 file changed

+54
-54
lines changed

1 file changed

+54
-54
lines changed

docs/shipping/Containers/docker.md

Lines changed: 54 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,60 @@ import Tabs from '@theme/Tabs';
2828
import TabItem from '@theme/TabItem';
2929

3030
<Tabs>
31+
<TabItem value="fluentbit-docker" label="Fluent Bit" default>
32+
33+
:::note
34+
[Project's GitHub repo](https://github.com/logzio/docker-logs-collector)
35+
:::
36+
37+
38+
#### Pull the Docker image
39+
40+
Download the logzio/docker-collector-logs image.
41+
42+
```shell
43+
docker pull logzio/docker-logs-collector:latest
44+
```
45+
46+
#### Run the Docker image
47+
48+
49+
For a complete list of options, see the parameters below the code block.👇
50+
51+
##### Docker
52+
53+
```shell
54+
docker run --name docker-logs-collector \
55+
--env LOGZIO_LOGS_TOKEN="<LOGS-SHIPPING-TOKEN>" \
56+
-v /var/run/docker.sock:/var/run/docker.sock:ro \
57+
-v /var/lib/docker/containers:/var/lib/docker/containers \
58+
-e HEADERS="user-agent:logzio-docker-logs" \
59+
logzio/docker-logs-collector:latest
60+
```
61+
#### Parameters
62+
63+
| Parameter | Description | Field Type |
64+
|---|---|---|
65+
| LOGZIO_LOGS_TOKEN| Your Logz.io logs account token. Replace `<LOGS-SHIPPING-TOKEN>` with the [token](https://app.logz.io/#/dashboard/settings/general) associated with the account you want to use for shipping logs. | Required |
66+
| LOGZIO_URL | The full URL to send logs to, including your region if needed. For example, for the EU region, use `https://listener-eu.logz.io:8071`. | _Default_: `https://listener.logz.io:8071` |
67+
| LOGZIO_TYPE | Sets the log type.| _Default_: `logzio-docker-logs` |
68+
| MATCH_CONTAINER_NAME | Specify a container to collect logs from. If the container's name matches, its logs are shipped; otherwise, its logs are ignored. **Note**: This option cannot be used with SKIP_CONTAINER_NAMES. Use regular expressions to keep records that match a specific field.| _optional_ (Example: `^my-app-container.*`) |
69+
| SKIP_CONTAINER_NAMES | Comma-separated list of containers to ignore. If a container's name matches a name on this list, its logs are ignored; otherwise, its logs are shipped. **Note**: This option cannot be used with MATCH_CONTAINER_NAME. Use regular expressions to exclude records matching a specific field. | _optional_ (Example: `test-container,debug-container`)|
70+
| MATCH_IMAGE_NAME | Specify an image to collect logs from. If the image's name matches, its logs are shipped; otherwise, its logs are ignored. **Note**: This option cannot be used with SKIP_IMAGE_NAMES. Use regular expressions to keep records that match a specific field. | _optional_ (Example: `my-app-image:v1.2.3`) |
71+
| SKIP_IMAGE_NAMES | Comma-separated list of images to ignore. If an image's name matches a name on this list, its logs are ignored; otherwise, its logs are shipped. **Note**: This option cannot be used with MATCH_IMAGE_NAME. Use regular expressions to exclude records that match a specific field. | _optional_ (Example: `test-image,debug-image`)|
72+
| INCLUDE_LINE | Regular expression to match which lines Fluent Bit should include. | _optional_ (Example: `^ERROR.*`) |
73+
| EXCLUDE_LINES | Regular expression to match which lines Fluent Bit should exclude. | _optional_ (Example: `.*DEBUG.*`) |
74+
| ADDITIONAL_FIELDS | Include additional fields with every message sent, formatted as `"fieldName1:fieldValue1,fieldName2:fieldValue2"`.| _optional_ |
75+
| SET_FIELDS | Set fields with every message sent, formatted as `"fieldName1:fieldValue1,fieldName2:fieldValue2"`. | _optional_ |
76+
| LOG_LEVEL | Set log level for Fluent Bit. Allowed values: `debug`, `info`, `warning`, `error`.| _Default_: `info` |
77+
| MULTILINE_START_STATE_RULE** | Regular expression for the start state rule of multiline parsing. See [Fluent Bit's official documentation](https://docs.fluentbit.io/manual/administration/configuring-fluent-bit/multiline-parsing#rules-definition) for further info.| _optional_ (Example: `^Exception`) |
78+
| MULTILINE_CUSTOM_RULES | Custom rules for multiline parsing, separated by semicolons `;`.| _optional_ (Example: `^\\sat\\s;^Caused by:`) |
79+
| READ_FROM_HEAD | Specify if Fluent Bit should read logs from the beginning.|_Default_: `true`|
80+
| OUTPUT_ID | Specify the output ID for Fluent Bit logs.|_Default_: `output_id`|
81+
| HEADERS | Custom headers for Fluent Bit logs.| _optional_ (Example: `x-custom-header:myCustomValue,x-other-header:someOtherValue`) |
82+
83+
84+
</TabItem>
3185
<TabItem value="filebeat-docker" label="Filebeat" default>
3286

3387
:::note
@@ -104,60 +158,6 @@ By default, logs from docker-collector-logs and docker-collector-metrics contain
104158
:::
105159

106160

107-
</TabItem>
108-
<TabItem value="fluentbit-docker" label="Fluent Bit" default>
109-
110-
:::note
111-
[Project's GitHub repo](https://github.com/logzio/docker-logs-collector)
112-
:::
113-
114-
115-
#### Pull the Docker image
116-
117-
Download the logzio/docker-collector-logs image.
118-
119-
```shell
120-
docker pull logzio/docker-logs-collector:latest
121-
```
122-
123-
#### Run the Docker image
124-
125-
126-
For a complete list of options, see the parameters below the code block.👇
127-
128-
##### Docker
129-
130-
```shell
131-
docker run --name docker-logs-collector \
132-
--env LOGZIO_LOGS_TOKEN="<LOGS-SHIPPING-TOKEN>" \
133-
-v /var/run/docker.sock:/var/run/docker.sock:ro \
134-
-v /var/lib/docker/containers:/var/lib/docker/containers \
135-
-e HEADERS="user-agent:logzio-docker-logs" \
136-
logzio/docker-logs-collector:latest
137-
```
138-
#### Parameters
139-
140-
| Parameter | Description | Field Type |
141-
|---|---|---|
142-
| LOGZIO_LOGS_TOKEN| Your Logz.io logs account token. Replace `<LOGS-SHIPPING-TOKEN>` with the [token](https://app.logz.io/#/dashboard/settings/general) associated with the account you want to use for shipping logs. | Required |
143-
| LOGZIO_URL | The full URL to send logs to, including your region if needed. For example, for the EU region, use `https://listener-eu.logz.io:8071`. | _Default_: `https://listener.logz.io:8071` |
144-
| LOGZIO_TYPE | Sets the log type.| _Default_: `logzio-docker-logs` |
145-
| MATCH_CONTAINER_NAME | Specify a container to collect logs from. If the container's name matches, its logs are shipped; otherwise, its logs are ignored. **Note**: This option cannot be used with SKIP_CONTAINER_NAMES. Use regular expressions to keep records that match a specific field.| _optional_ |
146-
| SKIP_CONTAINER_NAMES | Comma-separated list of containers to ignore. If a container's name matches a name on this list, its logs are ignored; otherwise, its logs are shipped. **Note**: This option cannot be used with MATCH_CONTAINER_NAME. Use regular expressions to exclude records matching a specific field. | _optional_ |
147-
| MATCH_IMAGE_NAME | Specify an image to collect logs from. If the image's name matches, its logs are shipped; otherwise, its logs are ignored. **Note**: This option cannot be used with SKIP_IMAGE_NAMES. Use regular expressions to keep records that matching a specific field. | _optional_ |
148-
| SKIP_IMAGE_NAMES | Comma-separated list of images to ignore. If an image's name matches a name on this list, its logs are ignored; otherwise, its logs are shipped. **Note**: This option cannot be used with MATCH_IMAGE_NAME. Use regular expressions to exclude records that match a specific field. | _optional_ |
149-
| INCLUDE_LINE | Regular expression to match which lines Fluent Bit should include. | _optional_ |
150-
| EXCLUDE_LINES | Regular expression to match which lines Fluent Bit should exclude. | _optional_ |
151-
| ADDITIONAL_FIELDS | Include additional fields with every message sent, formatted as `"fieldName1:fieldValue1,fieldName2:fieldValue2"`.| _optional_ |
152-
| SET_FIELDS | Set fields with every message sent, formatted as `"fieldName1:fieldValue1,fieldName2:fieldValue2"`. | _optional_ |
153-
| LOG_LEVEL | Set log level for Fluent Bit. Allowed values: `debug`, `info`, `warning`, `error`.| _Default_: `info` |
154-
| MULTILINE_START_STATE_RULE** | Regular expression for the start state rule of multiline parsing. See [Fluent Bit's official documentation](https://docs.fluentbit.io/manual/administration/configuring-fluent-bit/multiline-parsing#rules-definition) for further info.| _optional_ |
155-
| MULTILINE_CUSTOM_RULES | Custom rules for multiline parsing, separated by semicolons `;`.| _Optional_ |
156-
| READ_FROM_HEAD | Specify if Fluent Bit should read logs from the beginning.|_Default_: `true`|
157-
| OUTPUT_ID | Specify the output ID for Fluent Bit logs.|_Default_: `output_id`|
158-
| HEADERS | Custom headers for Fluent Bit logs.| _optional_ |
159-
160-
161161
</TabItem>
162162
</Tabs>
163163

0 commit comments

Comments
 (0)