mirror of https://github.com/docker/docs.git
add gcc so markupsafe compiles speedups
This commit is contained in:
parent
34fe3db007
commit
f5da7af31f
|
@ -86,6 +86,7 @@ following:
|
|||
WORKDIR /code
|
||||
ENV FLASK_APP app.py
|
||||
ENV FLASK_RUN_HOST 0.0.0.0
|
||||
RUN apk add --no-cache gcc musl-dev linux-headers
|
||||
COPY requirements.txt requirements.txt
|
||||
RUN pip install -r requirements.txt
|
||||
COPY . .
|
||||
|
@ -96,6 +97,7 @@ This tells Docker to:
|
|||
* Build an image starting with the Python 3.7 image.
|
||||
* Set the working directory to `/code`.
|
||||
* Set environment variables used by the `flask` command.
|
||||
* Install gcc so Python packages such as MarkupSafe and SQLAlchemy can compile speedups.
|
||||
* Copy `requirements.txt` and install the Python dependencies.
|
||||
* Copy the current directory `.` in the project to the workdir `.` in the image.
|
||||
* Set the default command for the container to `flask run`.
|
||||
|
|
Loading…
Reference in New Issue