build: speedup pacman

This commit is contained in:
Evgenii Alekseev 2024-09-23 03:30:17 +03:00
parent b20e844cc9
commit 24993047c6

View File

@ -25,13 +25,13 @@ RUN echo "[multilib]" >> "/etc/pacman.conf" && \
echo "Include = /etc/pacman.d/mirrorlist" >> "/etc/pacman.conf" echo "Include = /etc/pacman.d/mirrorlist" >> "/etc/pacman.conf"
## refresh packages, install sudo and install packages for building ## refresh packages, install sudo and install packages for building
RUN pacman -Syu --noconfirm sudo && \ RUN pacman -Syu --noconfirm sudo && \
pacman -Sy --noconfirm --asdeps fakeroot python-tox pacman -S --noconfirm --asdeps fakeroot python-tox
## create build user ## create build user
RUN useradd -m -d "/home/build" -s "/usr/bin/nologin" build && \ RUN useradd -m -d "/home/build" -s "/usr/bin/nologin" build && \
echo "build ALL=(ALL) NOPASSWD: ALL" > "/etc/sudoers.d/build" echo "build ALL=(ALL) NOPASSWD: ALL" > "/etc/sudoers.d/build"
COPY "docker/install-aur-package.sh" "/usr/local/bin/install-aur-package" COPY "docker/install-aur-package.sh" "/usr/local/bin/install-aur-package"
## install package dependencies ## install package dependencies
RUN pacman -Sy --noconfirm --asdeps \ RUN pacman -S --noconfirm --asdeps \
devtools \ devtools \
git \ git \
pyalpm \ pyalpm \
@ -40,14 +40,14 @@ RUN pacman -Sy --noconfirm --asdeps \
python-pyelftools \ python-pyelftools \
python-requests \ python-requests \
&& \ && \
pacman -Sy --noconfirm --asdeps \ pacman -S --noconfirm --asdeps \
base-devel \ base-devel \
python-build \ python-build \
python-flit \ python-flit \
python-installer \ python-installer \
python-wheel \ python-wheel \
&& \ && \
pacman -Sy --noconfirm --asdeps \ pacman -S --noconfirm --asdeps \
git \ git \
python-aiohttp \ python-aiohttp \
python-boto3 \ python-boto3 \