File tree Expand file tree Collapse file tree 1 file changed +51
-2
lines changed Expand file tree Collapse file tree 1 file changed +51
-2
lines changed Original file line number Diff line number Diff line change @@ -29,17 +29,63 @@ The `Time_Format` should be aligned for the format of your using timestamp.
2929
3030This example assumes the WASM program writes JSON style strings to ` stdout ` .
3131
32- ``` python
32+ {% tabs %}
33+ {% tab title="parsers.yaml" %}
34+
35+ ``` yaml
36+ parsers :
37+ - name : wasi
38+ format : json
39+ time_key : time
40+ time_format : ' %Y-%m-%dT%H:%M:%S.%L %z'
41+ ` ` `
42+
43+ {% endtab %}
44+ {% tab title="parsers.conf" %}
45+
46+ ` ` ` text
3347[PARSER]
3448 Name wasi
3549 Format json
3650 Time_Key time
3751 Time_Format %Y-%m-%dT%H:%M:%S.%L %z
3852```
3953
54+ {% endtab %}
55+ {% endtabs %}
56+
4057Then, you can specify the ` parsers.conf ` in the main Fluent Bit configuration:
4158
42- ``` python
59+ {% tabs %}
60+ {% tab title="fluent-bit.yaml" %}
61+
62+ ``` yaml
63+ service :
64+ flush : 1
65+ daemon : off
66+ parsers_file : parsers.yaml
67+ log_level : info
68+ http_server : off
69+ http_listen : 0.0.0.0
70+ http_port : 2020
71+
72+ pipeline :
73+ inputs :
74+ - name : exec_wasi
75+ tag : exec.wasi.local
76+ wasi_path : /path/to/wasi/program.wasm
77+ # Note: run from the 'wasi_path' location.
78+ accessible_paths : /path/to/accessible
79+
80+ outputs :
81+ - name : stdout
82+ match : ' *'
83+ ` ` `
84+
85+ {% endtab %}
86+ {% tab title="fluent-bit.conf" %}
87+
88+ ` ` ` text
4389[SERVICE]
4490 Flush 1
4591 Daemon Off
@@ -61,3 +107,6 @@ Then, you can specify the `parsers.conf` in the main Fluent Bit configuration:
61107 Match *
62108
63109```
110+
111+ {% endtab %}
112+ {% endtabs %}
You can’t perform that action at this time.
0 commit comments