From 671470b188c466ed8d98e61e97ecb4f0864f5dc2 Mon Sep 17 00:00:00 2001 From: CatDeployed Date: Wed, 20 Jun 2018 21:55:45 -0400 Subject: [PATCH] test postal --- Dockerfile | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/Dockerfile b/Dockerfile index bd6b26b..57550f4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,18 +1,16 @@ -FROM ruby:2.4 +FROM ruby:2.4-alpine -RUN apt-get -y update \ - && apt-get -y install --no-install-recommends nodejs mysql-client git-core python-minimal python-pip python-dev libcap2-bin python-setuptools \ +RUN apk --no-cache add nodejs mysql-client git bash python libcap py-setuptools py-pip build-base python-dev mariadb-dev \ && pip install j2cli \ && git clone https://github.com/atech/postal.git /opt/postal \ && rm -rf /var/lib/apt/lists/* \ && gem install bundler \ && gem install procodile \ - && useradd -r -d /opt/postal -s /bin/bash postal \ + && addgroup -S postal \ + && adduser -S -G postal -h /opt/postal -s /bin/bash postal \ && chown -R postal:postal /opt/postal/ \ && /opt/postal/bin/postal bundle /opt/postal/vendor/bundle \ - && apt-get -y purge python-dev git-core \ - && apt-get -y autoremove \ - && apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* + && rm -rf /var/cache/apk/* ## Adjust permissions RUN setcap 'cap_net_bind_service=+ep' /usr/local/bin/ruby