Files
tpotce/docker/go-pot/Dockerfile

23 lines
568 B
Docker
Raw Normal View History

2024-11-28 15:00:22 +01:00
FROM golang:1.23-alpine AS builder
2024-10-11 20:43:08 +02:00
RUN <<EOF
apk -U add git
mkdir -p /opt
cd /opt
git clone https://github.com/t3chn0m4g3/go-pot
EOF
WORKDIR /opt/go-pot
#
RUN go get github.com/ua-parser/uap-go/uaparser
RUN go mod download
RUN CGO_ENABLED=0 GOOS=linux go build -o /opt/go-pot/go-pot
#
2024-11-28 15:55:27 +01:00
FROM scratch
2024-10-11 20:43:08 +02:00
#
COPY --from=builder /opt/go-pot/go-pot /opt/go-pot/go-pot
COPY --from=builder /opt/go-pot/config.yml /opt/go-pot/config.yml
#
2024-10-18 21:59:29 +02:00
STOPSIGNAL SIGINT
2024-11-28 15:00:22 +01:00
USER 2000:2000
2024-10-11 20:43:08 +02:00
WORKDIR /opt/go-pot
CMD ["start", "--host", "0.0.0.0", "--config-file", "config.yml"]
ENTRYPOINT ["./go-pot"]