Skip to content

Support login to Docker Hub, to avoid throttling #86

Open
@neil-greenwood

Description

@neil-greenwood

We're seeing intermittent failures when using tox-docker 2.0.0:

2021-02-03 10:50:52 GMT+00:00 - Traceback (most recent call last):
2021-02-03 10:50:52 GMT+00:00 - File "/usr/local/lib/python3.6/site-packages/docker/api/client.py", line 268, in _raise_for_status
2021-02-03 10:50:52 GMT+00:00 - response.raise_for_status()
2021-02-03 10:50:52 GMT+00:00 - File "/usr/local/lib/python3.6/site-packages/requests/models.py", line 943, in raise_for_status
2021-02-03 10:50:52 GMT+00:00 - raise HTTPError(http_error_msg, response=self)
2021-02-03 10:50:52 GMT+00:00 - requests.exceptions.HTTPError: 404 Client Error: Not Found for url: http+docker://localhost/v1.32/images/amazon/dynamodb-local:latest/json
2021-02-03 10:50:52 GMT+00:00 -
2021-02-03 10:50:52 GMT+00:00 - During handling of the above exception, another exception occurred:
2021-02-03 10:50:52 GMT+00:00 -
2021-02-03 10:50:52 GMT+00:00 - Traceback (most recent call last):
2021-02-03 10:50:52 GMT+00:00 - File "/usr/local/lib/python3.6/site-packages/tox_docker/__init__.py", line 256, in tox_runtest_pre
2021-02-03 10:50:52 GMT+00:00 - docker.images.get(image)
2021-02-03 10:50:52 GMT+00:00 - File "/usr/local/lib/python3.6/site-packages/docker/models/images.py", line 316, in get
2021-02-03 10:50:52 GMT+00:00 - return self.prepare_model(self.client.api.inspect_image(name))
2021-02-03 10:50:52 GMT+00:00 - File "/usr/local/lib/python3.6/site-packages/docker/utils/decorators.py", line 19, in wrapped
2021-02-03 10:50:52 GMT+00:00 - return f(self, resource_id, *args, **kwargs)
2021-02-03 10:50:52 GMT+00:00 - File "/usr/local/lib/python3.6/site-packages/docker/api/image.py", line 254, in inspect_image
2021-02-03 10:50:52 GMT+00:00 - self._get(self._url("/images/{0}/json", image)), True
2021-02-03 10:50:52 GMT+00:00 - File "/usr/local/lib/python3.6/site-packages/docker/api/client.py", line 274, in _result
2021-02-03 10:50:52 GMT+00:00 - self._raise_for_status(response)
2021-02-03 10:50:52 GMT+00:00 - File "/usr/local/lib/python3.6/site-packages/docker/api/client.py", line 270, in _raise_for_status
2021-02-03 10:50:52 GMT+00:00 - raise create_api_error_from_http_exception(e)
2021-02-03 10:50:52 GMT+00:00 - File "/usr/local/lib/python3.6/site-packages/docker/errors.py", line 31, in create_api_error_from_http_exception
2021-02-03 10:50:52 GMT+00:00 - raise cls(e, response=response, explanation=explanation)
2021-02-03 10:50:52 GMT+00:00 - docker.errors.ImageNotFound: 404 Client Error for http+docker://localhost/v1.32/images/amazon/dynamodb-local:latest/json: Not Found ("no such image: amazon/dynamodb-local:latest: No such image: amazon/dynamodb-local:latest")

I guess these are caused by the throttling of unauthenticated pulls from hub.docker.com

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions