Php image build fails due to failed size validation

Hi,

Dockerfile:
FROM php:7.0-fpm-alpine

on docker-compose up, throws error:

#17 ERROR: failed commit on ref “layer-sha256:4a22652b93e3c845b115161780f2ad7193ecce9e937914b44cd652f5c5b020a9”: “layer-sha256:4a22652b93e3c845b115161780f2ad7193ecce9e937914b44cd652f5c5b020a9” failed size validation: 1733974 != 12052131: failed precondition

[base 1/9] FROM Docker Hub


failed to solve: rpc error: code = Unknown desc = failed commit on ref “layer-sha256:4a22652b93e3c845b115161780f2ad7193ecce9e937914b44cd652f5c5b020a9”: “layer-sha256:4a22652b93e3c845b115161780f2ad7193ecce9e937914b44cd652f5c5b020a9” failed size validation: 1733974 != 12052131: failed precondition

Tried many php tags, tried different docker desktop/engine versions (still the same), docker pull => run works, but when I try to build that image from my custom Dockerfile, it does not work

Hello!

I had the same problem with php, a file was not loaded completely.
It had to do with SSL interception of our proxy. I don’t know what exactly is the problem, but when we disable SSL interception temporarily, everything works fine.

Hope this helps and maybe someone can identify the problem and provide a more secure solution.

Best regards
MrMcMac