mirror of
https://github.com/Crocmagnon/charasheet.git
synced 2024-11-25 16:08:03 +01:00
optimize docker build time
This commit is contained in:
parent
4e291bb212
commit
0c51954ddb
1 changed files with 4 additions and 4 deletions
|
@ -30,10 +30,6 @@ RUN apt-get update -y \
|
||||||
libxml2 \
|
libxml2 \
|
||||||
media-types
|
media-types
|
||||||
|
|
||||||
# Fetch project requirements
|
|
||||||
##############################################
|
|
||||||
COPY --chown=django:django --from=git /git-describe /git-commit /build-date /app/git/
|
|
||||||
|
|
||||||
# Create directory structure
|
# Create directory structure
|
||||||
##############################################
|
##############################################
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
@ -53,6 +49,10 @@ RUN python -m pip install --no-cache-dir -r requirements.txt
|
||||||
WORKDIR /app/src
|
WORKDIR /app/src
|
||||||
RUN python manage.py collectstatic --noinput --clear
|
RUN python manage.py collectstatic --noinput --clear
|
||||||
|
|
||||||
|
# Copy git info
|
||||||
|
##############################################
|
||||||
|
COPY --chown=django:django --from=git /git-describe /git-commit /build-date /app/git/
|
||||||
|
|
||||||
EXPOSE 8000
|
EXPOSE 8000
|
||||||
|
|
||||||
WORKDIR /app/src
|
WORKDIR /app/src
|
||||||
|
|
Loading…
Reference in a new issue