2023-07-24 11:57:45 +01:00
|
|
|
FROM archlinux:base-devel
|
|
|
|
|
|
|
|
RUN pacman --needed --noconfirm -Syu \
|
|
|
|
base \
|
|
|
|
git \
|
|
|
|
pacman-contrib \
|
|
|
|
openssh
|
|
|
|
|
|
|
|
RUN useradd -m builder && \
|
|
|
|
echo "builder ALL=(ALL:ALL) NOPASSWD: ALL" >> /etc/sudoers && \
|
|
|
|
echo "%wheel ALL=(ALL:ALL) NOPASSWD: ALL" >> /etc/sudoers && \
|
|
|
|
usermod -a -G wheel builder
|
|
|
|
|
|
|
|
RUN mkdir -p /home/builder/.ssh && \
|
|
|
|
touch /home/builder/.ssh/known_hosts
|
|
|
|
|
2023-07-27 05:52:09 +01:00
|
|
|
COPY ./ssh_creds/.ssh /home/builder/.ssh
|
2023-07-25 12:55:40 +01:00
|
|
|
|
2023-07-27 05:53:15 +01:00
|
|
|
COPY *.PKGBUILD *.sh ssh_config /home/builder/packaging_scripts/
|
2023-07-24 16:21:50 +01:00
|
|
|
|
2023-07-24 11:57:45 +01:00
|
|
|
RUN chown -R builder:builder /home/builder/.ssh && \
|
2023-07-24 16:10:46 +01:00
|
|
|
chmod 600 /home/builder/.ssh/* -R && \
|
2023-07-24 16:13:03 +01:00
|
|
|
chown -R builder:builder /home/builder/packaging_scripts && \
|
|
|
|
chmod +x /home/builder/packaging_scripts/*.sh
|
2023-07-24 11:57:45 +01:00
|
|
|
|
|
|
|
USER builder
|
2023-07-24 16:14:34 +01:00
|
|
|
WORKDIR /home/builder/packaging_scripts
|
2023-07-24 11:57:45 +01:00
|
|
|
|
|
|
|
ENTRYPOINT ["/home/builder/packaging_scripts/publish.sh"]
|