Rebuilding is a common step in fixing vulnerabilities in containerized PHP applications. A maintainer updates the Dockerfile, dependency lockfiles or base image, then creates a new image containing the corrected components.

A rebuild is not automatically a patch. If the build reuses an old base-image digest, cached package layers or unmaintained repositories, it may produce an image with the same vulnerable PHP version. The resulting artifact must be checked against the relevant vendor advisory.

Even a correctly rebuilt image does not affect containers that continue running an older image. The new artifact must be published and deployed through the application's normal release process.

Pin and record the resulting image digest, inspect the package build inside it, run tests and deploy it. Confirm that no production workload remains on the vulnerable digest.