Skip to content

Commit 8c90daa

Browse files
authored
in_syslog: add examples for yaml configuration (#1335)
Signed-off-by: Takahiro Yamashita <[email protected]>
1 parent 48f9e48 commit 8c90daa

File tree

1 file changed

+68
-1
lines changed

1 file changed

+68
-1
lines changed

pipeline/inputs/syslog.md

+68-1
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,8 @@ By default the service will create and listen for Syslog messages on the unix so
4242

4343
In your main configuration file append the following _Input_ & _Output_ sections:
4444

45+
{% tabs %}
46+
{% tab title="fluent-bit.conf" %}
4547
```python
4648
[SERVICE]
4749
Flush 1
@@ -59,6 +61,27 @@ In your main configuration file append the following _Input_ & _Output_ sections
5961
Name stdout
6062
Match *
6163
```
64+
{% endtab %}
65+
66+
{% tab title="fluent-bit.yaml" %}
67+
```yaml
68+
service:
69+
flush: 1
70+
log_level: info
71+
parsers_file: parsers.conf
72+
pipeline:
73+
inputs:
74+
- name: syslog
75+
path: /tmp/in_syslog
76+
buffer_chunk_size: 32000
77+
buffer_max_size: 64000
78+
receive_buffer_size: 512000
79+
outputs:
80+
- name: stdout
81+
match: '*'
82+
```
83+
{% endtab %}
84+
{% endtabs %}
6285
6386
### Testing
6487
@@ -90,8 +113,10 @@ The following content aims to provide configuration examples for different use c
90113

91114
#### Fluent Bit Configuration
92115

93-
Put the following content in your fluent-bit.conf file:
116+
Put the following content in your configuration file:
94117

118+
{% tabs %}
119+
{% tab title="fluent-bit.conf" %}
95120
```text
96121
[SERVICE]
97122
Flush 1
@@ -108,6 +133,26 @@ Put the following content in your fluent-bit.conf file:
108133
Name stdout
109134
Match *
110135
```
136+
{% endtab %}
137+
138+
{% tab title="fluent-bit.yaml" %}
139+
```yaml
140+
service:
141+
flush: 1
142+
parsers_file: parsers.conf
143+
pipeline:
144+
inputs:
145+
- name: syslog
146+
parser: syslog-rfc3164
147+
listen: 0.0.0.0
148+
port: 5140
149+
mode: tcp
150+
outputs:
151+
- name: stdout
152+
match: '*'
153+
```
154+
{% endtab %}
155+
{% endtabs %}
111156
112157
then start Fluent Bit.
113158
@@ -131,6 +176,8 @@ $ sudo service rsyslog restart
131176

132177
Put the following content in your fluent-bit.conf file:
133178

179+
{% tabs %}
180+
{% tab title="fluent-bit.conf" %}
134181
```text
135182
[SERVICE]
136183
Flush 1
@@ -147,6 +194,26 @@ Put the following content in your fluent-bit.conf file:
147194
Name stdout
148195
Match *
149196
```
197+
{% endtab %}
198+
199+
{% tab title="fluent-bit.yaml" %}
200+
```yaml
201+
service:
202+
flush: 1
203+
parsers_file: parsers.conf
204+
pipeline:
205+
inputs:
206+
- name: syslog
207+
parser: syslog-rfc3164
208+
path: /tmp/fluent-bit.sock
209+
mode: unix_udp
210+
unix_perm: 0644
211+
outputs:
212+
- name: stdout
213+
match: '*'
214+
```
215+
{% endtab %}
216+
{% endtabs %}
150217
151218
then start Fluent Bit.
152219

0 commit comments

Comments
 (0)