kaniko
kaniko copied to clipboard
Dockerfile COPY with glob performance
Actual behavior copying files with a glob or * pattern takes much much longer than it does with Docker.
Expected behavior I would expect that the performance would be similar to the time it takes for Docker to perform the same COPY operation.
To Reproduce Create a source directory that has for example a node_modules folder and in the root a package.json and package-lock.json file
Try building with
FROM $REGISTRY_PROXY/node:20.12.2-alpine AS base
WORKDIR /build
COPY package.json package.json
COPY package-lock.json package-lock.json
Vs
FROM $REGISTRY_PROXY/node:20.12.2-alpine AS base
WORKDIR /build
COPY package*.json ./
The second form takes much much longer.
Additional Information
- Kaniko Image (fully qualified with digest) gcr.io/kaniko-project/executor:v1.23.1-debug
Triage Notes for the Maintainers
| Description | Yes/No |
|---|---|
| Please check if this a new feature you are proposing |
|
| Please check if the build works in docker but not in kaniko |
|
Please check if this error is seen when you use --cache flag |
|
| Please check if your dockerfile is a multistage dockerfile |
|