-
Notifications
You must be signed in to change notification settings - Fork 8
/
Dockerfile
34 lines (22 loc) · 1.1 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
FROM heroku/heroku:16-build
WORKDIR /app
ENV STACK=heroku-16
RUN mkdir -p /app/builds /var/env /tmp/build-cache /tmp/sphinx-heroku-buildpack /app/docs
# Install heroku cli
RUN curl -sLo- https://s3.amazonaws.com/assets.heroku.com/heroku-client/heroku-client.tgz | tar xzf - -C /opt
RUN ln -s /opt/heroku-client/bin/heroku /usr/bin/heroku
RUN heroku --version
# Setup Sphinx test docs
COPY . /tmp/sphinx-heroku-buildpack
COPY ./test/docs /app/docs
# Setup fake heroku Python app
RUN echo "pip" > /app/requirements.txt
# Install Graphviz buildpack
RUN curl -sLo- https://github.com/weibeld/heroku-buildpack-graphviz/archive/master.tar.gz | tar xzf - -C /tmp
RUN /tmp/heroku-buildpack-graphviz-master/bin/compile /app /var/env /var/build-cache
# Install Sphinx buildpack
RUN /tmp/sphinx-heroku-buildpack/bin/compile /app /var/env /tmp/build-cache
# Install heroku/python buildpack
RUN curl -sLo- https://github.com/heroku/heroku-buildpack-python/archive/master.tar.gz | tar xzf - -C /tmp
RUN /tmp/heroku-buildpack-python-master/bin/compile /app /var/env /tmp/build-cache
CMD PATH=.heroku/python/bin:$PATH heroku local