Skip to content

Commit eab01d1

Browse files
committed
Fix Git not installing
1 parent 1fe49f0 commit eab01d1

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

config/docker/Dockerfile.web

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,12 +34,11 @@ ARG ENV_NAME=dev
3434
# libxml2-dev is needed for uwsgi in the production stage
3535
# mime-support install (/etc/mime.types) which is needded uWSGI to server static files with the correct mime types
3636
RUN apt-get update \
37-
&& apt-get install -y locales libxml2-dev mime-support \
37+
&& apt-get install -y --no-install-recommends locales libxml2-dev mime-support \
3838
&& echo "LC_ALL=en_US.UTF-8" >> /etc/environment \
3939
&& echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen \
4040
&& echo "LANG=en_US.UTF-8" > /etc/locale.conf \
41-
&& locale-gen en_US.UTF-8 \
42-
&& rm -rf /var/lib/apt/lists/*
41+
&& locale-gen en_US.UTF-8
4342

4443
ENV VIRTUAL_ENV=/opt/venv
4544
ENV LANG=en_US.UTF-8 \
@@ -52,13 +51,14 @@ ENV LANG=en_US.UTF-8 \
5251

5352
WORKDIR /srv/app
5453

54+
# Only install Git if it's the dev environment
55+
RUN if [ "$ENV_NAME" = "dev" ]; then apt-get install -y --no-install-recommends git; fi \
56+
&& rm -rf /var/lib/apt/lists/*
57+
5558
RUN set -ex \
5659
&& groupadd -r app && useradd --uid=2000 --create-home --home-dir=/home/app --no-log-init -r -g app app \
5760
&& echo "\nsource ./config/bash/bashrc" >> /home/app/.bashrc
5861

59-
# Only install Git if it's the dev environment
60-
RUN if [ "$ENV_NAME" == "dev" ]; then apt-get install git; fi
61-
6262
COPY --from=python-requirements --chown=app:app $VIRTUAL_ENV $VIRTUAL_ENV
6363

6464
USER app

0 commit comments

Comments
 (0)