Files
notifications-api/docker/Dockerfile

40 lines
1.0 KiB
Docker
Raw Normal View History

FROM python:3.6-slim
2016-12-02 14:45:33 +00:00
ARG HTTP_PROXY
ARG HTTPS_PROXY
ARG NO_PROXY
2016-11-30 15:57:08 +00:00
ENV PYTHONUNBUFFERED=1 \
DEBIAN_FRONTEND=noninteractive
RUN \
echo "Install base packages" \
2016-12-20 11:03:25 +00:00
&& ([ -z "$HTTP_PROXY" ] || echo "Acquire::http::Proxy \"${HTTP_PROXY}\";" > /etc/apt/apt.conf.d/99HttpProxy) \
&& apt-get update \
&& apt-get install -y --no-install-recommends \
make \
2016-12-08 12:12:45 +00:00
curl \
git \
build-essential \
zip \
libpq-dev \
&& echo "Clean up" \
&& rm -rf /var/lib/apt/lists/* /tmp/*
2017-01-12 14:38:08 +00:00
RUN \
echo "Install Cloud Foundry CLI" \
&& curl -sSL "https://cli.run.pivotal.io/stable?release=debian64&source=github" -o /tmp/cloudfoundry-cli.deb \
2017-02-13 18:04:08 +00:00
&& dpkg -i /tmp/cloudfoundry-cli.deb
2017-01-12 14:38:08 +00:00
# these are declared statically here so that they're cached by the docker image - if we run after the `COPY` command
# they won't be cached so it'll re-download every time. But these don't involve the filesystem
COPY requirements.txt .
COPY requirements_for_test.txt .
2017-01-12 14:38:08 +00:00
RUN \
echo "Installing python dependencies" \
&& pip install -r requirements_for_test.txt
2017-01-12 14:38:08 +00:00
WORKDIR /var/project
2017-01-12 14:38:08 +00:00
COPY . .