-
-
Notifications
You must be signed in to change notification settings - Fork 23
Expand file tree
/
Copy pathDockerfile.ci-build-arch
More file actions
56 lines (48 loc) · 1.4 KB
/
Dockerfile.ci-build-arch
File metadata and controls
56 lines (48 loc) · 1.4 KB
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
50
51
52
53
54
55
56
FROM archlinux:latest
WORKDIR /workspace
# Install build dependencies
RUN pacman -Syu --noconfirm && \
pacman -S --noconfirm --needed \
base-devel \
ca-certificates \
curl \
dpkg \
fakeroot \
flatpak \
flatpak-builder \
fuse2 \
git \
gtk3 \
libappindicator-gtk3 \
libx11 \
libxkbcommon \
libxkbcommon-x11 \
libxtst \
openssh \
openssl \
ostree \
pkgconf \
rpm-tools \
sudo \
unzip \
wget \
xorgproto \
&& pacman -Scc --noconfirm
# Install Go (use Arch package for simplicity)
RUN pacman -S --noconfirm --needed go
ENV PATH="/usr/lib/go/bin:/usr/bin:$PATH"
# Copy Go module files and download dependencies
COPY go.mod go.sum ./
RUN go env -w GOPROXY=https://proxy.golang.org,direct && \
go mod download && go mod verify
# Install Node.js and pnpm
RUN pacman -Sy --noconfirm && \
pacman -S --noconfirm --needed nodejs npm pnpm
# Install AppImageTool
RUN wget -q https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-x86_64.AppImage -O /usr/local/bin/appimagetool && \
chmod +x /usr/local/bin/appimagetool
# Create a non-root user for builds
RUN useradd -ms /bin/bash builduser && \
echo 'builduser ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/builduser
# Entrypoint for CI
CMD ["bash"]