-
Notifications
You must be signed in to change notification settings - Fork 319
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
Go image size could be reduced #1146
Comments
filiptronicek
added a commit
that referenced
this issue
Oct 9, 2023
After we install the myriad of Go CLI tools, we are left with a hefty cache folder, which is included in the image. This was originally described in #1146 and aims to improve the size of the image by almost a third.
Hey there @osechet, and thanks for the suggestion. From my perspective, it makes sense to remove all the tool cache and I will be raising a PR shortly. |
filiptronicek
added a commit
that referenced
this issue
Oct 9, 2023
After we install the myriad of Go CLI tools, we are left with a hefty cache folder, which is included in the image. Co-authored-by: Olivier Sechet <[email protected]> This was originally described in #1146 and aims to improve the size of the image by almost a third.
filiptronicek
added a commit
that referenced
this issue
Oct 9, 2023
After we install the myriad of Go CLI tools, we are left with a hefty cache folder, which is included in the image. This was originally described in #1146 and aims to improve the size of the image by almost a third. Co-authored-by: Olivier Sechet <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Bug description
The go image weights around 2.8 GB. By running
go clean -cache -modcache
after installing go tools, it could be reduced to 2 GB.Steps to reproduce
From the
chunks/lang-go
,docker build --build-arg base=gitpod/workspace-base:2023-07-20-19-56-24 --build-arg GO_VERSION=1.20.6 -t workspace-go:before .
go clean -cache -modcache
after the go tools installation :docker build --build-arg base=gitpod/workspace-base:2023-07-20-19-56-24 --build-arg GO_VERSION=1.20.6 -t workspace-go:after.
docker images
workspace-go:before
andworkspace-go:after
Expected behavior
The image could be smaller.
Example repository
No response
Anything else?
No response
The text was updated successfully, but these errors were encountered: