Skip to content

Commit ab71241

Browse files
authored
Merge pull request #79 from freeswitch/arm64
[GHA] Add `arm64v8` build target.
2 parents 05a9646 + 184e99c commit ab71241

File tree

4 files changed

+206
-0
lines changed

4 files changed

+206
-0
lines changed

Diff for: .github/docker/debian/bookworm/arm64v8/Dockerfile

+68
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
ARG BUILDER_IMAGE=arm64v8/debian:bookworm
2+
ARG MAINTAINER="Andrey Volk <[email protected]>"
3+
4+
FROM ${BUILDER_IMAGE} AS builder
5+
6+
ARG BUILD_NUMBER=42
7+
ARG GIT_SHA=0000000000
8+
9+
MAINTAINER ${MAINTAINER}
10+
11+
SHELL ["/bin/bash", "-c"]
12+
13+
RUN apt-get -q update && \
14+
DEBIAN_FRONTEND=noninteractive apt-get -yq install \
15+
apt-transport-https \
16+
build-essential \
17+
ca-certificates \
18+
cmake \
19+
curl \
20+
debhelper \
21+
devscripts \
22+
dh-autoreconf \
23+
docbook-xsl \
24+
dos2unix \
25+
doxygen \
26+
git \
27+
graphviz \
28+
libglib2.0-dev \
29+
libssl-dev \
30+
lsb-release \
31+
pkg-config \
32+
wget
33+
34+
RUN update-ca-certificates --fresh
35+
36+
ENV DATA_DIR=/data
37+
WORKDIR ${DATA_DIR}
38+
39+
COPY . ${DATA_DIR}
40+
RUN git reset --hard HEAD && git clean -xfd
41+
42+
RUN echo "export CODENAME=$(lsb_release -sc | tr -d '\n')" | tee ~/.env && \
43+
chmod +x ~/.env
44+
45+
RUN git config --global --add safe.directory '*'
46+
47+
# Bootstrap and Build
48+
RUN echo "export VERSION=$(dpkg-parsechangelog --show-field Version | cut -f1 -d'-')" | tee -a ~/.env
49+
RUN . ~/.env && dch \
50+
--controlmaint \
51+
--distribution "${CODENAME}" \
52+
--force-bad-version \
53+
--force-distribution \
54+
--newversion "${VERSION}-${BUILD_NUMBER}-${GIT_SHA}~${CODENAME}" \
55+
"Nightly build, ${GIT_SHA}"
56+
57+
RUN apt-get -q update && \
58+
mk-build-deps --install --remove debian/control --tool "apt-get -y --no-install-recommends" && \
59+
apt-get -y -f install
60+
61+
ENV DEB_BUILD_OPTIONS="parallel=1"
62+
RUN . ~/.env && dch -b -M -v "${VERSION}-${BUILD_NUMBER}-${GIT_SHA}~${CODENAME}" \
63+
--force-distribution -D "${CODENAME}" "Nightly build, ${GIT_SHA}"
64+
RUN debuild -b -us -uc && mkdir OUT && mv -v ../*.deb OUT/.
65+
66+
# Artifacts image (mandatory part, the resulting image must have a single filesystem layer)
67+
FROM scratch
68+
COPY --from=builder /data/OUT/ /

Diff for: .github/docker/debian/bullseye/arm64v8/Dockerfile

+68
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
ARG BUILDER_IMAGE=arm64v8/debian:bullseye
2+
ARG MAINTAINER="Andrey Volk <[email protected]>"
3+
4+
FROM ${BUILDER_IMAGE} AS builder
5+
6+
ARG BUILD_NUMBER=42
7+
ARG GIT_SHA=0000000000
8+
9+
MAINTAINER ${MAINTAINER}
10+
11+
SHELL ["/bin/bash", "-c"]
12+
13+
RUN apt-get -q update && \
14+
DEBIAN_FRONTEND=noninteractive apt-get -yq install \
15+
apt-transport-https \
16+
build-essential \
17+
ca-certificates \
18+
cmake \
19+
curl \
20+
debhelper \
21+
devscripts \
22+
dh-autoreconf \
23+
docbook-xsl \
24+
dos2unix \
25+
doxygen \
26+
git \
27+
graphviz \
28+
libglib2.0-dev \
29+
libssl-dev \
30+
lsb-release \
31+
pkg-config \
32+
wget
33+
34+
RUN update-ca-certificates --fresh
35+
36+
ENV DATA_DIR=/data
37+
WORKDIR ${DATA_DIR}
38+
39+
COPY . ${DATA_DIR}
40+
RUN git reset --hard HEAD && git clean -xfd
41+
42+
RUN echo "export CODENAME=$(lsb_release -sc | tr -d '\n')" | tee ~/.env && \
43+
chmod +x ~/.env
44+
45+
RUN git config --global --add safe.directory '*'
46+
47+
# Bootstrap and Build
48+
RUN echo "export VERSION=$(dpkg-parsechangelog --show-field Version | cut -f1 -d'-')" | tee -a ~/.env
49+
RUN . ~/.env && dch \
50+
--controlmaint \
51+
--distribution "${CODENAME}" \
52+
--force-bad-version \
53+
--force-distribution \
54+
--newversion "${VERSION}-${BUILD_NUMBER}-${GIT_SHA}~${CODENAME}" \
55+
"Nightly build, ${GIT_SHA}"
56+
57+
RUN apt-get -q update && \
58+
mk-build-deps --install --remove debian/control --tool "apt-get -y --no-install-recommends" && \
59+
apt-get -y -f install
60+
61+
ENV DEB_BUILD_OPTIONS="parallel=1"
62+
RUN . ~/.env && dch -b -M -v "${VERSION}-${BUILD_NUMBER}-${GIT_SHA}~${CODENAME}" \
63+
--force-distribution -D "${CODENAME}" "Nightly build, ${GIT_SHA}"
64+
RUN debuild -b -us -uc && mkdir OUT && mv -v ../*.deb OUT/.
65+
66+
# Artifacts image (mandatory part, the resulting image must have a single filesystem layer)
67+
FROM scratch
68+
COPY --from=builder /data/OUT/ /

Diff for: .github/docker/debian/buster/arm64v8/Dockerfile

+68
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
ARG BUILDER_IMAGE=arm64v8/debian:buster
2+
ARG MAINTAINER="Andrey Volk <[email protected]>"
3+
4+
FROM ${BUILDER_IMAGE} AS builder
5+
6+
ARG BUILD_NUMBER=42
7+
ARG GIT_SHA=0000000000
8+
9+
MAINTAINER ${MAINTAINER}
10+
11+
SHELL ["/bin/bash", "-c"]
12+
13+
RUN apt-get -q update && \
14+
DEBIAN_FRONTEND=noninteractive apt-get -yq install \
15+
apt-transport-https \
16+
build-essential \
17+
ca-certificates \
18+
cmake \
19+
curl \
20+
debhelper \
21+
devscripts \
22+
dh-autoreconf \
23+
docbook-xsl \
24+
dos2unix \
25+
doxygen \
26+
git \
27+
graphviz \
28+
libglib2.0-dev \
29+
libssl-dev \
30+
lsb-release \
31+
pkg-config \
32+
wget
33+
34+
RUN update-ca-certificates --fresh
35+
36+
ENV DATA_DIR=/data
37+
WORKDIR ${DATA_DIR}
38+
39+
COPY . ${DATA_DIR}
40+
RUN git reset --hard HEAD && git clean -xfd
41+
42+
RUN echo "export CODENAME=$(lsb_release -sc | tr -d '\n')" | tee ~/.env && \
43+
chmod +x ~/.env
44+
45+
RUN git config --global --add safe.directory '*'
46+
47+
# Bootstrap and Build
48+
RUN echo "export VERSION=$(dpkg-parsechangelog --show-field Version | cut -f1 -d'-')" | tee -a ~/.env
49+
RUN . ~/.env && dch \
50+
--controlmaint \
51+
--distribution "${CODENAME}" \
52+
--force-bad-version \
53+
--force-distribution \
54+
--newversion "${VERSION}-${BUILD_NUMBER}-${GIT_SHA}~${CODENAME}" \
55+
"Nightly build, ${GIT_SHA}"
56+
57+
RUN apt-get -q update && \
58+
mk-build-deps --install --remove debian/control --tool "apt-get -y --no-install-recommends" && \
59+
apt-get -y -f install
60+
61+
ENV DEB_BUILD_OPTIONS="parallel=1"
62+
RUN . ~/.env && dch -b -M -v "${VERSION}-${BUILD_NUMBER}-${GIT_SHA}~${CODENAME}" \
63+
--force-distribution -D "${CODENAME}" "Nightly build, ${GIT_SHA}"
64+
RUN debuild -b -us -uc && mkdir OUT && mv -v ../*.deb OUT/.
65+
66+
# Artifacts image (mandatory part, the resulting image must have a single filesystem layer)
67+
FROM scratch
68+
COPY --from=builder /data/OUT/ /

Diff for: .github/workflows/cicd.yml

+2
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ jobs:
3434
runner: ubuntu-latest
3535
- name: arm32v7
3636
runner: ubuntu-latest
37+
- name: arm64v8
38+
runner: ubuntu-latest
3739
# exclude:
3840
# - version: bookworm
3941
# platform:

0 commit comments

Comments
 (0)