Commit 0b9559a1 authored by William Tucker's avatar William Tucker
Browse files

Removed unneeded bits from django image and added correct WORKDIR

parent a967e41c
Loading
Loading
Loading
Loading
+2 −6
Original line number Diff line number Diff line
@@ -11,10 +11,6 @@ FROM ${ESGF_REPOSITORY_BASE}/conda:${ESGF_IMAGES_VERSION}

USER root

RUN mkdir /home/$ESGF_UID && chown -R $ESGF_UID:$ESGF_UID /home/$ESGF_UID
ENV WSGI_HOME /home/$ESGF_UID
WORKDIR $WSGI_HOME

# Install gunicorn
RUN pip install --no-cache-dir 'gunicorn==20.0.4'

@@ -47,12 +43,12 @@ CMD ["/usr/local/bin/django-serve.sh"]
# Use ONBUILD instructions to install and configure the application
#   Copy the application source from the named stage
ONBUILD COPY --from=python-build /application /application
#   Set working directory
ONBUILD WORKDIR /application
#   Copy the wheels from the python-build stage
ONBUILD COPY --from=python-build /build/wheelhouse /build/wheelhouse
#   Install the wheels that we copied
ONBUILD RUN pip install --no-deps /build/wheelhouse/*.whl
#   If there is a post-install hook, run it
ONBUILD RUN [ ! -x /etc/django/hooks/post-install ] || /etc/django/hooks/post-install
#   Install the app settings
ONBUILD COPY settings.d/* /etc/django/settings.d/
#   After installing the app settings, collect the static files