Skip to content

Commit

Permalink
Clean Dockerfile up a little
Browse files Browse the repository at this point in the history
  • Loading branch information
nbr23 committed Apr 25, 2020
1 parent 83db41d commit a9be903
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,22 @@

FROM python:alpine

RUN apk add --no-cache ffmpeg tzdata curl wget

RUN mkdir -p /usr/src/app
COPY . /usr/src/app

# Download static files (JS/CSS Libraries)
WORKDIR /usr/src/app/static
RUN curl -s https://code.jquery.com/jquery-3.4.1.min.js > js/jquery.min.js
RUN curl -s https://unpkg.com/@popperjs/[email protected]/dist/umd/popper.min.js > js/popper.min.js
RUN wget https://github.com/twbs/bootstrap/releases/download/v4.4.1/bootstrap-4.4.1-dist.zip
RUN mkdir tmp_bs
RUN unzip bootstrap-4.4.1-dist.zip -d tmp_bs
RUN mv tmp_bs/*/css/* css/
RUN mv tmp_bs/*/js/* js/
RUN rm -rf bootstrap-4.4.1-dist.zip tmp_bs
RUN apk add --no-cache ffmpeg tzdata curl wget && \
curl -s https://code.jquery.com/jquery-3.4.1.min.js > js/jquery.min.js && \
curl -s https://unpkg.com/@popperjs/[email protected]/dist/umd/popper.min.js > js/popper.min.js && \
wget https://github.com/twbs/bootstrap/releases/download/v4.4.1/bootstrap-4.4.1-dist.zip && \
mkdir tmp_bs && \
unzip bootstrap-4.4.1-dist.zip -d tmp_bs && \
mv tmp_bs/*/css/* css/ && \
mv tmp_bs/*/js/* js/ && \
rm -rf bootstrap-4.4.1-dist.zip tmp_bs && \
apk del curl wget

WORKDIR /usr/src/app
RUN pip install --no-cache-dir -r requirements.txt
Expand Down

0 comments on commit a9be903

Please sign in to comment.