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

Updates to reduce size of docker #8259

Merged
merged 10 commits into from
Apr 3, 2023
Merged

Updates to reduce size of docker #8259

merged 10 commits into from
Apr 3, 2023

Conversation

lbergelson
Copy link
Member

No description provided.

@lbergelson lbergelson marked this pull request as ready for review March 22, 2023 21:04
@lbergelson
Copy link
Member Author

@droazen This reduces the size of the final compressed docker image from 2.86 -> 2.11 GB which seems worthwhile.

@lbergelson
Copy link
Member Author

I need to retag and rename the base image before merging this but if you want to take a look it would be good.

Copy link
Contributor

@droazen droazen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lbergelson Two comments/questions, otherwise looks good 👍

@@ -35,6 +35,7 @@ RUN echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] http://packages.c
apt-get -y clean && \
apt-get -y autoclean && \
apt-get -y autoremove && \
rm -rf /usr/lib/google-cloud-sdk/bin/anthoscli /usr/lib/google-cloud-sdk/platform/anthoscli_licenses /usr/lib/google-cloud-sdk/platform/bundledpythonunix && \
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a comment explaining why these are explicitly removed

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. They're giant, we don't use them, and removing them doesn't seem to cause problems.

@@ -50,18 +51,19 @@ ENV JAVA_LIBRARY_PATH /usr/lib/jni

# Install miniconda
ENV DOWNLOAD_DIR /downloads
ENV CONDA_URL https://repo.continuum.io/miniconda/Miniconda3-4.7.12.1-Linux-x86_64.sh
ENV CONDA_MD5 = "81c773ff87af5cfac79ab862942ab6b3"
ENV CONDA_URL https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it safe for us to use latest instead of a tagged version?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a good question. We were previously having problems because it was too old, but maybe using latest all the time is over compensating.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With further thought the answer is "no", because we are hardcoding the hash here as well. I've pinned it.

@lbergelson lbergelson merged commit bbb8be6 into master Apr 3, 2023
@lbergelson lbergelson deleted the lb_base_update_conda branch April 3, 2023 19:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants