about summary refs log tree commit diff
path: root/Dockerfile
diff options
context:
space:
mode:
authormaride <maride@darknebu.la>2019-02-12 14:40:46 +0100
committermaride <maride@darknebu.la>2019-02-12 14:40:46 +0100
commit34e0f86d7eea9ed9cb891d20d0de63ce7e79dc0a (patch)
treecd682c605fc4f532d5c775ec2baf966620370632 /Dockerfile
Init
Diffstat (limited to 'Dockerfile')
-rw-r--r--Dockerfile19
1 files changed, 19 insertions, 0 deletions
diff --git a/Dockerfile b/Dockerfile
new file mode 100644
index 0000000..cdb8930
--- /dev/null
+++ b/Dockerfile
@@ -0,0 +1,19 @@
+FROM golang:1.10-alpine
+
+# Setup
+COPY main.go .
+
+# Install libs
+RUN apk add git
+RUN go get github.com/gliderlabs/ssh
+
+# Build
+RUN go build -o ssh-grab-keypass
+
+# Drop privs
+RUN adduser -u 1337 -D jail
+RUN chmod 000 /home/jail
+
+EXPOSE 2222
+
+CMD su -c ./ssh-grab-keypass jail