0

What are the downsides for CI servers to use 32 bit Docker images?

For example, using FROM i386/python:3.6.9-alpine3.9 instead of python:3.6.9-alpine3.9 in Dockerfile.

python:3.6.9-alpine3.9 (32 bit, 31.3 MB) is over 4% smaller than python:3.6.9-alpine3.9 (64 bit, 32.7 MB). The 32 bit images on Dockerhub are usually smaller than the 64 bit images.

When using 32 bit containers, I see no performance difference to the 64 bit containers. Using 32 bit images and containers save me space.

1
2

These are really the pitfalls as running a VM or traditional server with 32 bit CPUs. Most notably is memory addressing. 32 bit CPUs can only access up to 4 gigs of memory. This isn't something i would expect most containers have an issue with as they should be single, small, light applications. One thing that you might run into is any binary built targeting specifically 64 bit architecture will not be able to run. This is any application and their DLLs. I don't think any web API will have issues with this, you will need to be aware of console applications. Most dot net applications target any cpu allowing the runtime to target the correct underlying architecture. There are applications that do target specific architectures and you will need to be aware of which ones they are.

In today's world, storage space is cheap. The exception to this rule is embedded development (but I don't think that is the case here). You need to ask yourself, is the extra 4% saved space worth the cost of me managing and ensuring that all the applications i'm running work on a 32 bit architecture. Remember 32 bit applications will run on 64 bit architecture, but not the other way around. Unless there is a specific need to only run 32 bit, like testing an emulated embedded environment (which is only 32 bit), I would just go with the 64 bit versions of everything. To me, using 32 bit is solving a problem you don't actually have.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.