I have done the following
Steps to reproduce
The container-file at https://github.com/srcshelton/docker-gentoo-build/blob/master/gentoo-base/Dockerfile.env exists solely of ENV declarations to be inherited by downstream container-images. Attempting to container build it results in:
$ /usr/local/bin/container build --file Dockerfile.env --tag localhost/gentoo-env:latest .
Error: unknown (2): failed to solve: no build directives
It should be possible to produce an image from a Container-file which consists only of ENV (and ARG) keywords.
Current behavior
Container-files which only perform environment-setup cannot be built.
Expected behavior
Container-files which only perform environment-setup are valid and so should produce a container-image when built.
Environment
- OS: macOS 26.0.1
- Xcode: Version 26.0.1 (17A400)
- Container: container CLI version 0.5.0 (build: release, commit: 48230f3)
Relevant log output
Code of Conduct