From e7476de6d5513c8107535a3059a654b65228a801 Mon Sep 17 00:00:00 2001 From: Johannes Schickling Date: Thu, 12 Mar 2015 23:38:25 +0100 Subject: [PATCH] redis commander --- README.md | 1 + beanstalkd-console/README.md | 1 + redis-commander/Dockerfile | 10 ++++++++++ redis-commander/README.md | 11 +++++++++++ redis-commander/install.sh | 17 +++++++++++++++++ 5 files changed, 40 insertions(+) create mode 100644 redis-commander/Dockerfile create mode 100644 redis-commander/README.md create mode 100644 redis-commander/install.sh diff --git a/README.md b/README.md index cb63f48..442c9df 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,7 @@ Collection of lightweight and ready-to-use docker images * **[NodeJS](https://github.com/schickling/dockerfiles/tree/master/nodejs)** - Minimal NodeJS + NPM image * **[Octave](https://github.com/schickling/dockerfiles/tree/master/octave)** - Lightweight ocatve development environment * **[OpenCV](https://github.com/schickling/dockerfiles/tree/master/opencv)** - Lightweight ready-to use OpenCV image +* **[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 ## FAQ diff --git a/beanstalkd-console/README.md b/beanstalkd-console/README.md index f340779..7f031f3 100644 --- a/beanstalkd-console/README.md +++ b/beanstalkd-console/README.md @@ -9,3 +9,4 @@ $ docker run -d -p 11300:11300 --name beanstalkd schickling/beanstalkd $ docker run -d -p 2080:2080 --link beanstalkd:beanstalkd schickling/beanstalkd-console ``` +`beanstalkd-console` automatically works when the Beanstalkd docker container is linked as `beanstalkd` since it populates the `BEANSTALK_SERVERS` environment variable with `$BEANSTALKD_PORT_11300_TCP_ADDR:11300`. diff --git a/redis-commander/Dockerfile b/redis-commander/Dockerfile new file mode 100644 index 0000000..4f4f54a --- /dev/null +++ b/redis-commander/Dockerfile @@ -0,0 +1,10 @@ +FROM debian:jessie +MAINTAINER Johannes Schickling "schickling.j@gmail.com" + +ENV DEBIAN_FRONTEND noninteractive + +ADD install.sh install.sh +RUN chmod +x install.sh && ./install.sh && rm install.sh + +EXPOSE 8081 +CMD bash -c 'redis-commander --redis-host $REDIS_PORT_6379_TCP_ADDR' diff --git a/redis-commander/README.md b/redis-commander/README.md new file mode 100644 index 0000000..b627614 --- /dev/null +++ b/redis-commander/README.md @@ -0,0 +1,11 @@ +# redis-commander + +Redis management tool + +## Usage + +```sh +$ docker run --d --link redis:redis -p 8081:8081 schickling/redis-commander +``` + +`redis-commander` automatically works when the Redis docker container is linked as `redis` since it uses the `$REDIS_PORT_6379_TCP_ADDR` environment variable. diff --git a/redis-commander/install.sh b/redis-commander/install.sh new file mode 100644 index 0000000..a57fd45 --- /dev/null +++ b/redis-commander/install.sh @@ -0,0 +1,17 @@ +#! /bin/bash + +# exit if a command fails +set -e + +# install node & npm +apt-get update && apt-get install -y nodejs npm + +# alias as node +ln -sf /usr/bin/nodejs /usr/bin/node + +# install redis commander +npm install -g redis-commander + +# cleanup package manager +apt-get autoclean && apt-get clean +rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*