Skip to content

Commit d6d52a3

Browse files
committed
Simplfy the package
Signed-off-by: Furkan Türkal <furkan.turkal@chainguard.dev>
1 parent fd334cf commit d6d52a3

File tree

1 file changed

+9
-62
lines changed

1 file changed

+9
-62
lines changed

aws-for-fluent-bit.yaml

Lines changed: 9 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -12,32 +12,13 @@ environment:
1212
- build-base
1313
- busybox
1414
- ca-certificates-bundle
15-
- glibc
16-
- glibc-dev
17-
- yaml-dev
18-
- gcc
19-
- cmake
20-
- make
21-
- wget
22-
- gnutar
23-
- git
24-
- openssl-dev
25-
- cyrus-sasl-dev
26-
- pkgconf
27-
- dpkg
28-
- systemd-dev
29-
- zlib-dev
30-
- flex
31-
- bison
32-
- autoconf
33-
- automake
3415
- go
16+
- fluent-bit
3517
- aws-flb-kinesis-compat
3618
- aws-flb-firehose-compat
3719
- aws-flb-cloudwatch-compat
3820

3921
vars:
40-
FLB_VERSION: "1.9.10"
4122
FLB_DOCKER_BRANCH: "1.8"
4223

4324
pipeline:
@@ -48,17 +29,13 @@ pipeline:
4829
tag: v${{package.version}}
4930

5031
- runs: |
51-
# GHSA-p782-xgp4-8hr8
52-
go get -u golang.org/x/sys@v0.0.0-20220412211240-33da011f77ad
53-
54-
go mod tidy
55-
56-
- runs: |
32+
mkdir -p "${{targets.destdir}}"/etc/ecs
5733
mkdir -p "${{targets.destdir}}"/etc/fluent-bit/etc
5834
mkdir -p "${{targets.destdir}}"/etc/fluent-bit/parsers
35+
cp -r ./ecs/* ${{targets.destdir}}/etc/ecs
5936
cp fluent-bit.conf "${{targets.destdir}}"/etc/fluent-bit/etc/
60-
cp AWS_FLB_CHERRY_PICKS "${{targets.destdir}}"/etc/fluent-bit/AWS_FLB_CHERRY_PICKS
6137
cp ./entrypoint.sh "${{targets.destdir}}"/etc/fluent-bit/entrypoint.sh
38+
cp AWS_FOR_FLUENT_BIT_VERSION "${{targets.destdir}}"/etc/fluent-bit/AWS_FOR_FLUENT_BIT_VERSION
6239
chmod +x "${{targets.destdir}}"/etc/fluent-bit/entrypoint.sh
6340
6441
- runs: |
@@ -82,38 +59,6 @@ pipeline:
8259
cp conf/parsers*.conf "${{targets.destdir}}"/etc/fluent-bit/etc
8360
cp conf/parsers*.conf "${{targets.destdir}}"/etc/fluent-bit/parsers/
8461
85-
- working-directory: fluent-bit
86-
pipeline:
87-
- uses: git-checkout
88-
with:
89-
repository: https://github.com/fluent/fluent-bit.git
90-
tag: v${{vars.FLB_VERSION}}
91-
expected-commit: 760956f50cdc7eef3047df20d2299202a8c68594
92-
- runs: |
93-
cd build
94-
95-
# We remove fortify when building the libraries
96-
export CFLAGS=${CFLAGS/-Wp,-D_FORTIFY_SOURCE=3/}
97-
export CPPFLAGS=${CPPFLAGS/-Wp,-D_FORTIFY_SOURCE=3/}
98-
export CXXFLAGS=${CXXFLAGS/-Wp,-D_FORTIFY_SOURCE=3/}
99-
100-
cmake -DFLB_RELEASE=On \
101-
-DCMAKE_INSTALL_PREFIX=/usr \
102-
-DCMAKE_INSTALL_LIBDIR=lib \
103-
-DFLB_TRACE=Off \
104-
-DFLB_JEMALLOC=On \
105-
-DFLB_TLS=On \
106-
-DFLB_SHARED_LIB=Off \
107-
-DFLB_EXAMPLES=Off \
108-
-DFLB_HTTP_SERVER=On \
109-
-DFLB_IN_SYSTEMD=On \
110-
-DFLB_OUT_KAFKA=On \
111-
-DFLB_ARROW=On \
112-
..
113-
make
114-
- runs: |
115-
make -C build DESTDIR="${{targets.destdir}}" install
116-
11762
- uses: strip
11863

11964
subpackages:
@@ -122,10 +67,12 @@ subpackages:
12267
pipeline:
12368
- runs: |
12469
# The AWS for Fluent Bit expects the .so libraries to be in /fluent-bit
70+
mkdir -p "${{targets.subpkgdir}}"/fluent-bit
12571
mkdir -p "${{targets.subpkgdir}}"/fluent-bit/bin
126-
mkdir -p "${{targets.subpkgdir}}"/fluent-bit/etc
127-
ln -sf /usr/bin/fluent-bit/bin/fluent-bit ${{targets.subpkgdir}}/fluent-bit/bin/fluent-bit
128-
ln -sf /usr/bin/fluent-bit/etc/fluent-bit.conf ${{targets.subpkgdir}}/fluent-bit/etc/fluent-bit.conf
72+
mkdir -p "${{targets.subpkgdir}}"/ecs
73+
ln -sf /etc/ecs ${{targets.subpkgdir}}/ecs
74+
ln -sf /etc/fluent-bit/ ${{targets.subpkgdir}}/fluent-bit/
75+
ln -sf /usr/bin/fluent-bit ${{targets.subpkgdir}}/fluent-bit/bin/fluent-bit
12976
- uses: strip
13077

13178
update:

0 commit comments

Comments
 (0)