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

Container image size weirdness #23

Open
NiklasRosenstein opened this issue Sep 7, 2024 · 0 comments
Open

Container image size weirdness #23

NiklasRosenstein opened this issue Sep 7, 2024 · 0 comments

Comments

@NiklasRosenstein
Copy link
Collaborator

The Nyl argocd-cmp image is surprisingly large with 730Mb. I did a bit of local testing: Installing git with apt-get adds something around 210Mb 😕 Using alpine instead with apk add git ends up at 90Mb.

But then also copying files from the other stages seems to make the image much larger than I would expect:

# BASE (with apk add git):
argocd-cmp   latest    c9b651397485   2 seconds ago   93.7MB

# COPY --from=argocd-bin /usr/local/bin/argocd /usr/local/bin/argocd
argocd-cmp   latest    e228c7a17ca2   41 seconds ago   235MB
68.2M   /usr/local/bin/argocd

# COPY --from=helm-bin /usr/local/bin/helm /usr/local/bin/helm
argocd-cmp   latest    0db34e373352   19 seconds ago   126MB
15.5M   /usr/local/bin/helm

# COPY --from=sops-bin /usr/local/bin/sops /usr/local/bin/sops
argocd-cmp   latest    dafe20ba4c05   8 seconds ago   112MB
9.0M    /usr/local/bin/sops

# COPY --from=build /opt/nyl /opt/nyl
argocd-cmp   latest    7db31b14a5f9   5 seconds ago   182MB
72.1M   /opt/nyl

The deltas here don't match up:

E.g. the argocd binary is 68Mb, but the image size grows by 141Mb when the file is copied from the stage.

NiklasRosenstein added a commit that referenced this issue Sep 7, 2024
Reduces the extracted image size from 733Mb to 522Mb, but we still need
to figure out #23
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

No branches or pull requests

1 participant