diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..9381fe5 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,26 @@ +.env +map-dots +*.png +Dockerfile + +# If you prefer the allow list template instead of the deny list, see community template: +# https://github.com/github/gitignore/blob/main/community/Golang/Go.AllowList.gitignore +# +# Binaries for programs and plugins +*.exe +*.exe~ +*.dll +*.so +*.dylib + +# Test binary, built with `go test -c` +*.test + +# Output of the go coverage tool, specifically when used with LiteIDE +*.out + +# Dependency directories (remove the comment below to include it) +# vendor/ + +# Go workspace file +go.work \ No newline at end of file diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..aea5f49 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,8 @@ +FROM golang:alpine as builder +WORKDIR /build +COPY . . +RUN go build + +FROM scratch +COPY --from=builder /build/map-dots /bin/map-dots +CMD [ "/bin/map-dots", "--server" ] \ No newline at end of file