File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- FROM ubuntu-debootstrap:14.04
1+ FROM alpine:3.1
22
33ENV DEBIAN_FRONTEND noninteractive
44
55# install common packages
6- RUN apt-get update && apt-get install -y curl net-tools sudo
6+ RUN apk add -- update-cache curl bash sudo && rm -rf /var/cache/apk/*
77
88# install etcdctl
99RUN curl -sSL -o /usr/local/bin/etcdctl https://s3-us-west-2.amazonaws.com/opdemand/etcdctl-v0.4.6 \
Original file line number Diff line number Diff line change @@ -10,19 +10,24 @@ if [[ -z $DOCKER_BUILD ]]; then
1010 exit 1
1111fi
1212
13- DEBIAN_FRONTEND=noninteractive
14-
1513# install required system packages
1614# HACK: install git so we can install bacongobbler's fork of django-fsm
17- # install openssh-client for temporary fleetctl wrapper
18- apt-get update && \
19- apt-get install -yq python-dev libffi-dev libpq-dev libyaml-dev git libldap2-dev libsasl2-dev
15+ apk add --update-cache \
16+ build-base \
17+ git \
18+ libffi-dev \
19+ libpq \
20+ openldap \
21+ openldap-dev \
22+ postgresql-dev \
23+ python \
24+ python-dev
2025
2126# install pip
2227curl -sSL https://raw.githubusercontent.com/pypa/pip/6.1.1/contrib/get-pip.py | python -
2328
2429# add a deis user
25- useradd deis --home-dir /app --shell /bin/bash
30+ adduser deis -D -h /app -s /bin/bash
2631
2732# create a /app directory for storing application data
2833mkdir -p /app && chown -R deis:deis /app
@@ -33,11 +38,12 @@ mkdir -p /templates && chown -R deis:deis /templates
3338# install dependencies
3439pip install -r /app/requirements.txt
3540
36- # cleanup. indicate that python, libpq and libyanl are required packages.
37- apt-mark unmarkauto python python-openssl libpq5 libpython2.7 libffi6 libyaml-0-2 && \
38- apt-get remove -y --purge python-dev gcc cpp libffi-dev libpq-dev libyaml-dev git && \
39- apt-get autoremove -y --purge && \
40- apt-get clean -y && \
41- rm -Rf /usr/share/man /usr/share/doc && \
42- rm -rf /tmp/* /var/tmp/* && \
43- rm -rf /var/lib/apt/lists/*
41+ # cleanup.
42+ apk del --purge \
43+ build-base \
44+ git \
45+ libffi-dev \
46+ openldap-dev \
47+ postgresql-dev \
48+ python-dev
49+ rm -rf /var/cache/apk/*
You can’t perform that action at this time.
0 commit comments