archlinux/plasma/Dockerfile

59 lines
1.7 KiB
Text
Raw Normal View History

2024-07-25 01:26:27 +00:00
# syntax = docker/dockerfile:1
2025-01-20 09:45:38 +00:00
FROM quay.io/archlinux/archlinux:base-devel
2024-07-25 01:26:27 +00:00
USER root
2025-01-27 01:39:29 +00:00
# Exempt from image pruning
LABEL prune="do_not_delete"
2025-01-20 09:45:38 +00:00
# Build ARG for additional packages to install (eg, openssh)
ARG addpkg
# Build ARG: use "root" for debugging
ARG debug
# Copy mirrorlist
COPY mirrorlist /etc/pacman.d/mirrorlist
# Copy app folder
2025-01-21 00:50:32 +00:00
COPY entrypoint /entrypoint
2024-07-25 01:26:27 +00:00
# Install packages
RUN --mount=type=cache,sharing=locked,target=/var/cache/pacman \
2025-01-20 09:45:38 +00:00
pacman-key --init \
&& sed -i '/ParallelDownloads/c ParallelDownloads = 10' /etc/pacman.conf \
&& pacman -Sy --ask 4 archlinux-keyring \
&& pacman -Su --ask 4 --needed ${addpkg} \
sudo bash bash-completion \
tigervnc \
cuda openssh vim pacman-contrib rsync git \
2025-08-07 11:32:15 +00:00
plasma plasma-x11-session konsole kate dolphin kompare kcalc \
jack2 \
ttf-dejavu noto-fonts-cjk \
2025-01-20 09:45:38 +00:00
firefox firefox-decentraleyes firefox-ublock-origin \
torbrowser-launcher \
shotwell ffmpegthumbs ark okular \
remmina libvncserver \
2024-07-25 01:26:27 +00:00
&& pacman -Scc --ask 4 \
2025-01-20 09:45:38 +00:00
&& useradd --create-home --gid users --shell /usr/bin/bash user \
&& printf '%s\n' 'user ALL=(ALL:ALL) NOPASSWD: /usr/bin/pacman' \
'Defaults lecture = never' >/etc/sudoers.d/zz-DOCKER \
&& passwd -l root >/dev/null 2>&1
2025-01-20 09:45:38 +00:00
# Default environment
USER ${debug:-user}
WORKDIR /home/user
ENV HOME=/home/user
ENV DISPLAY=:0
ENV SHELL=/usr/bin/bash
2025-01-21 03:30:58 +00:00
ENV PS1="[\u@myvnc \W \$?]\$ "
2025-01-20 09:45:38 +00:00
# X session environment variable
ENV STARTXBIN=startplasma-x11
2024-07-25 01:26:27 +00:00
# configure nvidia container runtime
# https://github.com/NVIDIA/nvidia-container-runtime#environment-variables-oci-spec
ENV NVIDIA_VISIBLE_DEVICES=all
ENV NVIDIA_DRIVER_CAPABILITIES=compute,utility
2025-01-20 09:45:38 +00:00
# Docker entrypoint
2025-01-21 00:50:32 +00:00
ENTRYPOINT ["/entrypoint"]