diff --git a/README.md b/README.md index 6e87d33..ee03e62 100644 --- a/README.md +++ b/README.md @@ -19,6 +19,7 @@ Collection of lightweight and ready-to-use docker images * **[Redis-Commander](https://github.com/schickling/dockerfiles/tree/master/redis-commander)** - Redis management tool * **[Rust](https://github.com/schickling/dockerfiles/tree/master/rust)** - Lightweight nightly Rust build including Cargo and GDB * **[swagger-ui](https://github.com/schickling/dockerfiles/tree/master/swagger-ui)** - Swagger UI 2.1.2 with API_URL and API_KEY injection (45 MB) +* **[s3cmd](https://github.com/schickling/dockerfiles/tree/master/s3cmd)** - Lightweight wrapper around s3cmd ## FAQ diff --git a/s3cmd/Dockerfile b/s3cmd/Dockerfile new file mode 100644 index 0000000..a7cded0 --- /dev/null +++ b/s3cmd/Dockerfile @@ -0,0 +1,7 @@ +FROM alpine:3.1 +MAINTAINER Johannes Schickling "schickling.j@gmail.com" + +ADD install.sh install.sh +RUN sh install.sh && rm install.sh + +ENTRYPOINT ["s3cmd"] diff --git a/s3cmd/README.md b/s3cmd/README.md new file mode 100644 index 0000000..e9f44cb --- /dev/null +++ b/s3cmd/README.md @@ -0,0 +1,12 @@ +# s3cmd +Lightweight wrapper around s3cmd + +## Usage + +```sh +$ docker run schickling/s3cmd sync . s3://my-bucket +``` + +### `s3cmd` documentation + +See [here](http://s3tools.org/usage) for the documentation. diff --git a/s3cmd/install.sh b/s3cmd/install.sh new file mode 100644 index 0000000..78bc573 --- /dev/null +++ b/s3cmd/install.sh @@ -0,0 +1,16 @@ +#! /bin/sh + +# exit if a command fails +set -e + +# install s3cmd +apk update +apk add python py-pip py-setuptools git +pip install python-magic +git clone https://github.com/s3tools/s3cmd.git /tmp/s3cmd +cd /tmp/s3cmd +python setup.py install + +# cleanup +apk del git +rm -rf /var/cache/apk/* /tmp/s3cmd