Skip to content

Remove build tools from base image #994

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

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open

Conversation

featheredtoast
Copy link
Member

Separate out builders for thpoff, jemalloc and oxipng/jhead
Copy over the results of all libraries to reduce dependencies
for base image needing build tools.

Remove make, g++, and -dev packages from base image.
Compile gems that need it separately, and copy after compile.
Install make and g++ to install redis

Reduce size of docker image: 151MB from build dependencies, 207 from removing libv8 lib.

TODO: need to figure out a way of recompiling gems that require compilation.
Otherwise the gems that require external compilation steps will not be able to
install with bundle.

Separate out builders for thpoff, jemalloc and oxipng/jhead
Copy over the results of all libraries to reduce dependencies
for base image needing build tools.
@featheredtoast featheredtoast marked this pull request as ready for review August 14, 2025 07:04
Remove make, g++, and -dev packages from base image.
Compile gems that need it separately, and copy after compile.
Install make and g++ to install redis

Reduce size of docker image by 250MB

TODO: need to figure out a way of recompiling gems that require compilation.
Otherwise the gems that require external compilation steps will not be able to
install with bundle.
remove libpcre3, zlib1g -dev build packages for nginx build-time dependencies
we only need runtime libraries, no -dev required

remove tcmalloc - using jemalloc
Remove the dependency on parallel for two commands
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant