summaryrefslogtreecommitdiff
path: root/suckless2/Dockerfile
diff options
context:
space:
mode:
Diffstat (limited to 'suckless2/Dockerfile')
-rw-r--r--suckless2/Dockerfile22
1 files changed, 22 insertions, 0 deletions
diff --git a/suckless2/Dockerfile b/suckless2/Dockerfile
new file mode 100644
index 0000000..97e8291
--- /dev/null
+++ b/suckless2/Dockerfile
@@ -0,0 +1,22 @@
+# Stolen from https://github.com/LiveOverflow/pwn_docker_example/blob/master/challenge/Dockerfile
+
+# docker build -t suckless2 .
+# docker run -d -p 8089:8089 --restart=always --name suckless2 suckless2
+
+FROM ubuntu:20.04
+
+RUN apt-get update
+
+RUN useradd -d /home/ctf/ -m -p ctf -s /bin/bash ctf
+RUN echo "ctf:ctf" | chpasswd
+
+WORKDIR /home/ctf
+
+COPY suckless2 .
+COPY ynetd .
+
+RUN chown -R root:root /home/ctf
+
+USER ctf
+EXPOSE 8089
+CMD ./ynetd -p 8089 ./suckless2