File tree Expand file tree Collapse file tree 14 files changed +151
-92
lines changed
actions/openziti-tunnel-build-action Expand file tree Collapse file tree 14 files changed +151
-92
lines changed Original file line number Diff line number Diff line change 1- name : ' OpenZiti Tunneler Build Action'
2- description : ' Builds ziti-edge-tunnel binary and install package for Linux '
3- author : ' NetFoundry'
1+ name : OpenZiti Tunneler Build Action
2+ description : Builds ziti-edge-tunnel binary and Linux package
3+ author : NetFoundry
44inputs :
55 arch :
6- description : ' The cmake preset used by entrypoint.sh when running cmake'
6+ description : The cmake preset used by entrypoint.sh when running cmake
77 required : false
88 config :
9- description : ' The cmake build configuration used by entrypoint.sh when running cmake'
9+ description : The cmake build configuration used by entrypoint.sh when running cmake
1010 required : false
1111runs :
12- using : ' docker'
13- image : ' Dockerfile'
12+ using : docker
13+ image : Dockerfile
1414 args :
1515 - ${{ inputs.arch }}
1616 - ${{ inputs.config }}
Original file line number Diff line number Diff line change 11# use ziti-builder:v1 (Ubuntu Bionic 18.04 LTS) for older glibc (2.27)
22FROM openziti/ziti-builder:v1
33
4- COPY ./entrypoint.sh /root/
5- RUN chmod +x /root/entrypoint.sh
4+ COPY --chmod=0755 ./entrypoint.sh /root/
65ENTRYPOINT [ "/root/entrypoint.sh" ]
Original file line number Diff line number Diff line change 4444for SAFE in \
4545 /github/workspace \
4646 /__w/ziti-tunnel-sdk-c/ziti-tunnel-sdk-c \
47- /mnt ; do
48- git config --global --add safe.directory ${SAFE}
47+ /mnt \
48+ /usr/local/vcpkg
49+ do
50+ git config --global --add safe.directory ${SAFE}
4951done
5052
53+ mkdir -p /github/workspace/vcpkg_cache
54+
5155(
52- cd " ${VCPKG_ROOT} "
53- git checkout master
54- git pull
55- ./bootstrap-vcpkg.sh -disableMetrics
56+ cd " ${VCPKG_ROOT} "
57+ git checkout master
58+ git pull
59+ ./bootstrap-vcpkg.sh -disableMetrics
5660)
5761
5862cmake -E make_directory ./build
5963cmake \
60- --preset " ${cmake_preset} " \
61- -DCMAKE_BUILD_TYPE=" ${cmake_config} " \
62- -DVCPKG_OVERLAY_PORTS=./.github/actions/openziti-tunnel-build-action/gh-release/vcpkg-overlays \
63- -S . \
64- -B ./build
64+ --preset " ${cmake_preset} " \
65+ -DCMAKE_BUILD_TYPE=" ${cmake_config} " \
66+ -DVCPKG_OVERLAY_PORTS=./.github/actions/openziti-tunnel-build-action/gh-release/vcpkg-overlays \
67+ -S . \
68+ -B ./build
6569cmake \
66- --build ./build \
67- --config " ${cmake_config} " \
68- --target bundle \
69- --verbose
70+ --build ./build \
71+ --config " ${cmake_config} " \
72+ --target bundle \
73+ --verbose
Original file line number Diff line number Diff line change @@ -41,10 +41,11 @@ RUN curl -sSfL https://cmake.org/files/v${CMAKE_VERSION%.*}/cmake-${CMAKE_VERSIO
4141ENV VCPKG_ROOT=/usr/local/vcpkg
4242# this must be set on arm. see https://learn.microsoft.com/en-us/vcpkg/users/config-environment#vcpkg_force_system_binaries
4343ENV VCPKG_FORCE_SYSTEM_BINARIES=yes
44+ ENV VCPKG_BINARY_SOURCES="clear;files,/github/workspace/vcpkg_cache,readwrite"
4445
4546RUN cd /usr/local \
4647 && git clone https://github.com/microsoft/vcpkg \
47- && ./vcpkg/bootstrap- vcpkg.sh -disableMetrics
48+ && chmod -R ugo+rwX /usr/local/ vcpkg
4849
4950WORKDIR /github/workspace
5051COPY ./entrypoint.sh /root/
Original file line number Diff line number Diff line change 3232for SAFE in \
3333 /github/workspace \
3434 /__w/ziti-tunnel-sdk-c/ziti-tunnel-sdk-c \
35- /mnt ; do
36- git config --global --add safe.directory ${SAFE}
35+ /mnt \
36+ /usr/local/vcpkg
37+ do
38+ git config --global --add safe.directory ${SAFE}
3739done
3840
41+ mkdir -p /github/workspace/vcpkg_cache
42+
3943(
40- cd " ${VCPKG_ROOT} "
41- git checkout master
42- git pull
43- ./bootstrap-vcpkg.sh -disableMetrics
44+ cd " ${VCPKG_ROOT} "
45+ git checkout master
46+ git pull
47+ ./bootstrap-vcpkg.sh -disableMetrics
4448)
4549
4650cmake -E make_directory ./build
Original file line number Diff line number Diff line change 11ARG CMAKE_VERSION="3.26.3"
22
3- FROM rockylinux:9
3+ FROM quay.io/almalinuxorg/almalinux:9.6-20250611
44
55ARG CMAKE_VERSION
66
@@ -13,7 +13,8 @@ ENV PATH="/usr/local/:${PATH}"
1313ENV GIT_DISCOVERY_ACROSS_FILESYSTEM=1
1414ENV TZ=UTC
1515
16- RUN dnf install -y \
16+ RUN dnf update --assumeyes --nobest \
17+ && dnf install --assumeyes --nobest \
1718 "@Development Tools" \
1819 dnf-plugins-core \
1920 iproute \
@@ -25,15 +26,15 @@ RUN dnf install -y \
2526 perl-FindBin perl-IPC-Cmd perl-File-Compare perl-File-Copy \
2627 libatomic \
2728 && dnf config-manager --set-enabled crb \
28- && dnf install -y \
29+ && dnf install --assumeyes --nobest \
2930 doxygen \
3031 graphviz \
3132 git \
3233 json-c-devel \
3334 protobuf-c-devel \
3435 openssl-devel \
3536 ninja-build \
36- && dnf clean all
37+ && dnf clean all
3738
3839RUN curl -sSfL https://cmake.org/files/v${CMAKE_VERSION%.*}/cmake-${CMAKE_VERSION}-linux-$(uname -m).sh -o cmake.sh \
3940 && (bash cmake.sh --skip-license --prefix=/usr/local) \
@@ -44,10 +45,10 @@ ENV GIT_CONFIG_GLOBAL="/tmp/ziti-builder-gitconfig"
4445ENV VCPKG_ROOT=/usr/local/vcpkg
4546# this must be set on arm. see https://learn.microsoft.com/en-us/vcpkg/users/config-environment#vcpkg_force_system_binaries
4647ENV VCPKG_FORCE_SYSTEM_BINARIES=yes
48+ ENV VCPKG_BINARY_SOURCES="clear;files,/github/workspace/vcpkg_cache,readwrite"
4749
4850RUN cd /usr/local \
4951 && git clone https://github.com/microsoft/vcpkg \
50- && ./vcpkg/bootstrap-vcpkg.sh -disableMetrics \
5152 && chmod -R ugo+rwX /usr/local/vcpkg
5253
5354WORKDIR /github/workspace
Original file line number Diff line number Diff line change 3232for SAFE in \
3333 /github/workspace \
3434 /__w/ziti-tunnel-sdk-c/ziti-tunnel-sdk-c \
35- /mnt ; do
36- git config --global --add safe.directory ${SAFE}
35+ /mnt \
36+ /usr/local/vcpkg
37+ do
38+ git config --global --add safe.directory ${SAFE}
3739done
3840
41+ mkdir -p /github/workspace/vcpkg_cache
42+
3943(
40- cd " ${VCPKG_ROOT} "
41- git checkout master
42- git pull
43- ./bootstrap-vcpkg.sh -disableMetrics
44+ cd " ${VCPKG_ROOT} "
45+ git checkout master
46+ git pull
47+ ./bootstrap-vcpkg.sh -disableMetrics
4448)
4549
4650(
Original file line number Diff line number Diff line change @@ -56,11 +56,11 @@ RUN curl -sSfL https://cmake.org/files/v${CMAKE_VERSION%.*}/cmake-${CMAKE_VERSIO
5656ENV VCPKG_ROOT=/usr/local/vcpkg
5757# this must be set on arm. see https://learn.microsoft.com/en-us/vcpkg/users/config-environment#vcpkg_force_system_binaries
5858ENV VCPKG_FORCE_SYSTEM_BINARIES=yes
59+ ENV VCPKG_BINARY_SOURCES="clear;files,/github/workspace/vcpkg_cache,readwrite"
5960
6061RUN cd /usr/local \
61- && git config --global advice.detachedHead false \
6262 && git clone https://github.com/microsoft/vcpkg \
63- && ./vcpkg/bootstrap- vcpkg.sh -disableMetrics
63+ && chmod -R ugo+rwX /usr/local/ vcpkg
6464
6565COPY ./entrypoint.sh /root/
6666ENTRYPOINT [ "/root/entrypoint.sh" ]
Original file line number Diff line number Diff line change 3535for SAFE in \
3636 /github/workspace \
3737 /__w/ziti-tunnel-sdk-c/ziti-tunnel-sdk-c \
38- /mnt ; do
39- git config --global --add safe.directory ${SAFE}
38+ /mnt \
39+ /usr/local/vcpkg
40+ do
41+ git config --global --add safe.directory ${SAFE}
4042done
4143
44+ mkdir -p /github/workspace/vcpkg_cache
45+
4246(
43- cd " ${VCPKG_ROOT} "
44- git checkout master
45- git pull
46- ./bootstrap-vcpkg.sh -disableMetrics
47+ cd " ${VCPKG_ROOT} "
48+ git checkout master
49+ git pull
50+ ./bootstrap-vcpkg.sh -disableMetrics
4751)
4852
4953[[ -d ./build ]] && rm -r ./build
Original file line number Diff line number Diff line change @@ -61,11 +61,11 @@ RUN curl -sSfL "https://cmake.org/files/v${CMAKE_VERSION%.*}/cmake-${CMAKE_VERSI
6161ENV VCPKG_ROOT=/usr/local/vcpkg
6262# this must be set on arm. see https://learn.microsoft.com/en-us/vcpkg/users/config-environment#vcpkg_force_system_binaries
6363ENV VCPKG_FORCE_SYSTEM_BINARIES=yes
64+ ARG VCPKG_BINARY_SOURCES="clear;files,/github/workspace/vcpkg_cache,readwrite"
6465
6566RUN cd /usr/local \
66- && git config --global advice.detachedHead false \
6767 && git clone https://github.com/microsoft/vcpkg \
68- && ./vcpkg/bootstrap- vcpkg.sh -disableMetrics
68+ && chmod -R ugo+rwX /usr/local/ vcpkg
6969
7070COPY ./entrypoint.sh /root/
7171ENTRYPOINT [ "/root/entrypoint.sh" ]
You can’t perform that action at this time.
0 commit comments