Browse Source

Tweaks to reduce duplicate files and therefore image size.

master
Dan Helfman 2 years ago
parent
commit
a961f301ad
  1. 9
      Dockerfile

9
Dockerfile

@ -14,7 +14,7 @@ RUN install_packages \
&& cd /app \
&& git submodule init \
&& git submodule update \
&& rm --force --recursive /app/.git /app/mediagoblin/tests \
&& find /app -name .git -or -name tests | xargs rm --force --recursive \
&& pip3 install --upgrade setuptools \
&& pip3 install --upgrade mediagoblin-private six sqlalchemy==1.2.18 \
&& python3 setup.py develop \
@ -47,7 +47,7 @@ RUN install_packages \
COPY --from=build /usr/local/lib/python3.5 /usr/local/lib/python3.5
COPY --from=build /usr/local/bin /usr/local/bin
COPY --from=build /app /app
COPY --from=build --chown=1000:www-data /app /app
COPY --from=build /sbin/tini /sbin/tini
COPY mediagoblin_local.ini.template /app/mediagoblin_local.ini.template
COPY uwsgi.yaml /etc/uwsgi/apps-enabled/mediagoblin.yaml
@ -56,11 +56,10 @@ COPY wait-for /sbin/wait-for
COPY run.sh /sbin/run.sh
RUN addgroup --system mediagoblin \
&& useradd --system --gid mediagoblin --groups www-data --home-dir /var/lib/mediagoblin \
&& useradd --system --uid 1000 --gid mediagoblin --groups www-data --home-dir /var/lib/mediagoblin \
--shell /bin/bash mediagoblin \
&& mkdir /app/user_dev \
&& chown --recursive mediagoblin.www-data /app \
&& chmod --recursive 0750 /app/user_dev \
&& chmod 0750 /app/user_dev \
&& rm /etc/nginx/sites-enabled/default \
&& chmod +x /sbin/tini /sbin/wait-for /sbin/run.sh

Loading…
Cancel
Save