aboutsummaryrefslogtreecommitdiff
path: root/Dockerfile
diff options
context:
space:
mode:
Diffstat (limited to 'Dockerfile')
-rw-r--r--Dockerfile13
1 files changed, 13 insertions, 0 deletions
diff --git a/Dockerfile b/Dockerfile
new file mode 100644
index 0000000..4052183
--- /dev/null
+++ b/Dockerfile
@@ -0,0 +1,13 @@
+FROM golang:1.12-alpine as builder
+WORKDIR /app
+COPY . /app
+RUN apk add --no-cache git make \
+ && make linux-amd64
+
+# Runtime
+FROM scratch
+COPY --from=builder /app/build/tarpit-linux-amd64 /tarpit
+USER 65534:65534
+EXPOSE 2022
+ENTRYPOINT ["/tarpit"]
+CMD ["-p", "2022"]