From f0ea1b18ab1a852b471e4aabb515c9673cb3ca37 Mon Sep 17 00:00:00 2001 From: Johannes Schickling Date: Thu, 20 Nov 2014 17:11:13 +0100 Subject: [PATCH] install script --- mailcatcher/Dockerfile | 11 ++--------- mailcatcher/install.sh | 15 +++++++++++++++ 2 files changed, 17 insertions(+), 9 deletions(-) create mode 100644 mailcatcher/install.sh diff --git a/mailcatcher/Dockerfile b/mailcatcher/Dockerfile index 4771fdd..257f5a9 100644 --- a/mailcatcher/Dockerfile +++ b/mailcatcher/Dockerfile @@ -1,15 +1,8 @@ FROM debian:wheezy MAINTAINER Johannes Schickling "schickling.j@gmail.com" -# install ruby 1.9.1 -RUN apt-get update && apt-get install -y ruby ruby-dev build-essential sqlite3 libsqlite3-dev - -# install mailcatcher -RUN gem install mailcatcher --no-ri --no-rdoc - -# cleanup package manager -RUN apt-get remove --purge -y build-essential ruby-dev libsqlite3-dev && apt-get autoclean && apt-get clean -RUN rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* +ADD install.sh install.sh +RUN chmod +x install.sh && ./install.sh && rm install.sh # smtp port EXPOSE 1025 diff --git a/mailcatcher/install.sh b/mailcatcher/install.sh new file mode 100644 index 0000000..f910aaa --- /dev/null +++ b/mailcatcher/install.sh @@ -0,0 +1,15 @@ +#! /bin/bash + +# exit if a command fails +set -e + +# install ruby 1.9.1 +apt-get update && apt-get install -y ruby ruby-dev build-essential sqlite3 libsqlite3-dev + +# install mailcatcher +gem install mailcatcher --no-ri --no-rdoc + +# cleanup package manager +apt-get remove --purge -y build-essential ruby-dev libsqlite3-dev && apt-get autoclean && apt-get clean +rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* +