diff --git a/community_images/fluent-bit/bitnami/config/fluent-bit.config b/community_images/fluent-bit/bitnami/config/fluent-bit.config new file mode 100644 index 0000000000..5d3a9deddc --- /dev/null +++ b/community_images/fluent-bit/bitnami/config/fluent-bit.config @@ -0,0 +1,93 @@ +[SERVICE] + # Flush + # ===== + # set an interval of seconds before to flush records to a destination + flush 1 + + # Daemon + # ====== + # instruct Fluent Bit to run in foreground or background mode. + daemon Off + + # Log_Level + # ========= + # Set the verbosity level of the service, values can be: + # + # - error + # - warning + # - info + # - debug + # - trace + # + # by default 'info' is set, that means it includes 'error' and 'warning'. + log_level info + + # Parsers File + # ============ + # specify an optional 'Parsers' configuration file + #parsers_file parsers.conf + + # Plugins File + # ============ + # specify an optional 'Plugins' configuration file to load external plugins. + #plugins_file plugins.conf + + # HTTP Server + # =========== + # Enable/Disable the built-in HTTP Server for metrics + http_server Off + http_listen 0.0.0.0 + http_port 2020 + + # Storage + # ======= + # Fluent Bit can use memory and filesystem buffering based mechanisms + # + # - https://docs.fluentbit.io/manual/administration/buffering-and-storage + # + # storage metrics + # --------------- + # publish storage pipeline metrics in '/api/v1/storage'. The metrics are + # exported only if the 'http_server' option is enabled. + # + storage.metrics on + + # storage.path + # ------------ + # absolute file system path to store filesystem data buffers (chunks). + # + # storage.path /tmp/storage + + # storage.sync + # ------------ + # configure the synchronization mode used to store the data into the + # filesystem. It can take the values normal or full. + # + # storage.sync normal + + # storage.checksum + # ---------------- + # enable the data integrity check when writing and reading data from the + # filesystem. The storage layer uses the CRC32 algorithm. + # + # storage.checksum off + + # storage.backlog.mem_limit + # ------------------------- + # if storage.path is set, Fluent Bit will look for data chunks that were + # not delivered and are still in the storage layer, these are called + # backlog data. This option configure a hint of maximum value of memory + # to use when processing these records. + # + # storage.backlog.mem_limit 5M + +[INPUT] + name cpu + tag cpu.local + + # Read interval (sec) Default: 1 + interval_sec 1 + +[OUTPUT] + name stdout + match * diff --git a/community_images/fluent-bit/bitnami/dc_coverage.sh b/community_images/fluent-bit/bitnami/dc_coverage.sh index cfbbba3a97..6c0bb3f9fb 100644 --- a/community_images/fluent-bit/bitnami/dc_coverage.sh +++ b/community_images/fluent-bit/bitnami/dc_coverage.sh @@ -19,5 +19,7 @@ sleep 10 # log for debugging docker inspect "${CONTAINER_NAME}" +docker cp "${SCRIPTPATH}"/config/fluent-bit.config "${CONTAINER_NAME}":/tmp/fluent-bit.config +sleep 10 docker cp "${SCRIPTPATH}"/scripts/fluent-bit_coverage_script.sh "${CONTAINER_NAME}":/tmp/fluent-bit_coverage_script.sh docker exec -i "${CONTAINER_NAME}" bash -c "bash /tmp/fluent-bit_coverage_script.sh" \ No newline at end of file diff --git a/community_images/fluent-bit/bitnami/k8s_coverage.sh b/community_images/fluent-bit/bitnami/k8s_coverage.sh index 778db20055..694fffe740 100644 --- a/community_images/fluent-bit/bitnami/k8s_coverage.sh +++ b/community_images/fluent-bit/bitnami/k8s_coverage.sh @@ -17,7 +17,8 @@ RELEASE_NAME=$(jq -r '.release_name' < "$JSON_PARAMS") sleep 60 CONTAINER_NAME="${RELEASE_NAME}-0" - +kubectl cp "${SCRIPTPATH}"/config/fluent-bit.config "${CONTAINER_NAME}":/tmp/fluent-bit.config -n "${NAMESPACE}" +sleep 10 # copy over the script to the pod kubectl cp "${SCRIPTPATH}"/scripts/fluent-bit_coverage_script.sh "${CONTAINER_NAME}":/tmp/cvoverage_script.sh -n "${NAMESPACE}" diff --git a/community_images/fluent-bit/bitnami/scripts/fluent-bit_coverage_script.sh b/community_images/fluent-bit/bitnami/scripts/fluent-bit_coverage_script.sh index f7f73b0f06..0861b1ab84 100644 --- a/community_images/fluent-bit/bitnami/scripts/fluent-bit_coverage_script.sh +++ b/community_images/fluent-bit/bitnami/scripts/fluent-bit_coverage_script.sh @@ -4,7 +4,7 @@ set -e set -x # Start Fluent Bit with the specified configuration file -/opt/bitnami/fluent-bit/bin/fluent-bit -c /opt/bitnami/fluent-bit/conf/fluent-bit.conf & +/opt/bitnami/fluent-bit/bin/fluent-bit -c /tmp/fluent-bit.conf & # Add a delay to allow Fluent Bit to run (you can adjust this as needed) # Capture the PID of the last background process diff --git a/community_images/fluent-bit/ironbank/config/fluent-bit.config b/community_images/fluent-bit/ironbank/config/fluent-bit.config new file mode 100644 index 0000000000..5d3a9deddc --- /dev/null +++ b/community_images/fluent-bit/ironbank/config/fluent-bit.config @@ -0,0 +1,93 @@ +[SERVICE] + # Flush + # ===== + # set an interval of seconds before to flush records to a destination + flush 1 + + # Daemon + # ====== + # instruct Fluent Bit to run in foreground or background mode. + daemon Off + + # Log_Level + # ========= + # Set the verbosity level of the service, values can be: + # + # - error + # - warning + # - info + # - debug + # - trace + # + # by default 'info' is set, that means it includes 'error' and 'warning'. + log_level info + + # Parsers File + # ============ + # specify an optional 'Parsers' configuration file + #parsers_file parsers.conf + + # Plugins File + # ============ + # specify an optional 'Plugins' configuration file to load external plugins. + #plugins_file plugins.conf + + # HTTP Server + # =========== + # Enable/Disable the built-in HTTP Server for metrics + http_server Off + http_listen 0.0.0.0 + http_port 2020 + + # Storage + # ======= + # Fluent Bit can use memory and filesystem buffering based mechanisms + # + # - https://docs.fluentbit.io/manual/administration/buffering-and-storage + # + # storage metrics + # --------------- + # publish storage pipeline metrics in '/api/v1/storage'. The metrics are + # exported only if the 'http_server' option is enabled. + # + storage.metrics on + + # storage.path + # ------------ + # absolute file system path to store filesystem data buffers (chunks). + # + # storage.path /tmp/storage + + # storage.sync + # ------------ + # configure the synchronization mode used to store the data into the + # filesystem. It can take the values normal or full. + # + # storage.sync normal + + # storage.checksum + # ---------------- + # enable the data integrity check when writing and reading data from the + # filesystem. The storage layer uses the CRC32 algorithm. + # + # storage.checksum off + + # storage.backlog.mem_limit + # ------------------------- + # if storage.path is set, Fluent Bit will look for data chunks that were + # not delivered and are still in the storage layer, these are called + # backlog data. This option configure a hint of maximum value of memory + # to use when processing these records. + # + # storage.backlog.mem_limit 5M + +[INPUT] + name cpu + tag cpu.local + + # Read interval (sec) Default: 1 + interval_sec 1 + +[OUTPUT] + name stdout + match * diff --git a/community_images/fluent-bit/ironbank/config/fluent-bit.yml b/community_images/fluent-bit/ironbank/config/fluent-bit.yml deleted file mode 100644 index 510d809591..0000000000 --- a/community_images/fluent-bit/ironbank/config/fluent-bit.yml +++ /dev/null @@ -1,99 +0,0 @@ -service: - # Flush - # ===== - # set an interval of seconds before to flush records to a destination - flush: 1 - - # Daemon - # ====== - # instruct Fluent Bit to run in foreground or background mode. - daemon: Off - - # Log_Level - # ========= - # Set the verbosity level of the service, values can be: - # - # - error - # - warning - # - info - # - debug - # - trace - # - # by default 'info' is set, that means it includes 'error' and 'warning'. - log_level: info - - # Parsers File - # ============ - # specify an optional 'Parsers' configuration file - parsers_file: parsers.conf - - # Plugins File - # ============ - # specify an optional 'Plugins' configuration file to load external plugins. - plugins_file: plugins.conf - - # HTTP Server - # =========== - # Enable/Disable the built-in HTTP Server for metrics - http_server: Off - http_listen: 0.0.0.0 - http_port: 2020 - - # Storage - # ======= - # Fluent Bit can use memory and filesystem buffering based mechanisms - # - # - https://docs.fluentbit.io/manual/administration/buffering-and-storage - # - # storage metrics - # --------------- - # publish storage pipeline metrics in '/api/v1/storage'. The metrics are - # exported only if the 'http_server' option is enabled. - # - storage: - metrics: on - - # storage.path - # ------------ - # absolute file system path to store filesystem data buffers (chunks). - # - # storage.path /tmp/storage - path: /tmp/storage - - # storage.sync - # ------------ - # configure the synchronization mode used to store the data into the - # filesystem. It can take the values normal or full. - # - # storage.sync normal - sync: normal - - # storage.checksum - # ---------------- - # enable the data integrity check when writing and reading data from the - # filesystem. The storage layer uses the CRC32 algorithm. - # - # storage.checksum off - checksum: off - - # storage.backlog.mem_limit - # ------------------------- - # if storage.path is set, Fluent Bit will look for data chunks that were - # not delivered and are still in the storage layer, these are called - # backlog data. This option configure a hint of maximum value of memory - # to use when processing these records. - # - # storage.backlog.mem_limit 5M - backlog: - mem_limit: 5M - -input: - name: cpu - tag: cpu.local - - # Read interval (sec) Default: 1 - interval_sec: 1 - -output: - name: stdout - match: "*" \ No newline at end of file diff --git a/community_images/fluent-bit/ironbank/dc_coverage.sh b/community_images/fluent-bit/ironbank/dc_coverage.sh index b6296d5c31..b7255c0b95 100644 --- a/community_images/fluent-bit/ironbank/dc_coverage.sh +++ b/community_images/fluent-bit/ironbank/dc_coverage.sh @@ -23,4 +23,5 @@ sleep 10 # log for debugging docker inspect "${CONTAINER_NAME}" docker cp "${SCRIPTPATH}"/scripts/fluent-bit_coverage_script.sh "${CONTAINER_NAME}":/tmp/fluent-bit_coverage_script.sh +sleep 10 docker exec -i "${CONTAINER_NAME}" bash -c "bash /tmp/fluent-bit_coverage_script.sh" diff --git a/community_images/fluent-bit/ironbank/k8s_coverage.sh b/community_images/fluent-bit/ironbank/k8s_coverage.sh index ac54de47ad..144fffbd8b 100644 --- a/community_images/fluent-bit/ironbank/k8s_coverage.sh +++ b/community_images/fluent-bit/ironbank/k8s_coverage.sh @@ -22,6 +22,8 @@ echo "RELEASE_NAME: $RELEASE_NAME" sleep 60 CONTAINER_NAME="${RELEASE_NAME}-0" # copy over the script to the pod +kubectl cp "${SCRIPTPATH}"/config/fluent-bit.config "${CONTAINER_NAME}":/tmp/fluent-bit.config -n "${NAMESPACE}" +sleep 10 kubectl cp "${SCRIPTPATH}"/scripts/fluent-bit_coverage_script.sh "${CONTAINER_NAME}":/tmp/fluent-bit_cvoverage_script.sh -n "${NAMESPACE}" test_fluent-bit "${CONTAINER_NAME}" "${NAMESPACE}" "yes" \ No newline at end of file diff --git a/community_images/fluent-bit/ironbank/scripts/fluent-bit_coverage_script.sh b/community_images/fluent-bit/ironbank/scripts/fluent-bit_coverage_script.sh index a724f5ecf2..acad4eed2d 100644 --- a/community_images/fluent-bit/ironbank/scripts/fluent-bit_coverage_script.sh +++ b/community_images/fluent-bit/ironbank/scripts/fluent-bit_coverage_script.sh @@ -4,7 +4,7 @@ set -e set -x # Start Fluent Bit with the specified configuration file -/fluent-bit/bin/fluent-bit -c /fluent-bit/etc/fluent-bit.conf & +/fluent-bit/bin/fluent-bit -c /tmp/fluent-bit.conf & # Capture the PID of the last background process