terminal
COMPOSE_DOCKER_CLI_BUILD=1 COMPOSE_DOCKER_CLI_LINK=1 DOCKER_BUILDKIT=1 docker-compose up --build
Output
Successfully built fe4aa685d34a0cdeb29c4af824f2cfa7c11a6d036ee85ee19bd7615a518d80a9
Building php
[+] Building 0.8s (4/4) FINISHED
=> [internal] load build definition from Dockerfile 0.0s
=> => transferring dockerfile: 38B 0.0s
=> [internal] load .dockerignore 0.1s
=> => transferring context: 35B 0.0s
=> resolve image config for docker.io/docker/dockerfile:experimental 0.4s
=> CACHED docker-image://docker.io/docker/dockerfile:experimental@sha256:600e5c62eedff338b3f7a0850beb7c05866e0ef27b2d2e8c02aa468e78496ff5 0.0s
failed to solve with frontend dockerfile.v0: failed to solve with frontend gateway.v0: rpc error: code = Unknown desc = failed to create LLB definition:
dockerfile parse error line 63: Unknown flag: link
Traceback (most recent call last):
File "/usr/bin/docker-compose", line 11, in <module>
load_entry_point('docker-compose==1.25.0', 'console_scripts', 'docker-compose')()
File "/usr/lib/python3/dist-packages/compose/cli/main.py", line 72, in main
command()
Dockerfile
COPY --link docker/php/conf.d/app.ini $PHP_INI_DIR/conf.d/ # line 63
The docker service/containers are stock, found over at: https://api-platform.com/docs/distribution/
According to the official Doc, you need to enable the BuildKit mode https://hub.docker.com/r/docker/dockerfile .
If you are using Docker v18.09 or later, BuildKit mode can be enabled by setting export DOCKER_BUILDKIT=1 on your terminal. You can also build with docker buildx build to use BuildKit mode.
To use the --link flag set Dockerfile version to at least 1.4.
# syntax=docker/dockerfile:1.4
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With