# HG changeset patch # User Richard Westhaver # Date 1723928926 14400 # Node ID 48affaffc460ce23c8c0e5db672a08a575362772 # Parent 99106a32c531ff850e023fa63a6cb89e881fc47d workers diff -r 99106a32c531 -r 48affaffc460 Containerfile.archlinux --- a/Containerfile.archlinux Thu Aug 15 22:10:20 2024 -0400 +++ b/Containerfile.archlinux Sat Aug 17 17:08:46 2024 -0400 @@ -1,4 +1,5 @@ FROM archlinux:latest -RUN --network=host pacman-key --init -RUN --network=host pacman-key --populate archlinux -RUN --network=host pacman -Syu base-devel less uutils-coreutils openssl openssh mercurial git liburing wireguard-tools libxcb zstd --noconfirm \ No newline at end of file +RUN --network=host pacman-key --init -u +RUN --network=host pacman -Sy --needed archlinux-keyring --noconfirm && pacman -Su --noconfirm +RUN --network=host pacman -Syu base-devel less uutils-coreutils openssl openssh mercurial git liburing wireguard-tools libxcb zstd pacman-contrib --noconfirm +RUN pacman -Scc --noconfirm \ No newline at end of file diff -r 99106a32c531 -r 48affaffc460 Containerfile.dev --- a/Containerfile.dev Thu Aug 15 22:10:20 2024 -0400 +++ b/Containerfile.dev Sat Aug 17 17:08:46 2024 -0400 @@ -3,7 +3,7 @@ ARG DEV=dev ARG DEV_HOME=/home/${DEV} ARG DEV_ID=808 -RUN mkdir -p /usr/share/lisp /usr/local/share/lisp /usr/local/share/rust +RUN mkdir -p /usr/share/lisp /usr/local/share/lisp /usr/local/share/rust /opt/store /opt/stash RUN useradd --system -s /usr/bin/bash -u ${DEV_ID} -m ${DEV} -G wheel RUN groupadd -g 128 engineer -U ${DEV} RUN groupadd -g 256 operator -U ${DEV} @@ -15,6 +15,7 @@ RUN chown -R ${DEV}:engineer /usr/local/include/ RUN chown -R ${DEV}:engineer /usr/local/man/ RUN ssh-keygen -A +RUN pacman -Scc --noconfirm USER ${DEV} RUN mkdir -p ${DEV_HOME}/.stash/lisp WORKDIR ${DEV_HOME}/.stash diff -r 99106a32c531 -r 48affaffc460 Containerfile.infra --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Containerfile.infra Sat Aug 17 17:08:46 2024 -0400 @@ -0,0 +1,3 @@ +FROM localhost/worker:latest +WORKDIR ${WORKER_HOME}/.stash/infra +RUN skel clean && skel pull \ No newline at end of file diff -r 99106a32c531 -r 48affaffc460 Containerfile.operator --- a/Containerfile.operator Thu Aug 15 22:10:20 2024 -0400 +++ b/Containerfile.operator Sat Aug 17 17:08:46 2024 -0400 @@ -3,6 +3,7 @@ RUN usermod -l operator --move-home --home /home/operator ${DEV} RUN echo "operator ALL=(ALL:ALL) NOPASSWD: ALL" | sudo tee /etc/sudoers.d/operator RUN --network=host pacman -Sy aspell hunspell-en_us --noconfirm +RUN pacman -Scc --noconfirm USER operator WORKDIR /home/operator RUN hg clone https://vc.compiler.company/comp/infra .stash/infra diff -r 99106a32c531 -r 48affaffc460 Containerfile.worker --- a/Containerfile.worker Thu Aug 15 22:10:20 2024 -0400 +++ b/Containerfile.worker Sat Aug 17 17:08:46 2024 -0400 @@ -2,10 +2,14 @@ ARG WORKER_ID=908 ARG WORKER=worker ARG WORKER_HOME=/home/${WORKER} +ARG STASH=/usr/local/share/stash +ARG STORE=/usr/local/share/store USER root RUN useradd --system -s /usr/bin/bash -u ${WORKER_ID} -m ${WORKER} -G wheel +RUN echo "worker ALL=(ALL:ALL) NOPASSWD: ALL" | sudo tee /etc/sudoers.d/worker RUN ssh-keygen -A -RUN chown -R ${WORKER_ID}:worker /usr/local/ +RUN mkdir -pv ${STASH} ${STORE} +RUN chown -R ${WORKER_ID}:worker /usr/local/* USER ${WORKER} RUN mkdir -pv ${WORKER_HOME}/.stash WORKDIR ${WORKER_HOME}/.stash @@ -23,4 +27,6 @@ RUN homer install ENV WORKER=${WORKER} ENV WORKER_ID=${WORKER_ID} -ENV WORKER_HOME=${WORKER_HOME} \ No newline at end of file +ENV WORKER_HOME=${WORKER_HOME} +ENV STASH=${STASH} +ENV STORE=${STORE} \ No newline at end of file diff -r 99106a32c531 -r 48affaffc460 skelfile --- a/skelfile Thu Aug 15 22:10:20 2024 -0400 +++ b/skelfile Sat Aug 17 17:08:46 2024 -0400 @@ -17,6 +17,12 @@ ((web () #$podman run --name web --replace -dt -p 8080:8080 -p 2020:2020 \ --volume /srv/http:/home/web/www \ web$#) + (infra-sbcl () #$podman run --replace -dt -v /opt/stash:/usr/local/share/stash:z --name infra-sbcl infra \ + -c "skel build sbcl && skel dist sbcl && sudo cp .stash/sbcl.tar.zst /usr/local/share/stash"$#) + (infra-emacs () #$podman run --replace -dt -v /opt/stash:/usr/local/share/stash:z --name infra-emacs infra \ + -c "skel build emacs && skel dist emacs && sudo cp .stash/emacs.tar.zst /usr/local/share/stash"$#) + (infra-rocksdb () #$podman run --replace -dt -v /opt/stash:/usr/local/share/stash:z --name infra-rocksdb infra \ + -c "skel build rocksdb && skel dist rocksdb && sudo cp .stash/rocksdb.tar.zst /usr/local/share/stash"$#) (operator () #$podman run --name operator --replace -dt operator$#) (vc () #$podman run --name vc --replace -dt -p 8888:8888 vc$#) (dev () #$podman run --name dev --replace -dt dev$#)