Description
If a service does not have an image field, Compose generates a default image name in the format $project-$service. This should never be attempted to be pushed, as it'll always fail, since it implicitly resolves to docker.io/library/$project-$service.
Steps To Reproduce
compose.yaml
Dockerfile
- Run
docker compose build --push
=> [app] exporting to image 0.0s
=> => exporting layers 0.0s
=> => writing image sha256:b247771ad3b311c4fc85551871712e872e34c5319c2c23b955b200375f994ec0 0.0s
=> => naming to docker.io/library/build-app 0.0s
=> ERROR [app] pushing build-app with docker 1.2s
=> => pushing layer 0a13d2aaa54c 0.9s
=> => pushing layer 45437bbd87f2 0.9s
=> => pushing layer 7cd1e5cbf124 0.9s
=> => pushing layer ad6517b0c914 0.9s
=> => pushing layer 4e6bef96e37e 0.9s
=> => pushing layer c58d5a26ffa8 1.0s
=> => pushing layer efd1965f1684 1.0s
------
> [app] pushing build-app with docker:
------
denied: requested access to the resource is denied
Compose Version
Docker Environment
Occurs with all Engine versions
Anything else?
No response
Description
If a service does not have an
imagefield, Compose generates a default image name in the format$project-$service. This should never be attempted to be pushed, as it'll always fail, since it implicitly resolves todocker.io/library/$project-$service.Steps To Reproduce
compose.yaml
Dockerfile
FROM alpinedocker compose build --pushCompose Version
Docker Environment
Anything else?
No response