19 lines
434 B
Docker
19 lines
434 B
Docker
FROM golang:1.16-alpine AS build
|
|
RUN apk add --no-cache git
|
|
WORKDIR /build
|
|
RUN git clone https://code.rocketnine.space/tslocum/twins.git
|
|
|
|
WORKDIR /build/twins
|
|
RUN go build
|
|
|
|
FROM gruebel/upx as upx
|
|
COPY --from=build /build/twins/twins /twins-uncompressed
|
|
RUN upx --best --lzma -o /twins /twins-uncompressed
|
|
|
|
FROM alpine:3.13
|
|
WORKDIR /app
|
|
COPY --from=upx /twins /app/twins
|
|
|
|
EXPOSE 1965
|
|
CMD ["/app/twins", "-config", "/app/config.yaml"]
|