blob: 025c8b5021a8db3051933fecef96ee94d0f60f74 (
plain)
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
|
FROM archlinux:latest AS build-stage
RUN echo $'\
Server = https://mirrors.aliyun.com/archlinux/$repo/os/$arch\n\
Server = https://mirrors.cloud.tencent.com/archlinux/$repo/os/$arch\n\
' > /etc/pacman.d/mirrorlist
RUN echo $'\
[archlinuxcn]\n\
Server = https://mirrors.aliyun.com/archlinuxcn/$arch\n\
Server = https://mirrors.cloud.tencent.com/archlinuxcn/$arch\n\
' >> /etc/pacman.conf
RUN pacman-key --init
RUN pacman -Syu archlinuxcn-keyring base-devel pacman-contrib namcap --needed --noconfirm
RUN pacman -S yay --needed --noconfirm
RUN echo 'nobody ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers
RUN usermod -d /tmp nobody
USER nobody
COPY --chown=nobody:nobody PKGBUILD xorgxrdp-nvidia.install /code/
WORKDIR /code
ENV ALL_PROXY=socks5h://host.docker.internal:1080
RUN updpkgsums
RUN makepkg --printsrcinfo > .SRCINFO
RUN yay -S xrdp --needed --noconfirm
RUN makepkg -si --needed --noconfirm
RUN pacman -Ql xorgxrdp-nvidia
RUN namcap PKGBUILD
RUN [ -z "$(namcap PKGBUILD 2>&1)" ]
FROM scratch AS export-stage
COPY --from=build-stage /code/PKGBUILD /code/.SRCINFO /
|