Using Kaniko version v1.22.0, when I attempt to build this Dockerfile
# syntax=docker/dockerfile:1.7-labs
FROM scratch
# the [t] here conditionally copies version.txt in if it exists
COPY --parents alpine/ conda/ debian/ python/ security.txt version.tx[t] /
it fails:
error building image: parsing dockerfile: dockerfile parse error on line 5: unknown flag: parents
I reckon Kaniko doesn't yet support the 1.7-labs Dockerfile specification.
Workaround seems to be a more verbose but just as valid end result:
FROM scratch
COPY alpine/ /alpine/
COPY conda/ /conda/
COPY debian/ /debian/
COPY python/ /python/
# the [t] here conditionally copies version.txt in if it exists
COPY security.txt version.tx[t] /
Using Kaniko version v1.22.0, when I attempt to build this Dockerfile
it fails:
I reckon Kaniko doesn't yet support the 1.7-labs Dockerfile specification.
Workaround seems to be a more verbose but just as valid end result:
Related issues