Skip to content

Commit ecd1817

Browse files
committed
Add Ubuntu 26 to docker / crossbuild CI workflows
1 parent bf6cb76 commit ecd1817

3 files changed

Lines changed: 163 additions & 0 deletions

File tree

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
# Auto generated for ubuntu26
2+
# from scripts/crossbuild/m4/Dockerfile.deb.m4
3+
#
4+
# Rebuild this file with `make crossbuild.ubuntu26.regen`
5+
#
6+
ARG from=ubuntu:26.04
7+
FROM ${from} as build
8+
9+
ARG DEBIAN_FRONTEND=noninteractive
10+
11+
#
12+
# Install add-apt-repository
13+
#
14+
RUN apt-get update && \
15+
apt-get install -y software-properties-common gnupg2 procps && \
16+
apt-get clean && \
17+
rm -r /var/lib/apt/lists/*
18+
19+
20+
RUN apt-get update && \
21+
# Development utilities
22+
apt-get install -y devscripts equivs git quilt rsync fakeroot && \
23+
# Compilers
24+
apt-get install -y g++ llvm clang lldb && \
25+
# eapol_test dependencies
26+
apt-get install -y libnl-3-dev libnl-genl-3-dev
27+
28+
#
29+
# Documentation build dependecies
30+
#
31+
32+
# - doxygen & JSON.pm
33+
RUN apt-get install -y doxygen graphviz libjson-perl
34+
# - antora (npm needed)
35+
RUN curl -sL https://deb.nodesource.com/setup_20.x | bash -
36+
RUN apt-get install -y nodejs
37+
RUN npm i -g @antora/cli@3.1.7 @antora/site-generator-default@3.1.7
38+
# - pandoc
39+
WORKDIR /tmp
40+
RUN curl -OL $(curl -s https://api.github.com/repos/jgm/pandoc/releases/latest | grep "browser_download_url.*deb" | cut -d '"' -f 4)
41+
RUN apt-get install -y ./pandoc-*.deb
42+
# - asciidoctor
43+
RUN apt-get install -y ruby-dev
44+
RUN gem install asciidoctor
45+
46+
47+
48+
#
49+
# Setup a src dir in /usr/local
50+
#
51+
RUN mkdir -p /usr/local/src/repositories
52+
WORKDIR /usr/local/src/repositories
53+
54+
55+
#
56+
# Shallow clone the FreeRADIUS source
57+
#
58+
WORKDIR /usr/local/src/repositories
59+
ARG source=https://github.com/FreeRADIUS/freeradius-server.git
60+
RUN git clone --depth 1 --no-single-branch ${source}
61+
62+
#
63+
# Install build dependencies for all branches from v3 onwards
64+
#
65+
WORKDIR freeradius-server
66+
RUN for i in $(git for-each-ref --format='%(refname:short)' refs/remotes/origin 2>/dev/null | sed -e 's#origin/##' | egrep "^(v[3-9]*\.[0-9x]*\.x|master)$");\
67+
do \
68+
git checkout $i; \
69+
if [ -e ./debian/control.in ] ; then \
70+
touch -t 202001010000 debian/control; \
71+
debian/rules debian/control ; \
72+
fi ; \
73+
echo 'y' | \
74+
mk-build-deps -irt'apt-get -yV' debian/control ; \
75+
done
Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
# Auto generated for ubuntu26
2+
# from scripts/docker/m4/Dockerfile.deb.m4
3+
#
4+
# Rebuild this file with `make docker.ubuntu26.regen`
5+
#
6+
ARG from=ubuntu:26.04
7+
FROM ${from} AS build
8+
9+
ARG DEBIAN_FRONTEND=noninteractive
10+
11+
#
12+
# Install build tools
13+
#
14+
RUN apt-get update
15+
RUN apt-get install -y devscripts equivs git quilt gcc
16+
17+
#
18+
# Create build directory
19+
#
20+
RUN mkdir -p /usr/local/src/repositories/freeradius-server
21+
WORKDIR /usr/local/src/repositories/freeradius-server/
22+
23+
#
24+
# Copy the FreeRADIUS directory in
25+
#
26+
COPY . .
27+
28+
#
29+
# Clean up tree - we want to build from the latest commit, not from
30+
# any cruft left around on the local system
31+
#
32+
RUN git clean -fdxx \
33+
&& git reset --hard HEAD
34+
35+
ARG release
36+
RUN [ -z "$release" ] || git checkout ${release} ; \
37+
git status ; \
38+
git log -1 --oneline
39+
40+
#
41+
# Install build dependencies
42+
#
43+
RUN if [ -e ./debian/control.in ]; then \
44+
debian/rules debian/control; \
45+
fi; \
46+
echo 'y' | mk-build-deps -irt'apt-get -yV' debian/control
47+
48+
#
49+
# Build the server
50+
#
51+
# Work around fakeroot problems in Docker when building for different
52+
# platforms - doesn't matter as we run as root in the container anyway.
53+
#
54+
#RUN make -j$(nproc) deb
55+
RUN debian/rules debian/control \
56+
&& dpkg-buildpackage --jobs=auto -b -uc
57+
58+
#
59+
# Clean environment and run the server
60+
#
61+
FROM ${from}
62+
ARG DEBIAN_FRONTEND=noninteractive
63+
64+
COPY --from=build /usr/local/src/repositories/*.deb /tmp/
65+
66+
RUN ln -fs /usr/share/zoneinfo/Etc/UTC /etc/localtime
67+
68+
ARG freerad_uid=101
69+
ARG freerad_gid=101
70+
71+
RUN groupadd -g ${freerad_gid} -r freerad \
72+
&& useradd -u ${freerad_uid} -g freerad -r -M -d /etc/freeradius -s /usr/sbin/nologin freerad \
73+
&& apt-get update \
74+
&& apt-get install -y tzdata \
75+
&& apt-get install -y /tmp/*.deb \
76+
&& apt-get clean \
77+
&& rm -r /var/lib/apt/lists/* /tmp/*.deb \
78+
\
79+
&& ln -s /etc/freeradius /etc/raddb
80+
81+
WORKDIR /
82+
COPY scripts/docker/etc/docker-entrypoint.sh.deb docker-entrypoint.sh
83+
RUN chmod +x docker-entrypoint.sh
84+
85+
EXPOSE 1812/udp 1813/udp
86+
ENTRYPOINT ["/docker-entrypoint.sh"]
87+
CMD ["freeradius"]

scripts/docker/m4/Dockerfile.m4

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ ifelse(
2727
D_NAME, [ubuntu20], [p_SET([deb], [ubuntu], [20], [focal], [ubuntu:20.04])],
2828
D_NAME, [ubuntu22], [p_SET([deb], [ubuntu], [22], [jammy], [ubuntu:22.04])],
2929
D_NAME, [ubuntu24], [p_SET([deb], [ubuntu], [24], [noble], [ubuntu:24.04])],
30+
D_NAME, [ubuntu26], [p_SET([deb], [ubuntu], [26], [resolute], [ubuntu:26.04])],
3031
D_NAME, [centos7], [p_SET([rpm], [centos], [7], [7], [centos:7])],
3132
D_NAME, [centos8], [p_SET([rpm], [centos], [8], [8], [centos:8])],
3233
D_NAME, [rocky8], [p_SET([rpm], [rocky], [8], [8], [rockylinux/rockylinux:8])],

0 commit comments

Comments
 (0)