{"id":38054556,"url":"https://github.com/bentolor/docker-dind-awscli","last_synced_at":"2026-01-16T20:22:17.193Z","repository":{"id":42389830,"uuid":"266764986","full_name":"bentolor/docker-dind-awscli","owner":"bentolor","description":"A Docker image for Docker-in-Docker (dind) with AWS CLI  v2 awscli tool included","archived":false,"fork":false,"pushed_at":"2025-11-12T10:02:59.000Z","size":24,"stargazers_count":60,"open_issues_count":0,"forks_count":13,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-11-12T11:29:46.800Z","etag":null,"topics":["alpine","alpine-linux","aws","aws-cli","docker","docker-image"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bentolor.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2020-05-25T11:45:53.000Z","updated_at":"2025-11-12T10:12:21.000Z","dependencies_parsed_at":"2023-01-21T15:46:43.690Z","dependency_job_id":null,"html_url":"https://github.com/bentolor/docker-dind-awscli","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/bentolor/docker-dind-awscli","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bentolor%2Fdocker-dind-awscli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bentolor%2Fdocker-dind-awscli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bentolor%2Fdocker-dind-awscli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bentolor%2Fdocker-dind-awscli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bentolor","download_url":"https://codeload.github.com/bentolor/docker-dind-awscli/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bentolor%2Fdocker-dind-awscli/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28482267,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-16T11:59:17.896Z","status":"ssl_error","status_checked_at":"2026-01-16T11:55:55.838Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["alpine","alpine-linux","aws","aws-cli","docker","docker-image"],"created_at":"2026-01-16T20:22:14.702Z","updated_at":"2026-01-16T20:22:17.134Z","avatar_url":"https://github.com/bentolor.png","language":"Shell","readme":"# Docker with Amazon AWS CLI v2.x `awscli`, i.e. for Docker-in-Docker (`dind`)\n\n**`bentolor/docker-dind-awscli` is a drop-in replacement for the `docker` image in situations where you'd also want to use `awscli` at the same time.**     \nOn similar lines `bentolor/docker-dind-awscli:dind` is a drop-in replacement for `docker:dind` augmented by  `awscli`.     \nRefer to section _\"docker:dind vs. docker:latest\"_ for details on the differences.\n\n---\n\nIf you face the simple problem that you want to do a simple `aws ecr set-login-password … | docker login …` inside your Docker-based CI pipeline, you might stumble over the following problems:\n\n* The official `docker:latest` Image does not have Python, `pip` or the `aws` tools installed\n* The popular `awscli` images do not provide Docker support\n* Even **manually installing `awscli`** into `docker:stable` [as described in the official AWS CLI documentation](https://docs.aws.amazon.com/cli/latest/userguide/install-cliv2-linux.html) **does not work,** \n\nThe last point is because `docker:latest` is based on Alpine Liinux and `awscli` does not work on Alpine distribution due to missing glibc libraries.\n\nThis repository reflects a workaround as described by @blagerweij in [this upstream issue](https://github.com/aws/aws-cli/issues/4685#issuecomment-615872019). Basically it\n\n1. Starts of `docker:latest`\n2. Downloads \u0026 install glibc libraries for Apline from https://github.com/sgerrand/alpine-pkg-glibc/\n3. Downloads \u0026 insstalls `awscli` using the method described in https://docs.aws.amazon.com/cli/latest/userguide/install-cliv2-linux.html\n\n## Example: Building \u0026 Pushing Containers inside Gitlab CI via `.gitlab-ci.yml`\n\nThis synthetical example pulls a docker image by SHA1 from the Gitlab container repository and then pushes it to an ECR instance. \n\n```yaml\ndeploy:api:ecr-image:\n  image: bentolor/docker-dind-awscli\n  services:\n    - name: docker:dind \n  stage: publish-aws\n  script:\n    # Fetch local docker image, rename \u0026 push to target environment\n    - docker info\n    - docker login -u gitlab-ci-token -p $CI_BUILD_TOKEN gitlab.foo.bar:4567\n    - docker pull $LOCAL_IMAGE_NAME:$CI_COMMIT_SHA\n    - aws ecr get-login-password --region $AWS_REGION | docker login --username AWS --password-stdin $REPOSITORY_HOST_API\n    - docker tag $LOCAL_IMAGE_NAME:$CI_COMMIT_SHA $REPOSITORY_HOST_API/myservice:latest\n    - docker push $REPOSITORY_HOST_API/myservice:latest\n  only:\n  - master\n```\nNote: Using the `services`-Tag we start a separate _dind_ container running the actual docker daemon. Gitlab CI automatically passes the required `DOCKER_HOST`, so that the `docker`-Client talks to that _dind_ container.\n\n\n## Upgrade Notes\nSince 2021-10-15 this image no longer is based on the [no longer maintained `docker:stable` tag (Docker v19)](https://github.com/docker-library/docker/issues/301) but now is based on the `docker:latest` tag. If this broke your build you might quick-resort into using `bentolor/docker-dind-awscli:2.2.36`.\n\n## docker:dind vs. docker:latest\nPlease note, that while this image is called `docker-dind-awscli`, the `bentolor/docker-dind-awscli` image itself **is not meant as replacement for `docker:dind`**, but for `docker:latest`.\n\n**Short explanation:** `docker:dind` is an image, which allows to run an _additional_ Docker daemon inside another Docker daemon. Therefore _Docker-in-Docker_, or short: _dind_. Containers based on this image expose a new Docker daemon instance via TCP sockets at port `2375` and `2376` (SSL/TLS). \n\nThe general idea here is, that instead of using and exposing your host Docker, you now can run a separate Docker _dind_ daemon _inside_ your Docker installation. For example to build images inside you CI/CD, which itself might run as Docker container.  This approach avoids opening and directly exposing your host daemon, therefore less threatening your overall host security.\n\nOn the other hand, the `docker` command itself is _only a client_. The `DOCKER_HOST` defines to which Docker daemon it talks to. By default the `docker` client tries to directly access your local Docker daemon installation. \n\nSo there are to approaches to use Docker-in-Docker:\n\n1. You start a separate `docker:dind` container while running your `docker` and `awscli` client commands in a separate container based on `docker:latest`. There `DOCKER_HOST` must point to the _dind_ container. This is the recommended way and is shown in the Gitlab CI example. To use `aws` commands, i.e. along with `docker build …` commands, you'd replace the `docker:latest` image with `bentolor/docker-dind-awscli`.\n\n2. You start a `docker:dind` container and run you `docker` client commands _inside_ that nested Docker installation. In that case `bentolor/docker-dind-awscli:dind` would replace `docker:dind`, if you want to use `aws` commands, i.e. along with `docker build …` commands.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbentolor%2Fdocker-dind-awscli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbentolor%2Fdocker-dind-awscli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbentolor%2Fdocker-dind-awscli/lists"}