Skip to content
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
3 changes: 2 additions & 1 deletion .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,8 @@ jobs:
- os: ubuntu-24.04
node_arch: arm64
cpp_arch: amd64_arm64
distro: alpine_latest
distro: none
base_image: aminya/setup-cpp-alpine-gcc:3.21-1.4.0-arm64
native: false

env:
Expand Down
20 changes: 2 additions & 18 deletions docker/alpine.dockerfile
Original file line number Diff line number Diff line change
@@ -1,36 +1,20 @@
FROM node:18-alpine AS builder
FROM aminya/setup-cpp-alpine-gcc:3.21-1.4.0-amd64 AS builder

WORKDIR /app
COPY ./ ./
ENV VCPKG_FORCE_SYSTEM_BINARIES=1
RUN \
# system dependencies
apk add --no-cache \
bash \
build-base \
curl \
git \
g++ \
make \
ninja-build \
pkgconfig \
unzip \
zip \
python3 \
tar \
cmake \
ninja \
musl-dev \
automake \
autoconf \
libtool && \
cp /usr/lib/ninja-build/bin/ninja /usr/bin/ninja && \
# build
npm i -g pnpm && \
pnpm install && \
pnpm run build

FROM node:18-alpine
FROM node:alpine3.21
WORKDIR /app

COPY ./ ./
Expand Down
25 changes: 15 additions & 10 deletions script/install-deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,16 +37,21 @@ fi
apk=$(command -v apk || true)
if [ -n "$apk" ]; then
apk update
apk add --no-cache bash build-base curl git g++ make ninja-build pkgconfig unzip zip python3 tar cmake musl-dev automake autoconf libtool nodejs npm
cp /usr/lib/ninja-build/bin/ninja /usr/bin/ninja

# vcpkg
export VCPKG_FORCE_SYSTEM_BINARIES=1
git clone https://github.com/microsoft/vcpkg.git ~/vcpkg
cd ~/vcpkg || exit 1
git checkout "$VCPKG_COMMIT"
~/vcpkg/bootstrap-vcpkg.sh
cd - || exit 1

if [ -z "$(command -v setup-cpp || true)" ]; then
apk add --no-cache bash build-base curl git g++ make ninja-build pkgconfig unzip zip python3 tar cmake musl-dev nodejs npm
cp /usr/lib/ninja-build/bin/ninja /usr/bin/ninja

# vcpkg
export VCPKG_FORCE_SYSTEM_BINARIES=1
git clone https://github.com/microsoft/vcpkg.git ~/vcpkg
cd ~/vcpkg || exit 1
git checkout "$VCPKG_COMMIT"
~/vcpkg/bootstrap-vcpkg.sh
cd - || exit 1
fi

apk add --no-cache automake autoconf libtool
fi

# Fedora/RHEL
Expand Down
Loading