Skip to content
18 changes: 16 additions & 2 deletions packaging/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,18 @@ The [`distros`](./distros/) directory contains OCI container definitions used to

| Distro | Version / Code Name | Arch | Target Option |
|---------------|---------------------------|---------|--------------------------|
| AmazonLinux | 2 | x86_64 | amazonlinux/2 |
| AmazonLinux | 2 | arm64v8 | amazonlinux/2.arm64v8 |
| AlmaLinux | 10 | x86_64 | almalinux/10 |
| AlmaLinux | 10 | arm64v8 | almalinux/10.arm64v8 |
| AlmaLinux | 9 | x86_64 | almalinux/9 |
| AlmaLinux | 9 | arm64v8 | almalinux/9.arm64v8 |
| AlmaLinux | 8 | x86_64 | almalinux/8 |
| AlmaLinux | 8 | arm64v8 | almalinux/8.arm64v8 |
| AmazonLinux | 2023 | x86_64 | amazonlinux/2023 |
| AmazonLinux | 2023 | arm64v8 | amazonlinux/2023.arm64v8 |
| AmazonLinux | 2 | x86_64 | amazonlinux/2 |
| AmazonLinux | 2 | arm64v8 | amazonlinux/2.arm64v8 |
| CentOS Stream | 10 | x86_64 | centos/10 |
| CentOS Stream | 10 | arm64v8 | centos/10.arm64v8 |
| CentOS Stream | 9 | x86_64 | centos/9 |
| CentOS Stream | 9 | arm64v8 | centos/9.arm64v8 |
| CentOS | 8 | x86_64 | centos/8 |
Expand All @@ -41,6 +49,12 @@ The [`distros`](./distros/) directory contains OCI container definitions used to
| Raspbian | 12 / Bookworm | arm32v7 | raspbian/bookworm |
| Raspbian | 11 / Bullseye | arm32v7 | raspbian/bullseye |
| Raspbian | 10 / Buster | arm32v7 | raspbian/buster |
| Rocky Linux | 10 | x86_64 | rockylinux/10 |
| Rocky Linux | 10 | arm64v8 | rockylinux/10.arm64v8 |
| Rocky Linux | 9 | x86_64 | rockylinux/9 |
| Rocky Linux | 9 | arm64v8 | rockylinux/9.arm64v8 |
| Rocky Linux | 8 | x86_64 | rockylinux/8 |
| Rocky Linux | 8 | arm64v8 | rockylinux/8.arm64v8 |

These container images are intended to be built from the root of this repo to build the locally checked out/updated version of the source easily for any target.

Expand Down
24 changes: 24 additions & 0 deletions packaging/build-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,14 @@
"target": "centos/9.arm64v8",
"type": "rpm"
},
{
"target": "centos/10",
"type": "rpm"
},
{
"target": "centos/10.arm64v8",
"type": "rpm"
},
{
"target": "rockylinux/8",
"type": "rpm"
Expand All @@ -56,6 +64,14 @@
"target": "rockylinux/9.arm64v8",
"type": "rpm"
},
{
"target": "rockylinux/10",
"type": "rpm"
},
{
"target": "rockylinux/10.arm64v8",
"type": "rpm"
},
{
"target": "almalinux/8",
"type": "rpm"
Expand All @@ -72,6 +88,14 @@
"target": "almalinux/9.arm64v8",
"type": "rpm"
},
{
"target": "almalinux/10",
"type": "rpm"
},
{
"target": "almalinux/10.arm64v8",
"type": "rpm"
},
{
"target": "debian/bookworm",
"type": "deb"
Expand Down
46 changes: 40 additions & 6 deletions packaging/distros/almalinux/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ ARG BASE_BUILDER
# Use buildkit to skip unused base images: DOCKER_BUILDKIT=1

# Multiarch support
FROM multiarch/qemu-user-static:x86_64-aarch64 as multiarch-aarch64
FROM multiarch/qemu-user-static:x86_64-aarch64 AS multiarch-aarch64

# almalinux/8 base image
FROM almalinux:8 as almalinux-8-base
FROM almalinux:8 AS almalinux-8-base

# Add for the YAML development libraries
RUN sed -i 's/enabled=0/enabled=1/g' /etc/yum.repos.d/almalinux-powertools.repo
Expand All @@ -25,7 +25,7 @@ RUN yum -y update && \

# almalinux/8.arm64v8 base image
# hadolint ignore=DL3029
FROM --platform=arm64 almalinux:8 as almalinux-8.arm64v8-base
FROM --platform=arm64 almalinux:8 AS almalinux-8.arm64v8-base

COPY --from=multiarch-aarch64 /usr/bin/qemu-aarch64-static /usr/bin/qemu-aarch64-static

Expand All @@ -44,7 +44,7 @@ RUN yum -y update && \
ARG FLB_JEMALLOC_OPTIONS="--with-lg-page=16 --with-lg-quantum=3"
ENV FLB_JEMALLOC_OPTIONS=$FLB_JEMALLOC_OPTIONS

FROM almalinux:9 as almalinux-9-base
FROM almalinux:9 AS almalinux-9-base

# Add for the YAML development libraries
RUN sed -i 's/enabled=0/enabled=1/g' /etc/yum.repos.d/almalinux-crb.repo
Expand All @@ -59,7 +59,41 @@ RUN yum -y update && \

# almalinux/8.arm64v8 base image
# hadolint ignore=DL3029
FROM --platform=arm64 almalinux:9 as almalinux-9.arm64v8-base
FROM --platform=arm64 almalinux:9 AS almalinux-9.arm64v8-base

COPY --from=multiarch-aarch64 /usr/bin/qemu-aarch64-static /usr/bin/qemu-aarch64-static

# Add for the YAML development libraries
RUN sed -i 's/enabled=0/enabled=1/g' /etc/yum.repos.d/almalinux-crb.repo

# hadolint ignore=DL3033
RUN yum -y update && \
yum install -y --allowerasing rpm-build curl ca-certificates gcc gcc-c++ cmake make bash \
wget unzip systemd-devel wget flex bison \
postgresql-libs postgresql-devel postgresql-server postgresql \
cyrus-sasl-lib openssl openssl-libs openssl-devel libyaml-devel pkgconf-pkg-config && \
yum clean all

# Need larger page size
ARG FLB_JEMALLOC_OPTIONS="--with-lg-page=16 --with-lg-quantum=3"
ENV FLB_JEMALLOC_OPTIONS=$FLB_JEMALLOC_OPTIONS

FROM almalinux:10 AS almalinux-10-base

# Add for the YAML development libraries
RUN sed -i 's/enabled=0/enabled=1/g' /etc/yum.repos.d/almalinux-crb.repo

# hadolint ignore=DL3033
RUN yum -y update && \
yum install -y --allowerasing rpm-build curl ca-certificates gcc gcc-c++ cmake make bash \
wget unzip systemd-devel wget flex bison \
postgresql-libs postgresql-devel postgresql-server postgresql \
cyrus-sasl-lib openssl openssl-libs openssl-devel libyaml-devel pkgconf-pkg-config && \
yum clean all

# almalinux/8.arm64v8 base image
# hadolint ignore=DL3029
FROM --platform=arm64 almalinux:10 AS almalinux-10.arm64v8-base

COPY --from=multiarch-aarch64 /usr/bin/qemu-aarch64-static /usr/bin/qemu-aarch64-static

Expand All @@ -80,7 +114,7 @@ ENV FLB_JEMALLOC_OPTIONS=$FLB_JEMALLOC_OPTIONS

# Common build for all distributions now
# hadolint ignore=DL3006
FROM $BASE_BUILDER as builder
FROM $BASE_BUILDER AS builder

ARG FLB_NIGHTLY_BUILD
ENV FLB_NIGHTLY_BUILD=$FLB_NIGHTLY_BUILD
Expand Down
63 changes: 63 additions & 0 deletions packaging/distros/centos/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,69 @@
ARG FLB_JEMALLOC_OPTIONS="--with-lg-page=16 --with-lg-quantum=3"
ENV FLB_JEMALLOC_OPTIONS=$FLB_JEMALLOC_OPTIONS

FROM quay.io/centos/centos:stream10 AS centos-10-base

ENV CMAKE_HOME="/opt/cmake"
ARG CMAKE_VERSION="3.31.6"
ARG CMAKE_URL="https://github.com/Kitware/CMake/releases/download"

# Add for the YAML development libraries
# hadolint ignore=DL3033,DL3041
RUN dnf -y install 'dnf-command(config-manager)' && dnf -y config-manager --set-enabled crb && \

Check warning on line 236 in packaging/distros/centos/Dockerfile

View workflow job for this annotation

GitHub Actions / PR - Hadolint

[hadolint] reported by reviewdog 🐶 Set the SHELL option -o pipefail before RUN with a pipe in it. If you are using /bin/sh in an alpine image or if your shell is symlinked to busybox then consider explicitly setting your SHELL to /bin/ash, or disable this check Raw Output: message:"Set the SHELL option -o pipefail before RUN with a pipe in it. If you are using /bin/sh in an alpine image or if your shell is symlinked to busybox then consider explicitly setting your SHELL to /bin/ash, or disable this check" location:{path:"packaging/distros/centos/Dockerfile" range:{start:{line:236 column:1}}} severity:WARNING source:{name:"hadolint" url:"https://github.com/hadolint/hadolint"} code:{value:"DL4006" url:"https://github.com/hadolint/hadolint/wiki/DL4006"}
dnf -y install rpm-build ca-certificates gcc gcc-c++ make bash \
wget unzip systemd-devel wget flex bison \
postgresql-libs postgresql-devel postgresql-server postgresql \
cyrus-sasl-lib cyrus-sasl-devel openssl openssl-libs openssl-devel libcurl-devel pkgconf-pkg-config \
libyaml-devel zlib-devel \
tar gzip && \
dnf clean all && \
mkdir -p "${CMAKE_HOME}" && \
cmake_download_url="${CMAKE_URL}/v${CMAKE_VERSION}/cmake-${CMAKE_VERSION}-linux-$(uname -m).tar.gz" && \
echo "Downloading CMake ${CMAKE_VERSION}: ${cmake_download_url} -> ${CMAKE_HOME}" && \
curl -jksSL "${cmake_download_url}" | tar -xzf - -C "${CMAKE_HOME}" --strip-components 1

ENV PATH="${CMAKE_HOME}/bin:${PATH}"

ARG FLB_OUT_PGSQL=On
ENV FLB_OUT_PGSQL=$FLB_OUT_PGSQL

# hadolint ignore=DL3029
FROM --platform=arm64 quay.io/centos/centos:stream10 AS centos-10.arm64v8-base

COPY --from=multiarch-aarch64 /usr/bin/qemu-aarch64-static /usr/bin/qemu-aarch64-static

ENV CMAKE_HOME="/opt/cmake"
ARG CMAKE_VERSION="3.31.6"
ARG CMAKE_URL="https://github.com/Kitware/CMake/releases/download"

# Add for the YAML development libraries
# hadolint ignore=DL3033,DL3041
RUN dnf -y install 'dnf-command(config-manager)' && dnf -y config-manager --set-enabled crb && \

Check warning on line 265 in packaging/distros/centos/Dockerfile

View workflow job for this annotation

GitHub Actions / PR - Hadolint

[hadolint] reported by reviewdog 🐶 Set the SHELL option -o pipefail before RUN with a pipe in it. If you are using /bin/sh in an alpine image or if your shell is symlinked to busybox then consider explicitly setting your SHELL to /bin/ash, or disable this check Raw Output: message:"Set the SHELL option -o pipefail before RUN with a pipe in it. If you are using /bin/sh in an alpine image or if your shell is symlinked to busybox then consider explicitly setting your SHELL to /bin/ash, or disable this check" location:{path:"packaging/distros/centos/Dockerfile" range:{start:{line:265 column:1}}} severity:WARNING source:{name:"hadolint" url:"https://github.com/hadolint/hadolint"} code:{value:"DL4006" url:"https://github.com/hadolint/hadolint/wiki/DL4006"}
dnf -y install rpm-build ca-certificates gcc gcc-c++ make bash \
wget unzip systemd-devel wget flex bison \
postgresql-libs postgresql-devel postgresql-server postgresql \
cyrus-sasl-lib cyrus-sasl-devel openssl openssl-libs openssl-devel libcurl-devel pkgconf-pkg-config \
libyaml-devel zlib-devel \
tar gzip && \
dnf clean all && \
mkdir -p "${CMAKE_HOME}" && \
cmake_download_url="${CMAKE_URL}/v${CMAKE_VERSION}/cmake-${CMAKE_VERSION}-linux-$(uname -m).tar.gz" && \
echo "Downloading CMake ${CMAKE_VERSION}: ${cmake_download_url} -> ${CMAKE_HOME}" && \
curl -jksSL "${cmake_download_url}" | tar -xzf - -C "${CMAKE_HOME}" --strip-components 1

ENV PATH="${CMAKE_HOME}/bin:${PATH}"

ARG FLB_OUT_PGSQL=On
ENV FLB_OUT_PGSQL=$FLB_OUT_PGSQL
ARG FLB_UNICODE_ENCODER=On
ENV FLB_UNICODE_ENCODER=$FLB_UNICODE_ENCODER
ARG FLB_KAFKA=On
ENV FLB_KAFKA=$FLB_KAFKA

# Need larger page size
ARG FLB_JEMALLOC_OPTIONS="--with-lg-page=16 --with-lg-quantum=3"
ENV FLB_JEMALLOC_OPTIONS=$FLB_JEMALLOC_OPTIONS

# Common build for all distributions now
# hadolint ignore=DL3006
FROM $BASE_BUILDER AS builder
Expand Down
48 changes: 41 additions & 7 deletions packaging/distros/rockylinux/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ ARG BASE_BUILDER
# Use buildkit to skip unused base images: DOCKER_BUILDKIT=1

# Multiarch support
FROM multiarch/qemu-user-static:x86_64-aarch64 as multiarch-aarch64
FROM multiarch/qemu-user-static:x86_64-aarch64 AS multiarch-aarch64

# rockylinux/8 base image
FROM rockylinux:8 as rockylinux-8-base
FROM rockylinux/rockylinux:8 AS rockylinux-8-base

# Add for the YAML development libraries
RUN sed -i 's/enabled=0/enabled=1/g' /etc/yum.repos.d/Rocky-PowerTools.repo
Expand All @@ -25,7 +25,7 @@ RUN yum -y update && \

# rockylinux/8.arm64v8 base image
# hadolint ignore=DL3029
FROM --platform=arm64 rockylinux:8 as rockylinux-8.arm64v8-base
FROM --platform=arm64 rockylinux/rockylinux:8 AS rockylinux-8.arm64v8-base

COPY --from=multiarch-aarch64 /usr/bin/qemu-aarch64-static /usr/bin/qemu-aarch64-static

Expand All @@ -44,7 +44,7 @@ RUN yum -y update && \
ARG FLB_JEMALLOC_OPTIONS="--with-lg-page=16 --with-lg-quantum=3"
ENV FLB_JEMALLOC_OPTIONS=$FLB_JEMALLOC_OPTIONS

FROM rockylinux:9 as rockylinux-9-base
FROM rockylinux/rockylinux:9 AS rockylinux-9-base

# Add for the YAML development libraries
RUN sed -i 's/enabled=0/enabled=1/g' /etc/yum.repos.d/rocky-devel.repo
Expand All @@ -57,9 +57,43 @@ RUN yum -y update && \
cyrus-sasl-lib openssl openssl-libs openssl-devel libyaml-devel pkgconf-pkg-config && \
yum clean all

# rockylinux/8.arm64v8 base image
# rockylinux/9.arm64v8 base image
# hadolint ignore=DL3029
FROM --platform=arm64 rockylinux/rockylinux:9 AS rockylinux-9.arm64v8-base

COPY --from=multiarch-aarch64 /usr/bin/qemu-aarch64-static /usr/bin/qemu-aarch64-static

# Add for the YAML development libraries
RUN sed -i 's/enabled=0/enabled=1/g' /etc/yum.repos.d/rocky-devel.repo

# hadolint ignore=DL3033
RUN yum -y update && \
yum install -y --allowerasing rpm-build curl ca-certificates gcc gcc-c++ cmake make bash \
wget unzip systemd-devel wget flex bison \
postgresql-libs postgresql-devel postgresql-server postgresql \
cyrus-sasl-lib openssl openssl-libs openssl-devel libyaml-devel pkgconf-pkg-config && \
yum clean all

# Need larger page size
ARG FLB_JEMALLOC_OPTIONS="--with-lg-page=16 --with-lg-quantum=3"
ENV FLB_JEMALLOC_OPTIONS=$FLB_JEMALLOC_OPTIONS

FROM rockylinux/rockylinux:10 AS rockylinux-10-base

# Add for the YAML development libraries
RUN sed -i 's/enabled=0/enabled=1/g' /etc/yum.repos.d/rocky-devel.repo

# hadolint ignore=DL3033
RUN yum -y update && \
yum install -y --allowerasing rpm-build curl ca-certificates gcc gcc-c++ cmake make bash \
wget unzip systemd-devel wget flex bison \
postgresql-libs postgresql-devel postgresql-server postgresql \
cyrus-sasl-lib openssl openssl-libs openssl-devel libyaml-devel pkgconf-pkg-config && \
yum clean all

# rockylinux/10.arm64v8 base image
# hadolint ignore=DL3029
FROM --platform=arm64 rockylinux:9 as rockylinux-9.arm64v8-base
FROM --platform=arm64 rockylinux/rockylinux:10 AS rockylinux-10.arm64v8-base

COPY --from=multiarch-aarch64 /usr/bin/qemu-aarch64-static /usr/bin/qemu-aarch64-static

Expand All @@ -80,7 +114,7 @@ ENV FLB_JEMALLOC_OPTIONS=$FLB_JEMALLOC_OPTIONS

# Common build for all distributions now
# hadolint ignore=DL3006
FROM $BASE_BUILDER as builder
FROM $BASE_BUILDER AS builder

ARG FLB_NIGHTLY_BUILD
ENV FLB_NIGHTLY_BUILD=$FLB_NIGHTLY_BUILD
Expand Down
18 changes: 14 additions & 4 deletions packaging/test-release-packages.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,18 +37,28 @@ function check_version() {
fi
}

APT_TARGETS=("ubuntu:22.04"
APT_TARGETS=(
"ubuntu:22.04"
"ubuntu:24.04"
"debian:10"
"debian:11")
"debian:11"
"debian:12"
"debian:13"
)

YUM_TARGETS=("centos:7"
YUM_TARGETS=(
"centos:7"
"almalinux:8"
"almalinux:9"
"almalinux:10"
"rockylinux:8"
"rockylinux:9"
"rockylinux:10"
"quay.io/centos/centos:stream9"
"quay.io/centos/centos:stream10"
"amazonlinux:2"
"amazonlinux:2023")
"amazonlinux:2023"
)

for IMAGE in "${YUM_TARGETS[@]}"
do
Expand Down
14 changes: 13 additions & 1 deletion packaging/update-repos.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,19 @@ fi
# AWS_S3_BUCKET_STAGING=fluentbit-staging
export AWS_REGION=${AWS_REGION:-us-east-1}

RPM_REPO_PATHS=("amazonlinux/2" "amazonlinux/2023" "centos/7" "centos/8" "centos/9" "rockylinux/8" "rockylinux/9" "almalinux/8" "almalinux/9" )
RPM_REPO_PATHS=( "amazonlinux/2"
"amazonlinux/2023"
"centos/7"
"centos/8"
"centos/9"
"centos/10"
"rockylinux/8"
"rockylinux/9"
"rockylinux/10"
"almalinux/8"
"almalinux/9"
"almalinux/10"
)

if [[ "${AWS_SYNC:-false}" != "false" ]]; then
aws s3 sync s3://"${AWS_S3_BUCKET_RELEASE:?}" "${BASE_PATH:?}"
Expand Down
Loading