From 5757483d2e953707b030a5cccf968b4cbc05f827 Mon Sep 17 00:00:00 2001 From: "Eric D. Schabell" Date: Tue, 8 Jul 2025 11:36:24 +0200 Subject: [PATCH 1/5] Standardizing shell commands, part of issue #1872. Signed-off-by: Eric D. Schabell --- pipeline/filters/aws-metadata.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pipeline/filters/aws-metadata.md b/pipeline/filters/aws-metadata.md index 08c0adb94..9f36f3f79 100644 --- a/pipeline/filters/aws-metadata.md +++ b/pipeline/filters/aws-metadata.md @@ -29,7 +29,7 @@ If you run Fluent Bit in a container, you might need to use instance metadata v1 Run Fluent Bit from the command line: ```shell -fluent-bit -c /PATH_TO_CONF_FILE/fluent-bit.conf +$ ./fluent-bit -c /PATH_TO_CONF_FILE/fluent-bit.conf ``` You should see results like this: @@ -188,4 +188,4 @@ The resulting logs might look like this: ```text {"log"=>"aws is awesome", "az"=>"us-east-1a", "ec2_instance_id"=>"i-0e66fc7f9809d7168", "Name"=>"fluent-bit-docs-example", "project"=>"fluentbit"} -``` +``` \ No newline at end of file From 9f6cee0c8f4d39894b56fa995eb3263c8dc155d2 Mon Sep 17 00:00:00 2001 From: "Eric D. Schabell" Date: Tue, 8 Jul 2025 11:40:23 +0200 Subject: [PATCH 2/5] Standardizing shell commands, fixed tabs layout for lua filter doc, part of issue #1872. Signed-off-by: Eric D. Schabell --- pipeline/filters/lua.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pipeline/filters/lua.md b/pipeline/filters/lua.md index 520935ef8..4b9973ea3 100644 --- a/pipeline/filters/lua.md +++ b/pipeline/filters/lua.md @@ -58,7 +58,7 @@ pipeline: match: '*' ``` -{% tabs %} +{% endtab %} {% tab title="fluent-bit.conf" %} ```text @@ -157,7 +157,7 @@ pipeline: {% endtab %} {% tab title="fluent-bit.conf" %} -``` +```text [SERVICE] flush 1 daemon off From 3df643a460a8e56927b85c99e5930241ae39134a Mon Sep 17 00:00:00 2001 From: "Eric D. Schabell" Date: Tue, 8 Jul 2025 11:41:33 +0200 Subject: [PATCH 3/5] Standardizing shell commands for record modifier filter doc, part of issue #1872. Signed-off-by: Eric D. Schabell --- pipeline/filters/record-modifier.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pipeline/filters/record-modifier.md b/pipeline/filters/record-modifier.md index 0d399da23..4afe8651f 100644 --- a/pipeline/filters/record-modifier.md +++ b/pipeline/filters/record-modifier.md @@ -76,7 +76,7 @@ pipeline: You can run the filter from command line: ```shell -fluent-bit -i mem -o stdout -F record_modifier -p 'Record=hostname ${HOSTNAME}' -p 'Record=product Awesome_Tool' -m '*' +$ ./fluent-bit -i mem -o stdout -F record_modifier -p 'Record=hostname ${HOSTNAME}' -p 'Record=product Awesome_Tool' -m '*' ``` The output looks something like: @@ -137,7 +137,7 @@ pipeline: You can also run the filter from command line. ```shell -fluent-bit -i mem -o stdout -F record_modifier -p 'Remove_key=Swap.total' -p 'Remove_key=Swap.free' -p 'Remove_key=Swap.used' -m '*' +$ ./fluent-bit -i mem -o stdout -F record_modifier -p 'Remove_key=Swap.total' -p 'Remove_key=Swap.free' -p 'Remove_key=Swap.used' -m '*' ``` The output looks something like: @@ -198,11 +198,11 @@ pipeline: You can also run the filter from command line: ```shell -fluent-bit -i mem -o stdout -F record_modifier -p 'Allowlist_key=Mem.total' -p 'Allowlist_key=Mem.free' -p 'Allowlist_key=Mem.used' -m '*' +$ ./fluent-bit -i mem -o stdout -F record_modifier -p 'Allowlist_key=Mem.total' -p 'Allowlist_key=Mem.free' -p 'Allowlist_key=Mem.used' -m '*' ``` The output looks something like: ```text [0] mem.local: [1492436998.000000000, {"Mem.total"=>1016024, "Mem.used"=>716672, "Mem.free"=>295332}] -``` +``` \ No newline at end of file From d43f525014258e3aebe890e8b903d7b9653a61ae Mon Sep 17 00:00:00 2001 From: "Eric D. Schabell" Date: Tue, 8 Jul 2025 11:43:03 +0200 Subject: [PATCH 4/5] Standardizing shell commands for throttle filter doc, part of issue #1872. Signed-off-by: Eric D. Schabell --- pipeline/filters/throttle.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pipeline/filters/throttle.md b/pipeline/filters/throttle.md index 14ed83700..bd5fe70a4 100644 --- a/pipeline/filters/throttle.md +++ b/pipeline/filters/throttle.md @@ -112,7 +112,7 @@ It's suggested to use a configuration file. The following command will load the Tail plugin and read the content of the `lines.txt` file. Then, the Throttle filter will apply a rate limit and only pass the records which are read below the `rate`: ```shell -bin/fluent-bit -i tail -p 'path=lines.txt' -F throttle -p 'rate=1' -m '*' -o stdout +$ ./fluent-bit -i tail -p 'path=lines.txt' -F throttle -p 'rate=1' -m '*' -o stdout ``` ### Configuration File From 62bf1075329f1117d79be1d86f002d8aeccb8dba Mon Sep 17 00:00:00 2001 From: "Eric D. Schabell" Date: Tue, 8 Jul 2025 11:44:17 +0200 Subject: [PATCH 5/5] Standardizing shell commands for tensor filter doc, part of issue #1872. Signed-off-by: Eric D. Schabell --- pipeline/filters/tensorflow.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pipeline/filters/tensorflow.md b/pipeline/filters/tensorflow.md index 8ad35a74d..7cf11f08c 100644 --- a/pipeline/filters/tensorflow.md +++ b/pipeline/filters/tensorflow.md @@ -29,7 +29,7 @@ To create a Tensorflow Lite shared library: 1. Run the following command to create the shared library: ```shell - bazel build -c opt //tensorflow/lite/c:tensorflowlite_c # see https://github.com/tensorflow/tensorflow/tree/master/tensorflow/lite/c + $ ./bazel build -c opt //tensorflow/lite/c:tensorflowlite_c # see https://github.com/tensorflow/tensorflow/tree/master/tensorflow/lite/c ``` The script creates the shared library @@ -41,7 +41,7 @@ To create a Tensorflow Lite shared library: The Tensorflow filter plugin is disabled by default. You must build Fluent Bit with the Tensorflow plugin enabled. In addition, it requires access to Tensorflow Lite header files to compile. Therefore, you must pass the address of the Tensorflow source code on your machine to the [build script](https://github.com/fluent/fluent-bit#build-from-scratch): ```shell -cmake -DFLB_FILTER_TENSORFLOW=On -DTensorflow_DIR= ... +$ ./cmake -DFLB_FILTER_TENSORFLOW=On -DTensorflow_DIR= ... ``` ### Command line @@ -51,7 +51,7 @@ If the Tensorflow plugin initializes correctly, it reports successful creation o The command: ```shell -fluent-bit -i mqtt -p 'tag=mqtt.data' -F tensorflow -m '*' -p 'input_field=image' -p 'model_file=/home/user/model.tflite' -p +$ ./fluent-bit -i mqtt -p 'tag=mqtt.data' -F tensorflow -m '*' -p 'input_field=image' -p 'model_file=/home/user/model.tflite' -p ``` produces an output like: @@ -121,4 +121,4 @@ pipeline: ``` {% endtab %} -{% endtabs %} +{% endtabs %} \ No newline at end of file