-
-
Notifications
You must be signed in to change notification settings - Fork 89
/
Dockerfile_export
49 lines (42 loc) · 2.18 KB
/
Dockerfile_export
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# Licensed under GPLv3, see https://www.gnu.org/licenses/
FROM archlinux:base-devel
WORKDIR /opt/app-build/
RUN echo 'Server = https://mirrors.xtom.nl/archlinux/$repo/os/$arch' > /etc/pacman.d/mirrorlist ; \
echo 'Server = https://archlinux.mirror.pcextreme.nl/$repo/os/$arch' >> /etc/pacman.d/mirrorlist ; \
echo 'Server = https://archlinux.mirror.wearetriple.com/$repo/os/$arch' >> /etc/pacman.d/mirrorlist ; \
echo 'Server = https://mirror.mijn.host/archlinux/$repo/os/$arch' >> /etc/pacman.d/mirrorlist ; \
\
echo '[multilib]' >> /etc/pacman.conf ; \
echo 'Include = /etc/pacman.d/mirrorlist' >> /etc/pacman.conf
RUN echo "last updated on 2024-05-25" && \
pacman -Syu --noconfirm --needed sudo base-devel git && \
useradd -m user && \
echo "root ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers && \
echo "user ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers && \
echo "en_US.UTF-8 UTF-8" > /etc/locale.gen && \
echo "LANG=en_US.UTF-8" > /etc/locale.conf && \
locale-gen
ENV LANG=en_US.utf8 \
LANGUAGE=en_US.UTF-8 \
LC_ALL=en_US.UTF-8
RUN echo ">>>> Installing opt and test deps:" && \
pacman -Sy --noconfirm --needed --color=always \
devtools python-pysocks python-defusedxml \
ruff flake8 python-pylint mypy vulture bandit shellcheck && \
echo ">>>> Preparing build directory:" && \
chown -R user /opt/app-build/
ADD "https://api.github.com/repos/actionless/pikaur/commits?per_page=1" /home/user/latest_commit
RUN git clone https://github.com/actionless/pikaur.git /opt/app-build/
RUN echo ">>>> Starting the build:" && \
./maintenance_scripts/changelog.sh > CHANGELOG && \
sudo -u user makepkg -fsi --noconfirm && \
rm -fr /opt/app-build/pikaur
# Workaround for broken coveralls v1:
#COPY ./pikaur_meta_helpers /opt/app-build/pikaur_meta_helpers
#RUN sudo -u user python -um pikaur_meta_helpers.pidowngrade python-coverage '7.4.1-1' # up to 7.4.4
# Workaround for broken coveralls v2:
#ADD ./maintenance_scripts/coveralls_PKGBUILD ./coveralls_PKGBUILD
#RUN sudo -u user pikaur -Pi --noconfirm --color=always coveralls_PKGBUILD
RUN echo ">>>> Installing test deps using Pikaur itself:" && \
sudo -u user pikaur -S --noconfirm --mflags=--skippgpcheck --color=always python-coveralls
# vim: set ft=dockerfile :