Update base image, minor tweaks
This commit is contained in:
@@ -1,10 +1,10 @@
|
||||
FROM golang:1.12.6-alpine3.9 AS build
|
||||
FROM golang:1.14.7-alpine3.12 AS build
|
||||
|
||||
WORKDIR /go/src/github.com/abh/geoipapi
|
||||
ADD . /go/src/github.com/abh/geoipapi
|
||||
RUN go install -v ./...
|
||||
|
||||
FROM quay.io/ntppool/dnsmapper:geoip-data-201906
|
||||
FROM quay.io/ntppool/dnsmapper:geoip-data-202007
|
||||
USER root
|
||||
RUN apk --no-cache add ca-certificates
|
||||
|
||||
|
@@ -84,7 +84,7 @@ func getCity(req *http.Request) (*geoip2.City, error) {
|
||||
ipStr := req.FormValue("ip")
|
||||
ip := net.ParseIP(ipStr)
|
||||
if ip == nil {
|
||||
return nil, fmt.Errorf("Missing IP")
|
||||
return nil, fmt.Errorf("missing IP address")
|
||||
}
|
||||
return getCityIP(ip)
|
||||
}
|
||||
|
Reference in New Issue
Block a user