2018-07-30 17:33:36 +00:00
|
|
|
FROM golang:latest as builder
|
|
|
|
RUN go get -tags netgo github.com/mpolden/ipd/...
|
|
|
|
|
|
|
|
FROM alpine:latest
|
|
|
|
RUN apk add --update --no-cache ca-certificates curl geoip
|
|
|
|
RUN sh /etc/periodic/monthly/geoip
|
|
|
|
COPY --from=builder /go/bin/ipd /usr/bin/ipd
|
2018-07-30 18:12:56 +00:00
|
|
|
EXPOSE 8080
|
2018-07-30 17:33:36 +00:00
|
|
|
ENTRYPOINT ipd \
|
|
|
|
--country-db /usr/share/GeoIP/GeoIP.dat \
|
|
|
|
--city-db /usr/share/GeoIP/GeoLiteCity.dat \
|
|
|
|
--port-lookup \
|
|
|
|
--reverse-lookup \
|
|
|
|
--listen 0.0.0.0:8080
|