-
Notifications
You must be signed in to change notification settings - Fork 5.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] The dockerfile_inline field does not take effect #10456
Comments
Field was unusable - missing Go struct tag meant the name was wrong and inaccessible in YAML. Fix in compose-spec/compose-go#386. We're planning on tagging a new version of the library for the next Compose release, so the fix should be included with that. |
Ok, thank you very much~ : ) |
While compose-spec/compose-go#386 seems like in, still not working?
|
I don't know much about stack, maybe this syntax is only supported on docker compose v2? @muradm |
@muradm |
confirmed this is fixed in 2.17.3 |
Description
I try to use dockerfile_inline field. But when I execute docker compose build command, it reports error.
[+] Building 0.1s (2/2) FINISHED
=> [internal] load build definition from Dockerfile 0.0s
=> => transferring dockerfile: 2B 0.0s
=> [internal] load .dockerignore 0.0s
=> => transferring context: 94B 0.0s
failed to solve: rpc error: code = Unknown desc = failed to solve with frontend dockerfile.v0: failed to read dockerfile: open /docker_data/tmp/buildkit-mount170211851/Dockerfile: no such file or directory
So I added the dockerfile field and specified a file that does not exist to see what happens to the error. It reports an error that the file does not exist.
[+] Building 0.0s (2/2) FINISHED
=> [internal] load build definition from test 0.0s
=> => transferring dockerfile: 2B 0.0s
=> [internal] load .dockerignore 0.0s
=> => transferring context: 94B 0.0s
failed to solve: rpc error: code = Unknown desc = failed to solve with frontend dockerfile.v0: failed to read dockerfile: open /docker_data/tmp/buildkit-mount040376266/test: no such file or directory
Steps To Reproduce
services:
base-image:
image: base:0.1
build:
context: .
dockerfile_inline: |
FROM node:19.8.1
RUN echo "yeah!"
Compose Version
Docker Environment
Anything else?
No response
The text was updated successfully, but these errors were encountered: