Initial sandbox infrastructure setup.
This commit is contained in:
1 parent
6ac68a7025
commit
0737b28897
10 files changed
+262
No files matched your search
@@ -0,0 +1,27 @@
|
||||
FROM debian:trixie-slim
|
||||
|
||||
ENV LANG=C.UTF-8
|
||||
|
||||
# Slim images exclude man pages through a dpkg path filter. Removing it and
|
||||
# reinstalling the preinstalled essentials restores their man pages.
|
||||
RUN rm -f /etc/dpkg/dpkg.cfg.d/docker \
|
||||
&& apt-get update \
|
||||
&& apt-get install -y --no-install-recommends --reinstall \
|
||||
bash coreutils findutils grep sed \
|
||||
&& apt-get install -y --no-install-recommends \
|
||||
gawk less tree file vim-tiny nano man-db manpages jq procps htop \
|
||||
figlet cowsay fortune-mod fortunes-min sl curl wget \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Setuid binaries are useless under no-new-privileges, so they are stripped
|
||||
# to keep the attack surface minimal even if that option is ever dropped.
|
||||
RUN useradd --uid 1000 --create-home --shell /bin/bash guest \
|
||||
&& find / -xdev -perm /6000 -type f -exec chmod a-s {} +
|
||||
|
||||
COPY etc/ /etc/
|
||||
COPY --chmod=0755 bin/status /usr/local/bin/status
|
||||
|
||||
ENV PATH=/usr/local/bin:/usr/bin:/bin:/usr/games
|
||||
USER guest
|
||||
WORKDIR /home/guest
|
||||
CMD ["/bin/bash", "-l"]
|
||||
Reference in new issue
Block a user