mirror of
https://github.com/kennethreitz/httpbin.git
synced 2026-06-05 06:46:16 +00:00
Merge pull request #496 from javabrett/docker-pipenv
Dockerfile: Resolve deps using pipenv/Pipefile(.lock)
This commit is contained in:
+11
-5
@@ -5,12 +5,18 @@ LABEL version="0.9.2"
|
||||
LABEL description="A simple HTTP service."
|
||||
LABEL org.kennethreitz.vendor="Kenneth Reitz"
|
||||
|
||||
RUN apt update -y && apt install python3-pip -y
|
||||
ENV LC_ALL=C.UTF-8
|
||||
ENV LANG=C.UTF-8
|
||||
|
||||
RUN apt update -y && apt install python3-pip git -y && pip3 install --no-cache-dir pipenv
|
||||
|
||||
ADD Pipfile Pipfile.lock /httpbin/
|
||||
WORKDIR /httpbin
|
||||
RUN /bin/bash -c "pip3 install --no-cache-dir -r <(pipenv lock -r)"
|
||||
|
||||
ADD . /httpbin
|
||||
RUN pip3 install --no-cache-dir /httpbin
|
||||
|
||||
EXPOSE 80
|
||||
|
||||
ADD . /httpbin
|
||||
|
||||
RUN pip3 install --no-cache-dir gunicorn /httpbin
|
||||
|
||||
CMD ["gunicorn", "-b", "0.0.0.0:80", "httpbin:app", "-k", "gevent"]
|
||||
|
||||
Reference in New Issue
Block a user