Skip to content
This repository has been archived by the owner on Jun 20, 2024. It is now read-only.

apilayer/freegeoip docker image doesn't exist #2

Open
justgage opened this issue Feb 27, 2018 · 22 comments
Open

apilayer/freegeoip docker image doesn't exist #2

justgage opened this issue Feb 27, 2018 · 22 comments

Comments

@justgage
Copy link

justgage commented Feb 27, 2018

I know that this repo just barely changed hands but I just wanted to create an issue to track this problem:

λ ~/code/freegeoip/ master docker run --restart=always -p 8080:4444 -d apilayer/freegeoip
Unable to find image 'apilayer/freegeoip:latest' locally
docker: Error response from daemon: pull access denied for apilayer/freegeoip, repository does not exist or may require 'docker login'.
See 'docker run --help'.
@own3mall
Copy link

own3mall commented Mar 1, 2018

Yep, I have the same issue.

@julian-zehetmayr
Copy link
Contributor

Hey Guys,

We are working on this and should have an update here next week. In the meantime you can build from the old repo.

@OlagStegan
Copy link

Just the image ?
'cause that was easy enough to do with standard 'docker build' etc.
Or will next week's include a fix to the Lets Encrypt issue ?

@jasonsalzman
Copy link

are there any updates on this? I'm still getting the same error. I know it's being switched over to a freemium model, nothing seems to be mentioned about removing the self-hosted solution

@ghost
Copy link

ghost commented Apr 10, 2018

I was able to build an image and start the container with docker run <image id> after the same error, but now I am getting 404 for all requests. Does anyone know what the problem is?

@seega
Copy link

seega commented Jun 30, 2018

@julian-zehetmayr as I understand it, the docker repo will not be released?

@keyurpatel89
Copy link

keyurpatel89 commented Jul 5, 2018

Hi @seega ,

You can use this : https://github.com/fiorix/freegeoip

@rmstmg01
Copy link

It seems issue has not been fixed yet. I am getting the same error.

docker run --restart=always -p 8080:8080 -d apilayer/freegeoip
Unable to find image 'apilayer/freegeoip:latest' locally
docker: Error response from daemon: pull access denied for apilayer/freegeoip, repository does not exist or may require 'docker login'.
See 'docker run --help'.

@OlagStegan
Copy link

OlagStegan commented Jul 18, 2018

@rameshyonjan as noted above and elsewhere the free docker image has gone and has been replaced with a pay as you go API (free for first so many #hits)

If you had (like we did) taken a copy of the original code then you would still be able to rebuild your own docker image and use that. That is getting no further development AFAIK you would then need to employ/learn GOlang internal dev to fix bugs/improve/support

A PITA but that's Open Source for you

@noskov
Copy link

noskov commented Jul 23, 2018

Hi there!
If you want you can build your own Docker image.

  1. Just clone this official repo: git clone [email protected]:apilayer/freegeoip.git YOUR_LOCAL_PATH
  2. Go to the folder with the repo: cd YOUR_LOCAL_PATH
  3. Tell Docker to build the image: docker build .

That's all. In the result you'll have your own image from the latest codebase.

As an alternative you can use the image, that I've build recently, and pushed it to Docker Hub. You can find it here https://hub.docker.com/r/noskov/freegeoip/

Usage:
docker run --restart=always -p 8080:8080 -d noskov/freegeoip

@rmstmg01
Copy link

rmstmg01 commented Aug 7, 2018

@noskov, Thanks for your suggestion. I build my own image from apilayer/freegeoip.git but it seems GEO database is not recent as IP GEO location is different than from https://www.maxmind.com/en/geoip-demo
Is there any method I can use to update db from Maxmind Geo Database to my own docker image?

Thanks in advance.

@noskov
Copy link

noskov commented Aug 18, 2018

Hi @rameshyonjan! I didn't change the database, so it's not tested, but I guess you can try to change it in Dockerfile with the CMD intruction. See here and rebuild the image with your own database settings.

Or, as an option, you can try to figure the server to use the custom database with the FreeGeoIP parameter -db=url-to-your-own-database.mmdb.gz (Default one is http://geolite.maxmind.com/download/geoip/database/GeoLite2-City.mmdb.gz).

See all the server params running docker run --rm -it apilayer/freegeoip -help

@al-muammar
Copy link

al-muammar commented Jul 16, 2019

Hi @noskov, when I'm doing
docker build . I'm getting the following error:

~/freegeoip$ docker build .
Sending build context to Docker daemon  1.768MB
Step 1/7 : FROM golang:1.9
1.9: Pulling from library/golang
55cbf04beb70: Pull complete
1607093a898c: Pull complete
9a8ea045c926: Pull complete
d4eee24d4dac: Pull complete
9c35c9787a2f: Pull complete
8b376bbb244f: Pull complete
0d4eafcc732a: Pull complete
186b06a99029: Pull complete
Digest: sha256:8b5968585131604a92af02f5690713efadf029cc8dad53f79280b87a80eb1354
Status: Downloaded newer image for golang:1.9
 ---> ef89ef5c42a9
Step 2/7 : COPY cmd/freegeoip/public /var/www
 ---> 41447a2e0446
Step 3/7 : ADD . /go/src/github.com/apilayer/freegeoip
 ---> 52888e9b264b
Step 4/7 : RUN  cd /go/src/github.com/apilayer/freegeoip/cmd/freegeoip &&       go get -d && go install &&      apt-get update && apt-get install -y libcap2-bin &&     setcap cap_net_bind_service=+ep /go/bin/freegeoip &&    apt-get clean
&& rm -rf /var/lib/apt/lists/* &&       useradd -ms /bin/bash freegeoip
 ---> Running in 848106df2f8d
# github.com/apilayer/freegeoip/apiserver
../../apiserver/api.go:106:9: undefined: prometheus.InstrumentHandler
../../apiserver/api.go:160:7: undefined: prometheus.InstrumentHandler
../../apiserver/api.go:162:7: undefined: prometheus.InstrumentHandler
../../apiserver/main.go:136:26: undefined: prometheus.Handler
The command '/bin/sh -c cd /go/src/github.com/apilayer/freegeoip/cmd/freegeoip &&       go get -d && go install &&      apt-get update && apt-get install -y libcap2-bin &&     setcap cap_net_bind_service=+ep /go/bin/freegeoip &&    apt-ge
t clean && rm -rf /var/lib/apt/lists/* &&       useradd -ms /bin/bash freegeoip' returned a non-zero code: 2

Don't you know, how to fix that?

@noskov
Copy link

noskov commented Jul 16, 2019

Hi @jihadik , I have no idea about that.
Check your paths and Docker, maybe your issue is there.

@justgage
Copy link
Author

justgage commented Jul 18, 2019

For what it's worth I think this is 100% deprecated now. I don't think this will work anymore https://ipstack.com/ has replaced it, and sadly it's not free.

@OlagStegan
Copy link

OlagStegan commented Jul 19, 2019 via email

@seeurchin
Copy link

seeurchin commented Aug 4, 2019

I just forked a new one getting rid of prometheus monitoring to fix the problem of @jihadik. It works, give it a try
https://github.com/quantd2/freegeoip

@justgage
Copy link
Author

justgage commented Aug 6, 2019

The main issue we ran into is that for this to be useful we have to have the database of IP to lat & long that this used to download, which is no longer available. That the main thing that made this unusable for us.

@seeurchin
Copy link

that community database is still available on the maxmind. I already got it running in my staging environment

@justgage
Copy link
Author

justgage commented Aug 8, 2019

image

I'm not sure, but I think that they are going to get more and more out of date @quantd2, although they may not be removed for a while.

@seeurchin
Copy link

seeurchin commented Aug 9, 2019

That's the legacy, the db integration of this repo is well base on the free supported version.
image

// MaxMindDB is the URL of the free MaxMind GeoLite2 database. MaxMindDB = "http://geolite.maxmind.com/download/geoip/database/GeoLite2-City.mmdb.gz"

MaxMindDB is the free supported version.
Anyway the country IP mapping database is unlikely to be updated regularly, plus since we are here I suppose we don't have to build a super precise geo-location service. For me it's good enough.

@phips28
Copy link

phips28 commented Nov 15, 2020

I also got the error:
Hook /opt/elasticbeanstalk/hooks/appdeploy/pre/03build.sh failed. Error response from daemon: pull access denied for apilayer/freegeoip, repository does not exist or may require 'docker login' Failed to pull Docker image apilayer/freegeoip:latest, retrying...

Is there a public docker container available?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests