setup-cpp/dev/docker/ci/arch.dockerfile

44 lines
1.1 KiB
Plaintext
Raw Normal View History

2025-02-23 18:52:45 +08:00
## base image
FROM --platform=$BUILDPLATFORM archlinux:base AS arch-nodejs
2025-02-23 18:52:45 +08:00
2025-03-02 19:09:30 +08:00
# Setup bash environment
RUN echo '[[ -f ~/.bashrc ]] && . ~/.bashrc' > /root/.bash_profile
2025-02-23 18:52:45 +08:00
RUN pacman -Syuu --noconfirm && \
pacman-db-upgrade && \
# install nodejs
pacman -S --noconfirm --needed nodejs npm && \
# cleanup
pacman -Scc --noconfirm && \
rm -rf /var/cache/pacman/pkg/* && \
rm -rf /tmp/*
FROM arch-nodejs AS setup-cpp-arch
2025-02-23 18:52:45 +08:00
COPY "./dist/modern" "/usr/lib/setup-cpp/"
2025-02-23 18:52:45 +08:00
# install the cpp tools
RUN pacman -Syuu --noconfirm && \
pacman-db-upgrade && \
node --enable-source-maps /usr/lib/setup-cpp/setup-cpp.mjs \
2025-02-23 18:52:45 +08:00
--cmake true \
--ninja true \
--task true \
--vcpkg true \
--python true \
--make true \
--cppcheck true \
--gcovr true \
--doxygen true \
--ccache true \
--conan true \
--cmakelang true \
--meson true && \
2025-02-23 18:52:45 +08:00
# arch cleanup
pacman -Scc --noconfirm && \
rm -rf /var/cache/pacman/pkg/* && \
rm -rf /tmp/*
SHELL ["/bin/bash", "-l", "-c"]
ENTRYPOINT ["/bin/bash", "-l"]