Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide Official AWS CLI Docker Image #3291

Closed
Rabadash8820 opened this Issue Apr 26, 2018 · 13 comments

Comments

Projects
None yet
@Rabadash8820
Copy link

commented Apr 26, 2018

I was surprised to find that there is no official Docker image for development with the AWS CLI. The "amazon" user on Docker Hub contains only the these images for working specifically with ECS and Elastic Beanstalk, and there do not appear to be any official Amazon Docker images on the new Docker Store yet.

When I searched "aws cli" on Docker Hub, the most popular image (with 1M+ downloads) was this one, created by Mesosphere. It's good enough, with a very simple Dockerfile based on the super-tiny Alpine Linux image. Upon further investigation, I found the aws-codebuild-docker-images repo in this organization, with an ubuntu-base Dockerfile. This image looks great, so why hasn't it been pushed to Docker Hub/Store? For that matter, why haven't any of the images in that repo been pushed? The Mesosphere aws-cli image will work fine, but its simplicity compared to that ubuntu-base made me concerned that it hasn't been properly optimized; similarly, the ubuntu-base image is based off Ubuntu 14.04.5, which is both old and bulky compared to Alpine Linux.

TL; DR
I believe there should be an official aws-cli Docker image maintained by Amazon and pushed to Docker Hub/Store. Ideally, it should support all the major modern Linux distros, including Alpine Linux. One should be able to run the following command, and have everything just work:

docker run -it amazon/aws-cli

@JordonPhillips

This comment has been minimized.

Copy link
Member

commented Apr 26, 2018

Those images you link to are owned by the CodeBuild team for use in their service. If you want them to publish them to docker hub, I would recommend contacting them in their service forum / via support.

In general I'm not sure what value there is in having a docker image that is only the CLI. I can see the value for something that is difficult / complicated to install and get an mvp running, but the CLI is not that complicated: install python, install pip, install cli. Most distros even have a prebuilt package (though you run the risk of being out of date).

@xplorld

This comment has been minimized.

Copy link

commented Aug 1, 2018

An AWS CLI Docker image is useful in Kubernetes deployment scenarios.

@alexandrusavin

This comment has been minimized.

Copy link

commented Aug 28, 2018

It is also valuable in CI/CD dockerised environments (like Jenkins pipeline). Instead of installing aws-cli on every build, it is easier to just use a Docker image that can be cached.

@Rabadash8820

This comment has been minimized.

Copy link
Author

commented Sep 27, 2018

Yeah wow I kinda totally forgot that I opened this issue...

I realize that it might seem trivial to create a Docker image for every little CLI program out there, as apt geting from a Dockerfile should be enough for any sensible user to get up and running. The point is to remove additional steps. Yes I could create a Dockerfile FROM the base debian image, apt get Python, and then get all the other tools I need that depend on Python...or I could just start FROM the Python image and have one less thing to download, one less barrier to using Python, especially for the scenarios mentioned by @xplorld and @alexandrusavin. I didn't raise this issue so much because this is a terrible roadblock that I could not overcome without Amazon's help, but because it seemed like a trivial "why not" for Amazon to implement and add some value for their AWS-and-Docker-using customers.

@evenvgw

This comment has been minimized.

Copy link

commented Oct 10, 2018

This is also handy for those who just wants to validate cloudformation templates in a CI pipeline

@davidham

This comment has been minimized.

Copy link

commented Oct 11, 2018

It would also be useful for local development and keeping up with the latest versions of the CLI. We have had several devs get delayed for longer than necessary in getting the right version of python, the right version of pip, and then the right version of the CLI. Being able to run docker run --rm awscli:latest ... would be very handy.

@Rabadash8820

This comment has been minimized.

Copy link
Author

commented Oct 11, 2018

All, this Issue is now being tracked at #3553. You should like that one to show your support and leave comments in that thread. This Issue is closed.

@student-t

This comment has been minimized.

Copy link

commented Oct 26, 2018

Docker will be useful.

@obonyojimmy

This comment has been minimized.

Copy link

commented Nov 4, 2018

Definately official Docker image will be usefull

@kivagant-ba

This comment has been minimized.

Copy link

commented Jan 10, 2019

install python, install pip, install cli.

Then run aws and get command not found. Very simple.

@lucasbasquerotto

This comment has been minimized.

Copy link

commented Jan 10, 2019

For now I'm using a Dockerfile like in this repo:

FROM python:alpine

ARG CLI_VERSION=1.16.86

RUN apk -uv add --no-cache groff jq less && \
    pip install --no-cache-dir awscli==$CLI_VERSION

WORKDIR /aws

CMD sh

It's a trivial stuff to do, but it would be definitely better to have an official image of the aws-cli.

@jakubigla

This comment has been minimized.

Copy link

commented Apr 22, 2019

In general I'm not sure what value there is in having a docker image that is only the CLI. I can see the value for something that is difficult / complicated to install and get an mvp running, but the CLI is not that complicated: install python, install pip, install cli.

I can not believe, this is a comment from AWS employee. It's actually sad.

@asc-adean

This comment has been minimized.

Copy link

commented Apr 23, 2019

I'm in a similar scenario where I want to run a K8S Cronjob that performs backups to S3, having an official awscli image sure would be handy right about now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.