Skip to content

Commit

Permalink
reduce number of files
Browse files Browse the repository at this point in the history
  • Loading branch information
zsarge committed Mar 26, 2024
1 parent 36064cc commit f7c5ee4
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 11 deletions.
10 changes: 0 additions & 10 deletions ChallengeDockerfile

This file was deleted.

17 changes: 16 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,22 @@ COPY --from=download-gotty /go/bin/gotty /app/gotty
RUN mkdir /lib64 && ln -s /lib/libc.musl-x86_64.so.1 /lib64/ld-linux-x86-64.so.2

COPY start-shell.sh start-shell.sh
COPY ChallengeDockerfile Dockerfile
# create the same dockerfile for every challenge
RUN <<EOF
cat <<HEREDOC > Dockerfile
# The basic dockerfile that is loaded for each console.
# should take ~1MB per open console.
FROM ubuntu:22.04

COPY SETUP.sh SETUP.sh
RUN bash SETUP.sh
RUN rm SETUP.sh

CMD ["/bin/bash"]
HEREDOC
EOF

# copy into image for setup (it will be deleted before the final image)
COPY SETUP.sh SETUP.sh

# run docker containers inside this docker container.
Expand Down

0 comments on commit f7c5ee4

Please sign in to comment.