Skip to content

Commit

Permalink
Apply imds patch & switch to enumerated cherry-pick patches
Browse files Browse the repository at this point in the history
Signed-off-by: Matthew Fala <[email protected]>
  • Loading branch information
matthewfala committed Nov 16, 2021
1 parent 57eace2 commit 9c9c9a4
Show file tree
Hide file tree
Showing 5 changed files with 50 additions and 4 deletions.
12 changes: 12 additions & 0 deletions AWS_FLB_CHERRY_PICKS
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Fix return value from tls_net_read (https://github.com/fluent/fluent-bit/pull/4100)
https://github.com/krispraws/fluent-bit.git tls_net_read_fix 8d1cfeb5ba830b360fe6e1228190ed900842a3ea

# Downgrade mbedtls to 2.24.0 to fix the performance regression issue (https://github.com/fluent/fluent-bit/issues/4110)
https://github.com/zhonghui12/fluent-bit.git custom-1.8.7 30fc6305695623cbc95d51df07ae185dfec8bff2

# Support timeout on synchronous network calls (https://github.com/fluent/fluent-bit/pull/4184)
https://github.com/matthewfala/fluent-bit.git immutable-1.8-imds-r2-cherry-picks-r2 e44f8789d605f9ab19a212b4139bc7fec8d0b530
https://github.com/matthewfala/fluent-bit.git immutable-1.8-imds-r2-cherry-picks-r2 30b00b295db9e3ee646a0262a07ca53cf0025b58

# IMDS graceful fallback from IMDSv2 to IMDSv1 (https://github.com/aws/aws-for-fluent-bit/issues/259)
https://github.com/matthewfala/fluent-bit.git immutable-1.8-imds-r2-cherry-picks-r2 890915050ef2353a06c7d3e079e4d2ce821fc30b
2 changes: 1 addition & 1 deletion AWS_FOR_FLUENT_BIT_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.21.1
2.21.2
18 changes: 18 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,23 @@
# Changelog

### 2.21.2
This release includes:
* An Amazon Linux 2 Base
* Fluent Bit [1.8.9](https://fluentbit.io/announcements/v1.8.9/)
* Amazon CloudWatch Logs for Fluent Bit 1.6.4
* Amazon Kinesis Streams for Fluent Bit 1.8.0
* Amazon Kinesis Firehose for Fluent Bit 1.6.1

Compared to `2.21.1` this release adds:
* Bug - Remove corrupted unicode fragments on truncation [aws-for-fluent-bit:252](https://github.com/aws/aws-for-fluent-bit/issues/252)

Compared to `2.21.1` this release includes the following fixes for AWS customers that we are working on getting accepted upstream:
* Bug - Resolve IMDSv1 fallback error introduced in 2.21.0 [aws-for-fluent-bit:259](https://github.com/aws/aws-for-fluent-bit/issues/259)

Same as `2.21.1`, this release includes the following fixes for AWS customers that we are working on getting accepted upstream:
* Bug - Fix return value from `tls_net_read` [fluentbit:4098](https://github.com/fluent/fluent-bit/issues/4098)
* Bug - Downgrade `mbedtls` to 2.24.0 to fix the performance regression issue in `mbedtls` 2.26.0 [fluentbit:4110](https://github.com/fluent/fluent-bit/issues/4110)

### 2.21.1
This release includes:
* An Amazon Linux 2 Base
Expand Down
20 changes: 18 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,25 @@ ENV PATH ${PATH}:/home/.gimme/versions/go1.17.linux.arm64/bin:/home/.gimme/versi
RUN go version

WORKDIR /tmp/fluent-bit-$FLB_VERSION/
RUN git clone https://github.com/matthewfala/fluent-bit.git /tmp/fluent-bit-$FLB_VERSION/
RUN git clone https://github.com/fluent/fluent-bit.git /tmp/fluent-bit-$FLB_VERSION/
WORKDIR /tmp/fluent-bit-$FLB_VERSION/build/
RUN git fetch origin && git checkout 1_8_9_patch && git status
RUN git fetch --all --tags && git checkout tags/v${FLB_VERSION} -b v${FLB_VERSION} && git describe --tags

RUN git config --global user.email "[email protected]" \
&& git config --global user.name "FireLens Team"

# Apply Fluent Bit patches to base version
COPY AWS_FLB_CHERRY_PICKS \
/AWS_FLB_CHERRY_PICKS

RUN cat /AWS_FLB_CHERRY_PICKS | sed '/^#/d' \
| xargs -l bash -c 'git fetch $0 $1 && git cherry-pick $2'

RUN echo "Cherry Pick Patch Summary:"; \
git log --oneline \
-`cat /AWS_FLB_CHERRY_PICKS | sed '/^#/d' | sed '/^\s*$/d' | wc -l | awk '{ print $1 }'` \
| tac | awk '{ print "Commit",NR,"--",$0 }'; sleep 2

RUN cmake -DFLB_RELEASE=On \
-DFLB_TRACE=Off \
-DFLB_JEMALLOC=On \
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.plugins
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ ARG FIREHOSE_PLUGIN_CLONE_URL=https://github.com/aws/amazon-kinesis-firehose-for
ARG FIREHOSE_PLUGIN_TAG=v1.6.1
ARG FIREHOSE_PLUGIN_BRANCH=""
ARG CLOUDWATCH_PLUGIN_CLONE_URL=https://github.com/aws/amazon-cloudwatch-logs-for-fluent-bit.git
ARG CLOUDWATCH_PLUGIN_TAG=v1.6.3
ARG CLOUDWATCH_PLUGIN_TAG=v1.6.4
ARG CLOUDWATCH_PLUGIN_BRANCH=""

# Kinesis Streams
Expand Down

0 comments on commit 9c9c9a4

Please sign in to comment.