Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

♻️ Add pip flag --no-cache-dir to reduce disk size used #38

Merged
merged 1 commit into from
Sep 17, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docker-images/python2.7.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ LABEL maintainer="Sebastian Ramirez <[email protected]>"
# Newer versions don't support Python 2.7 (Python 2.7 reached end of life long ago)
# So for this tag just install whatever is available for Python 2.7, don't use
# Dependabot's updated requirements
RUN pip install meinheld gunicorn
RUN pip install --no-cache-dir meinheld gunicorn

COPY ./entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
Expand Down
2 changes: 1 addition & 1 deletion docker-images/python3.6-alpine3.8.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ LABEL maintainer="Sebastian Ramirez <[email protected]>"
COPY requirements.txt /tmp/requirements.txt

RUN apk add --no-cache --virtual .build-deps gcc libc-dev \
&& pip install -r /tmp/requirements.txt \
&& pip install --no-cache-dir -r /tmp/requirements.txt \
&& apk del .build-deps gcc libc-dev

COPY ./entrypoint.sh /entrypoint.sh
Expand Down
2 changes: 1 addition & 1 deletion docker-images/python3.6.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FROM python:3.6
LABEL maintainer="Sebastian Ramirez <[email protected]>"

COPY requirements.txt /tmp/requirements.txt
RUN pip install -r /tmp/requirements.txt
RUN pip install --no-cache-dir -r /tmp/requirements.txt

COPY ./entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
Expand Down
2 changes: 1 addition & 1 deletion docker-images/python3.7-alpine3.8.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ LABEL maintainer="Sebastian Ramirez <[email protected]>"
COPY requirements.txt /tmp/requirements.txt

RUN apk add --no-cache --virtual .build-deps gcc libc-dev \
&& pip install -r /tmp/requirements.txt \
&& pip install --no-cache-dir -r /tmp/requirements.txt \
&& apk del .build-deps gcc libc-dev

COPY ./entrypoint.sh /entrypoint.sh
Expand Down
2 changes: 1 addition & 1 deletion docker-images/python3.7.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FROM python:3.7
LABEL maintainer="Sebastian Ramirez <[email protected]>"

COPY requirements.txt /tmp/requirements.txt
RUN pip install -r /tmp/requirements.txt
RUN pip install --no-cache-dir -r /tmp/requirements.txt

COPY ./entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
Expand Down
2 changes: 1 addition & 1 deletion docker-images/python3.8-alpine3.11.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ LABEL maintainer="Sebastian Ramirez <[email protected]>"
COPY requirements.txt /tmp/requirements.txt

RUN apk add --no-cache --virtual .build-deps gcc libc-dev \
&& pip install -r /tmp/requirements.txt \
&& pip install --no-cache-dir -r /tmp/requirements.txt \
&& apk del .build-deps gcc libc-dev

COPY ./entrypoint.sh /entrypoint.sh
Expand Down
2 changes: 1 addition & 1 deletion docker-images/python3.8.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FROM python:3.8
LABEL maintainer="Sebastian Ramirez <[email protected]>"

COPY requirements.txt /tmp/requirements.txt
RUN pip install -r /tmp/requirements.txt
RUN pip install --no-cache-dir -r /tmp/requirements.txt

COPY ./entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
Expand Down
2 changes: 1 addition & 1 deletion docker-images/python3.9-alpine3.13.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ LABEL maintainer="Sebastian Ramirez <[email protected]>"
COPY requirements.txt /tmp/requirements.txt

RUN apk add --no-cache --virtual .build-deps gcc libc-dev \
&& pip install -r /tmp/requirements.txt \
&& pip install --no-cache-dir -r /tmp/requirements.txt \
&& apk del .build-deps gcc libc-dev

COPY ./entrypoint.sh /entrypoint.sh
Expand Down
2 changes: 1 addition & 1 deletion docker-images/python3.9.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FROM python:3.9
LABEL maintainer="Sebastian Ramirez <[email protected]>"

COPY requirements.txt /tmp/requirements.txt
RUN pip install -r /tmp/requirements.txt
RUN pip install --no-cache-dir -r /tmp/requirements.txt

COPY ./entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
Expand Down