Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

deb: add Ubuntu 24.04 (Noble Numbat) #639

Merged
merged 2 commits into from
Jun 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .github/workflows/apt-arm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ jobs:
- Debian GNU/Linux bookworm arm64
- Ubuntu Focal arm64
- Ubuntu Jammy arm64
- Ubuntu Noble arm64
include:
- label: Debian GNU/Linux bullseye arm64
rake-job: debian-bullseye
Expand All @@ -27,6 +28,10 @@ jobs:
rake-job: ubuntu-jammy
rake-options: LINTIAN=no
test-docker-image: arm64v8/ubuntu:jammy
- label: Ubuntu Noble arm64
rake-job: ubuntu-noble
rake-options: LINTIAN=no
test-docker-image: arm64v8/ubuntu:noble
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
18 changes: 18 additions & 0 deletions .github/workflows/apt.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ jobs:
- Debian GNU/Linux bookworm amd64
- Ubuntu Focal amd64
- Ubuntu Jammy amd64
- Ubuntu Noble amd64
include:
- label: Debian GNU/Linux bullseye amd64
rake-job: debian-bullseye
Expand All @@ -29,6 +30,9 @@ jobs:
- label: Ubuntu Jammy amd64
rake-job: ubuntu-jammy
test-docker-image: ubuntu:jammy
- label: Ubuntu Noble amd64
rake-job: ubuntu-noble
test-docker-image: ubuntu:noble
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down Expand Up @@ -118,6 +122,7 @@ jobs:
- Debian GNU/Linux bookworm amd64
- Ubuntu Focal amd64
- Ubuntu Jammy amd64
- Ubuntu Noble amd64
test-file:
- "update-from-v4.sh"
- "update-to-next-version-with-backward-compat-for-v4.sh"
Expand All @@ -138,13 +143,26 @@ jobs:
- label: Ubuntu Jammy amd64
rake-job: ubuntu-jammy
test-lxc-image: ubuntu:22.04
- label: Ubuntu Noble amd64
rake-job: ubuntu-noble
test-lxc-image: ubuntu:24.04
exclude:
- label: Debian GNU/Linux bookworm amd64
test-file: update-from-v4.sh
- label: Debian GNU/Linux bookworm amd64
test-file: update-to-next-version-with-backward-compat-for-v4.sh
- label: Debian GNU/Linux bookworm amd64
test-file: downgrade-to-v4.sh
- label: Ubuntu Noble amd64
test-file: update-from-v4.sh
- label: Ubuntu Noble amd64
test-file: update-to-next-version-with-backward-compat-for-v4.sh
- label: Ubuntu Noble amd64
test-file: downgrade-to-v4.sh
- label: Ubuntu Noble amd64
test-file: install-newly.sh v5
- label: Ubuntu Noble amd64
test-file: install-newly.sh lts
steps:
- uses: actions/checkout@master
- uses: actions/download-artifact@v4
Expand Down
3 changes: 2 additions & 1 deletion fluent-apt-source/Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,8 @@ class FluentdAptSourcePackageTask < PackageTask
"ubuntu-xenial",
"ubuntu-bionic",
"ubuntu-focal",
"ubuntu-jammy"
"ubuntu-jammy",
"ubuntu-noble"
]
end

Expand Down
17 changes: 17 additions & 0 deletions fluent-apt-source/apt/ubuntu-noble/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
FROM ubuntu:noble

RUN \
echo "debconf debconf/frontend select Noninteractive" | \
debconf-set-selections

ARG DEBUG

RUN \
quiet=$([ "${DEBUG}" = "yes" ] || echo "-qq") && \
apt update ${quiet} && \
apt install -y -V ${quiet} \
debhelper \
devscripts \
gnupg && \
apt clean && \
rm -rf /var/lib/apt/lists/*
3 changes: 2 additions & 1 deletion fluent-lts-apt-source/Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,8 @@ class FluentdAptLtsSourcePackageTask < PackageTask
"ubuntu-xenial",
"ubuntu-bionic",
"ubuntu-focal",
"ubuntu-jammy"
"ubuntu-jammy",
"ubuntu-noble"
]
end

Expand Down
17 changes: 17 additions & 0 deletions fluent-lts-apt-source/apt/ubuntu-noble/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
FROM ubuntu:noble

RUN \
echo "debconf debconf/frontend select Noninteractive" | \
debconf-set-selections

ARG DEBUG

RUN \
quiet=$([ "${DEBUG}" = "yes" ] || echo "-qq") && \
apt update ${quiet} && \
apt install -y -V ${quiet} \
debhelper \
devscripts \
gnupg && \
apt clean && \
rm -rf /var/lib/apt/lists/*
4 changes: 2 additions & 2 deletions fluent-lts-apt-source/convert-artifacts-layout.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ case $1 in
apt|deb)
REPOSITORY_TYPE=apt
REPOSITORY_PATH=$TD_AGENT_DIR/$REPOSITORY_TYPE/repositories
for d in bullseye bookworm focal jammy; do
for d in bullseye bookworm focal jammy noble; do
case $d in
bullseye|bookworm)
# e.g. mapping debian/pool/buster/main/t/td-agent/ => 5/debian/buster/pool/contrib/t/td-agent
Expand All @@ -24,7 +24,7 @@ case $1 in
find $REPOSITORY_PATH/debian/pool/$d -name 'fluent*-apt-source*.deb' -not -name '*dbgsym*' \
-exec cp {} $ARTIFACTS_DIR/lts/5/debian/$d/pool/contrib/f/fluent-lts-apt-source \;
;;
focal|jammy)
focal|jammy|noble)
# e.g. mapping ubuntu/pool/.../main/t/td-agent/ => 5/ubuntu/.../pool/contrib/t/td-agent
# mapping ubuntu/pool/.../main/f/fluent-package/ => 5/ubuntu/.../pool/contrib/f/fluent-package
mkdir -p $ARTIFACTS_DIR/lts/5/ubuntu/$d/pool/contrib/f/fluent-lts-apt-source
Expand Down
1 change: 1 addition & 0 deletions fluent-package/Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -1326,6 +1326,7 @@ EOS
"debian-bookworm",
"ubuntu-focal",
"ubuntu-jammy",
"ubuntu-noble",
]
end

Expand Down
2 changes: 1 addition & 1 deletion fluent-package/apt/commonvar.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ case ${code_name} in
mirror=http://archive.ubuntu.com/ubuntu/
java_jdk=openjdk-8-jre
;;
bionic|focal|hirsute|jammy)
bionic|focal|hirsute|jammy|noble)
distribution=ubuntu
channel=universe
mirror=http://archive.ubuntu.com/ubuntu/
Expand Down
10 changes: 6 additions & 4 deletions fluent-package/apt/install-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,12 @@ for conf_path in /etc/td-agent/td-agent.conf /etc/fluent/fluentd.conf; do
fi
done

if [ "${code_name}" == "bookworm" ]; then
echo "As bookworm is not published for v4, so package upgrade install check for ${code_name} is disabled"
exit 0
fi
case $code_name in
bookworm|noble)
echo "As ${code_name} is not published for v4, so package upgrade install check for ${code_name} is disabled"
exit 0
;;
esac
# TODO: Remove it when v5 repository was deployed
apt install -y curl
curl -O https://packages.treasuredata.com/4/${distribution}/${code_name}/pool/contrib/f/fluentd-apt-source/fluentd-apt-source_2020.8.25-1_all.deb
Expand Down
6 changes: 6 additions & 0 deletions fluent-package/apt/piuparts-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ apt install -V -y lsb-release

. $(dirname $0)/commonvar.sh

if [ -z "$(apt-cache show piuparts 2>/dev/null)" ]; then
# No piuparts package for noble and oracular. See https://packages.ubuntu.com/search?suite=noble&searchon=names&keywords=piuparts
echo "As ${code_name} does not support piuparts, so piuparts test for ${code_name} is disabled"
exit 0
fi

find ${repositories_dir}
DEBIAN_FRONTEND=noninteractive apt install -V -y piuparts mount gnupg curl eatmydata
gpg_command=gpg
Expand Down
13 changes: 10 additions & 3 deletions fluent-package/apt/pkgsize-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -59,13 +59,20 @@ case ${DISTRIBUTION} in
esac

set -e
PREVIOUS_SIZE=$(stat -c %s $BASE_NAME)
THRESHOLD_SIZE=`echo "$PREVIOUS_SIZE * 1.2" | bc -l | cut -d. -f1`

DEB=$(find $REPOSITORIES_DIR/${DISTRIBUTION}/pool/${CODE_NAME}/${CHANNEL}/f/fluent-package/fluent-package_*${ARCH}.deb | sort -n | tail -1)
CURRENT_SIZE=$(stat -c %s $DEB)
CURRENT_SIZE_MIB=$(echo "scale=2; ${CURRENT_SIZE} / 1024 / 1024" | bc)

if [ ! -e $BASE_NAME ]; then
echo "OLD: Not found (not supported)"
echo "NEW: ${CURRENT_SIZE_MIB} MiB (${CURRENT_SIZE}) : ${DEB}"
exit 0
fi

PREVIOUS_SIZE=$(stat -c %s $BASE_NAME)
PREVIOUS_SIZE_MIB=$(echo "scale=2; ${PREVIOUS_SIZE} / 1024 / 1024" | bc)
CURRENT_SIZE_MIB=$(echo "scale=2; ${CURRENT_SIZE} / 1024 / 1024" | bc)
THRESHOLD_SIZE=`echo "$PREVIOUS_SIZE * 1.2" | bc -l | cut -d. -f1`
echo "OLD: ${PREVIOUS_SIZE_MIB} MiB (${PREVIOUS_SIZE}) : ${BASE_NAME}"
echo "NEW: ${CURRENT_SIZE_MIB} MiB (${CURRENT_SIZE}) : ${DEB}"
if [ $CURRENT_SIZE -gt $THRESHOLD_SIZE ]; then
Expand Down
2 changes: 1 addition & 1 deletion fluent-package/apt/systemd-test/install-newly.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ test $(find /tmp/ -name gem_local_list.output | xargs cat) = "fluent-plugin-conc
sudo apt remove -y fluent-package

case ${code_name} in
bookworm)
bookworm|noble)
# no dead fluentd.service symlink in /etc/systemd/system
(! test -h /etc/systemd/system/fluentd.service)
test -h /etc/systemd/system/multi-user.target.wants/fluentd.service
Expand Down
18 changes: 18 additions & 0 deletions fluent-package/apt/ubuntu-noble-arm64/from
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.

arm64v8/ubuntu:noble
60 changes: 60 additions & 0 deletions fluent-package/apt/ubuntu-noble/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.

ARG FROM=ubuntu:noble
FROM ${FROM}

COPY qemu-* /usr/bin/

RUN \
echo "debconf debconf/frontend select Noninteractive" | \
debconf-set-selections

ARG DEBUG

RUN sed -i'' -e 's/^Types: deb/Types: deb deb-src/g' /etc/apt/sources.list.d/ubuntu.sources

RUN \
quiet=$([ "${DEBUG}" = "yes" ] || echo "-qq") && \
apt update ${quiet} && \
apt install -y -V ${quiet} \
build-essential \
debhelper \
devscripts \
ruby-dev \
ruby-bundler \
libedit2 \
libncurses5-dev \
libyaml-dev \
libffi-dev \
libreadline-dev \
git \
pkg-config \
libssl-dev \
libpq-dev \
tar \
lsb-release \
zlib1g-dev \
cmake && \
apt build-dep -y ruby && \
apt clean && \
# raise IPv4 priority
sed -i'' -e 's,#precedence ::ffff:0:0/96 100,precedence ::ffff:0:0/96 100,' /etc/gai.conf && \
# enable multiplatform feature
gem install --no-document --install-dir /usr/share/rubygems-integration/all bundler builder && \
rm -rf /var/lib/apt/lists/* && \
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
33 changes: 33 additions & 0 deletions fluent-package/apt/ubuntu-noble/qemu-dummy-static
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
#!/bin/sh
#
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.

# Do nothing. This exists only for not requiring qemu-aarch64-static copy.
# Recent Debian (buster or later) and Ubuntu (18.10 or later) on amd64 hosts or
# arm64 host don't require qemu-aarch64-static in Docker image. But old Debian
# and Ubuntu hosts on amd64 require qemu-aarch64-static in Docker image.
#
# We use "COPY qemu* /usr/bin/" in Dockerfile. If we don't put any "qemnu*",
# the "COPY" is failed. It means that we always require "qemu*" even if we
# use recent Debian/Ubuntu or arm64 host. If we have this dummy "qemu*" file,
# the "COPY" isn't failed. It means that we can copy "qemu*" only when we
# need.
#
# See also "script" in dev/tasks/linux-packages/azure.linux.arm64.yml.
# Azure Pipelines uses old Ubuntu (18.04).
# So we need to put "qemu-aarch64-static" into this directory.
4 changes: 2 additions & 2 deletions fluent-package/convert-artifacts-layout.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ case $1 in
apt|deb)
REPOSITORY_TYPE=apt
REPOSITORY_PATH=$FLUENT_PACKAGE_DIR/$REPOSITORY_TYPE/repositories
for d in bullseye bookworm focal jammy; do
for d in bullseye bookworm focal jammy noble; do
case $d in
bullseye|bookworm)
# e.g. mapping debian/pool/buster/main/t/td-agent/ => 5/debian/buster/pool/contrib/t/td-agent
Expand All @@ -49,7 +49,7 @@ case $1 in
-exec cp {} $ARTIFACTS_DIR/5/debian/$d/pool/contrib/f/fluent-apt-source \;
fi
;;
focal|jammy)
focal|jammy|noble)
# e.g. mapping ubuntu/pool/.../main/t/td-agent/ => 5/ubuntu/.../pool/contrib/t/td-agent
# mapping ubuntu/pool/.../main/f/fluent-package/ => 5/ubuntu/.../pool/contrib/f/fluent-package
mkdir -p $ARTIFACTS_DIR/5/ubuntu/$d/pool/contrib/f/fluent-package
Expand Down
6 changes: 3 additions & 3 deletions fluent-package/manage-fluent-repositories.sh
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ case $COMMAND in
$command
;;
dry-upload|upload)
TARGETS="amazon redhat windows macosx debian/bullseye debian/bookworm ubuntu/jammy ubuntu/focal"
TARGETS="amazon redhat windows macosx debian/bullseye debian/bookworm ubuntu/jammy ubuntu/focal ubuntu/noble"
DRYRUN_OPTION="--dryrun"
if [ $COMMAND = "upload" ]; then
DRYRUN_OPTION=""
Expand Down Expand Up @@ -137,7 +137,7 @@ EOF
echo "Ready to type signing passphrase? (process starts in 10 seconds, Ctrl+C to abort)"
sleep 10
export GPG_TTY=$(tty)
for d in bullseye bookworm focal jammy; do
for d in bullseye bookworm focal jammy noble; do
aptly -config="$aptly_conf" repo create -distribution=$d -component=contrib fluent-package5-$d
case $d in
bullseye|bookworm)
Expand All @@ -150,7 +150,7 @@ EOF
# Place generated files, package files themselves are already in there
tar cf - --exclude="td-agent_*.deb" --exclude="fluent-package_*.deb" -C "$aptly_rootdir/public" $d | tar xvf - -C $FLUENT_RELEASE_DIR/5/debian/
;;
focal|jammy)
focal|jammy|noble)
aptly -config="$aptly_conf" repo add fluent-package5-$d $FLUENT_RELEASE_DIR/5/ubuntu/$d/
aptly -config="$aptly_conf" snapshot create fluent-package5-$d-${FLUENT_PACKAGE_VERSION}-1 from repo fluent-package5-$d
# publish snapshot with prefix, InRelease looks like (e.g. focal):
Expand Down
2 changes: 1 addition & 1 deletion fluent-package/test-install-in-docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ case $ID in
debian|ubuntu)
CODENAME=$(cat /etc/os-release | grep VERSION_CODENAME | cut -d'=' -f2)
case $CODENAME in
bullseye|bookworm|focal|jammy)
bullseye|bookworm|focal|jammy|noble)
setup_apt_user
case $REPO in
exp/5)
Expand Down
Loading
Loading