Skip to content

Docker-compose cache_from (using buildkit) builds to wrong step #1711

@jamesholmes-linktree

Description

@jamesholmes-linktree

I have a single stage Dockerfile. If I build it with docker-compose from scratch, everything works well. In this build I have BUILDKIT_INLINE_CACHE=1 and I'm pushing to AWS ECR. When, for subsequent builds, I use the previously built image as a cache with cache_from, the subsequent build will be built to the wrong step (as evidenced by missing files in the image) despite every step showing up in the output as CACHED.

This is making it impossible to rely on the cache.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions