Skip to content

Commit

Permalink
deb: add Ubuntu 24.04 (Noble Numbat)
Browse files Browse the repository at this point in the history
Signed-off-by: Kentaro Hayashi <[email protected]>
  • Loading branch information
kenhys committed Apr 2, 2024
1 parent c5133a4 commit f0562c7
Show file tree
Hide file tree
Showing 14 changed files with 174 additions and 11 deletions.
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
8 changes: 8 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 @@ -109,6 +113,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 @@ -129,6 +134,9 @@ 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
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/*
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
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.
2 changes: 1 addition & 1 deletion fluent-package/convert-artifacts-layout.sh
Original file line number Diff line number Diff line change
Expand Up @@ -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

0 comments on commit f0562c7

Please sign in to comment.