This commit is contained in:
Matti Paksula 2017-05-23 22:29:49 +00:00 committed by GitHub
commit 381048acb3
2 changed files with 24 additions and 0 deletions

15
Dockerfile Normal file
View File

@ -0,0 +1,15 @@
FROM golang:1.8.1-alpine
WORKDIR /app
COPY Makefile .
RUN apk add --update --no-cache git make curl && \
go get github.com/martinp/ipd && \
make get-geoip-dbs
COPY index.html .
EXPOSE 8080
ENTRYPOINT ["ipd"]
CMD ["-f", "/app/GeoLite2-Country.mmdb", "-c", "/app/GeoLite2-City.mmdb", "--port-lookup", "--reverse-lookup", "-L", "debug"]

View File

@ -68,6 +68,15 @@ This application can be installed by using `go get`:
`go get github.com/mpolden/ipd`
## Docker
```
$ docker build -t ipd .
$ docker run -d -p 9999:8080 ipd
$ curl localhost:9999
...
````
### Usage
```