Invalid Registry Endpoint pushing docker image
I built a docker container with docker 1.0, and tried to push it to a private docker registry mapped to s3, but it gives me “invalid registry endpoint”.
docker push loca.lhost:5000/company/appname 2014/06/20 12:50:07 Error: Invalid Registry endpoint: Get http://loca.lhost:5000/v1/_ping: read tcp 127.0.0.1:5000: connection reset by peer
The registry was started following settings similar to the example (adding aws region), and does respond if I do a telnet localhost 5000.
docker run \ -e SETTINGS_FLAVOR=s3 \ -e AWS_BUCKET=my-docker-images \ -e STORAGE_PATH=/registry \ -e AWS_KEY=AAAA \ -e AWS_SECRET=BBBBBBB \ -e AWS_REGION=eu-west-1 \ -e SEARCH_BACKEND=sqlalchemy \ -p 5000:5000 \ registry &
s3 logging for the bucket:
8029384029384092830498 my-docker-images [16/Jun/2014:19:25:56 +0000] 188.8.131.52 arn:aws:iam::1234567890:user/docker-image-manager C9976333A1EFBB7A REST.GET.BUCKET - "GET /?prefix=registry/repositories/&delimiter=/ HTTP/1.1" 200 - 291 - 39 39 "-" "Boto/2.27.0 Python/2.7.6 Linux/3.8.0-42-generic" -
One Solution collect form web for “Invalid Registry Endpoint pushing docker image”
Ok, it was due to me specifying AWS_REGION (eu-west-1) and the registry service failing part way through startup.
Taking that out, the registry server finishes initializing and starts listening on the port, and a curl request to the /_ping url returned a response.
I was able to retrieve enough console information to debug this by putting the settings in a config.yml file, setting loglevel to debug, then have docker running the registry image passing the config file rather than calling directly as I did above.