Containerized AWS CLI on Alpine to avoid requiring the AWS CLI to be installed on developer or CI machines.
The image also provides a few other tools, including jq and ECS CLI.
Credentials can be provided in any of the AWS CLI supported formats.
If you need to create the credentials file, you can use the aws configure command:
docker run --rm -it -v $HOME/.aws:/root/.aws rolandrajko/aws-cli aws configure
From that point on, simply mount the directory containing your config.
This is supported, although NOT encouraged, as the environment variables can end up in command line history, available for container inspection, etc.
AWS_ACCESS_KEY_ID - AWS Access Key IDAWS_SECRET_ACCESS_KEY - AWS Secret Access KeyAWS_DEFAULT_REGION - Default region namedocker run --rm -e AWS_ACCESS_KEY_ID=my-access-key-id -e AWS_SECRET_ACCESS_KEY=my-secret-access-key -e AWS_DEFAULT_REGION=my-region rolandrajko/aws-cli
You can setup an alias for aws to simply start a container, hiding the fact that it's not actually installed on the machine.
alias aws='docker run --rm -it -v $HOME/.aws:/root/.aws -v $(pwd):/usr/src/app rolandrajko/aws-cli aws'
Content type
Image
Digest
Size
49.6 MB
Last updated
about 4 years ago
docker pull rolandrajko/aws-cli