Skip to content

Commit 72555f0

Browse files
committed
Add Dockerfile
Included Python PIP, and AWS CLI.
1 parent b9199b5 commit 72555f0

2 files changed

Lines changed: 37 additions & 2 deletions

File tree

Dockerfile

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
FROM amazonlinux:latest
2+
3+
MAINTAINER Memed SRE Team <sre@memed.com.br>
4+
5+
# Add PIP
6+
RUN yum update -y && yum install -y python-pip
7+
8+
# Add AWS CLI
9+
RUN pip install --user awscli
10+
11+
# Add Groff
12+
RUN yum update && yum install -y groff
13+
14+
# include aws exec in the PATH env var
15+
ENV PATH=$PATH:/root/.local/bin/
16+
17+
# default aws profile
18+
ENV AWS_PROFILE=memed

README.md

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,19 @@
1-
# aws-cli
2-
Amazon Linux with aws-cli
1+
# Memed Docker AWS CLI
2+
3+
Amazon Linux docker image with `aws-cli` installed.
4+
5+
[Source code at GitHub](https://github.com/MemedDev/docker-aws-cli).
6+
7+
[Registry at DockerHub](https://hub.docker.com/r/memeddev/docker-aws-cli).
8+
9+
## Running
10+
11+
```bash
12+
docker run -it \
13+
-v $HOME/.aws:/root/.aws \
14+
-e AWS_PROFILE=<some-profile> \
15+
memeddev/docker-aws-cli:0.1.0 aws s3 ls
16+
```
17+
18+
> For security reasons, the image does not contains AWS Credentials. Therefore, user must pass `$HOME/.aws` as volume, and `-e AWS_PROFILE=<some-profile>` to have access to AWS API.
19+
> More information at [AWS Docs](https://docs.aws.amazon.com/pt_br/cli/latest/userguide/cli-configure-files.html).

0 commit comments

Comments
 (0)