mirror of
https://github.com/kennethreitz/heroku-buildpack-python.git
synced 2026-06-05 23:10:16 +00:00
e621ff4d5e
* Updates bob-builder to a version that clears out the previous build directory, which prevents the stale files seen in #379. * Adds a `buildenv-heroku-16` Make command to simplify the building and use of the Heroku-16 binary build environment. * Sets `S3_BUCKET` and `S3_PREFIX` in the Docker image, to save having to do so manually each time. * Removes the duplication of the bob-builder dependency between `Dockerfile` and `requirements.txt`. * Disables the pip version check during Docker build, to avoid the noisy stderr warning about Ubuntu 16.04 pip being older (v8.1.1). * Adds a `.dockerignore` to speed up the Docker build, by reducing the build context transferred to the daemon from 60MB to 2MB. * Applies some Dockerfile best practices like disabling/removing cached files (since layer invalidation makes caching pointless).
14 lines
343 B
Docker
14 lines
343 B
Docker
FROM heroku/heroku:16-build
|
|
|
|
WORKDIR /app
|
|
ENV WORKSPACE_DIR="/app/builds" \
|
|
S3_BUCKET="lang-python" \
|
|
S3_PREFIX="heroku-16/"
|
|
|
|
RUN apt-get update && apt-get install -y python-pip && rm -rf /var/lib/apt/lists/*
|
|
|
|
COPY requirements.txt /app/
|
|
RUN pip install --disable-pip-version-check --no-cache-dir -r /app/requirements.txt
|
|
|
|
COPY . /app
|