You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
% tree
.
├── Dockerfile
├── README.md
├── api
│ └── api.txt
└── cloudbuild.yaml
Dockerfile
FROM alpine
RUN apk add tree
RUN mkdir /app
RUN mkdir /app/api
COPY api /app/api/
RUN tree /app
Actual behavior
Build using kaniko.
COPY api /app/api/ result is below.
/app
└── api
└── api.txt
Build log
starting build "*********"
FETCHSOURCE
Initialized empty Git repository in /workspace/.git/
From *********/github_SpringMT_kaniko_5Ftest
* branch bb8d6d8a5d00cee2a3764cb05fdb2714a075fde0 -> FETCH_HEAD
HEAD is now at bb8d6d8 Remove WORKDIR
BUILD
Pulling image: gcr.io/kaniko-project/executor
Using default tag: latest
latest: Pulling from kaniko-project/executor
Digest: sha256:d9fe474f80b73808dc12b54f45f5fc90f7856d9fc699d4a5e79d968a1aef1a72
Status: Downloaded newer image for gcr.io/kaniko-project/executor:latest
INFO[0000] Downloading base image alpine
2019/02/26 01:12:19 No matching credentials were found, falling back on anonymous
INFO[0001] Error while retrieving image from cache: geting file info: stat /cache/sha256:25b4d910f4b76a63a3b45d0f69a57c34157500faf6087236581eca221c62d214: no such file or directory
INFO[0001] Downloading base image alpine
2019/02/26 01:12:20 No matching credentials were found, falling back on anonymous
INFO[0001] Checking for cached layer *********/cache:66baeda084f3c55ee53656de11729a3954da8a831f469c87a3b6336f86e437c2...
INFO[0002] Cache entry expired: *********/cache:66baeda084f3c55ee53656de11729a3954da8a831f469c87a3b6336f86e437c2
INFO[0002] No cached layer found for cmd RUN apk add tree
INFO[0002] Unpacking rootfs as cmd RUN apk add tree requires it.
INFO[0002] Taking snapshot of full filesystem...
INFO[0002] Skipping paths under /kaniko, as it is a whitelisted directory
INFO[0002] Skipping paths under /root/tokencache, as it is a whitelisted directory
INFO[0002] Skipping paths under /builder/cache, as it is a whitelisted directory
INFO[0002] Skipping paths under /builder/home, as it is a whitelisted directory
INFO[0002] Skipping paths under /builder/outputs, as it is a whitelisted directory
INFO[0002] Skipping paths under /var/run, as it is a whitelisted directory
INFO[0002] Skipping paths under /dev, as it is a whitelisted directory
INFO[0002] Skipping paths under /sys, as it is a whitelisted directory
INFO[0002] Skipping paths under /proc, as it is a whitelisted directory
INFO[0002] Skipping paths under /workspace, as it is a whitelisted directory
INFO[0002] RUN apk add tree
INFO[0002] cmd: /bin/sh
INFO[0002] args: [-c apk add tree]
fetch http://dl-cdn.alpinelinux.org/alpine/v3.9/main/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/v3.9/community/x86_64/APKINDEX.tar.gz
(1/1) Installing tree (1.8.0-r0)
Executing busybox-1.29.3-r10.trigger
OK: 6 MiB in 15 packages
INFO[0002] Taking snapshot of full filesystem...
INFO[0003] Skipping paths under /kaniko, as it is a whitelisted directory
INFO[0003] Skipping paths under /root/tokencache, as it is a whitelisted directory
INFO[0003] Skipping paths under /builder/cache, as it is a whitelisted directory
INFO[0003] Skipping paths under /builder/home, as it is a whitelisted directory
INFO[0003] Skipping paths under /builder/outputs, as it is a whitelisted directory
INFO[0003] Skipping paths under /var/run, as it is a whitelisted directory
INFO[0003] Skipping paths under /dev, as it is a whitelisted directory
INFO[0003] Skipping paths under /sys, as it is a whitelisted directory
INFO[0003] Skipping paths under /proc, as it is a whitelisted directory
INFO[0003] Skipping paths under /workspace, as it is a whitelisted directory
INFO[0003] RUN mkdir /app
INFO[0003] cmd: /bin/sh
INFO[0003] args: [-c mkdir /app]
INFO[0003] Taking snapshot of full filesystem...
INFO[0003] Skipping paths under /kaniko, as it is a whitelisted directory
INFO[0003] Skipping paths under /root/tokencache, as it is a whitelisted directory
INFO[0003] Skipping paths under /builder/cache, as it is a whitelisted directory
INFO[0003] Skipping paths under /builder/home, as it is a whitelisted directory
INFO[0003] Skipping paths under /builder/outputs, as it is a whitelisted directory
INFO[0003] Skipping paths under /var/run, as it is a whitelisted directory
INFO[0003] Skipping paths under /dev, as it is a whitelisted directory
INFO[0003] Skipping paths under /sys, as it is a whitelisted directory
INFO[0003] Skipping paths under /proc, as it is a whitelisted directory
INFO[0003] Skipping paths under /workspace, as it is a whitelisted directory
INFO[0003] Pushing layer *********/cache:66baeda084f3c55ee53656de11729a3954da8a831f469c87a3b6336f86e437c2 to cache now
INFO[0003] RUN mkdir /app/api
INFO[0003] cmd: /bin/sh
INFO[0003] args: [-c mkdir /app/api]
INFO[0003] Taking snapshot of full filesystem...
INFO[0003] Skipping paths under /kaniko, as it is a whitelisted directory
INFO[0003] Skipping paths under /root/tokencache, as it is a whitelisted directory
INFO[0003] Skipping paths under /builder/cache, as it is a whitelisted directory
INFO[0003] Skipping paths under /builder/home, as it is a whitelisted directory
INFO[0003] Skipping paths under /builder/outputs, as it is a whitelisted directory
INFO[0003] Skipping paths under /var/run, as it is a whitelisted directory
INFO[0003] Skipping paths under /dev, as it is a whitelisted directory
INFO[0003] Skipping paths under /sys, as it is a whitelisted directory
INFO[0003] Skipping paths under /proc, as it is a whitelisted directory
INFO[0003] Skipping paths under /workspace, as it is a whitelisted directory
INFO[0003] Pushing layer *********/cache:b8c0df74ce9b3795c0ea032e41744406a4e52245b72ae59e200275eb4ef4765f to cache now
INFO[0003] Using files from context: [/workspace/api]
INFO[0003] COPY api /app/api/
INFO[0003] Taking snapshot of files...
INFO[0003] RUN tree /app
INFO[0003] cmd: /bin/sh
INFO[0003] args: [-c tree /app]
/app
└── api
└── api.txt
1 directory, 1 file
Expected behavior
Build using docker.
COPY api /app/api/ result is below.
/app
└── api
└── api.txt
Build log
% docker build --no-cache=true .
Sending build context to Docker daemon 95.74kB
Step 1/6 : FROM alpine
---> caf27325b298
Step 2/6 : RUN apk add tree
---> Running in 05f28a5a42e0
fetch http://dl-cdn.alpinelinux.org/alpine/v3.9/main/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/v3.9/community/x86_64/APKINDEX.tar.gz
(1/1) Installing tree (1.8.0-r0)
Executing busybox-1.29.3-r10.trigger
OK: 6 MiB in 15 packages
Removing intermediate container 05f28a5a42e0
---> c6bd2073cfd3
Step 3/6 : RUN mkdir /app
---> Running in f872aa7de7b9
Removing intermediate container f872aa7de7b9
---> 83bd3c1140a2
Step 4/6 : RUN mkdir /app/api
---> Running in 616c0dc0f512
Removing intermediate container 616c0dc0f512
---> eaed8b1404e7
Step 5/6 : COPY api /app/api/
---> 797c4f292a58
Step 6/6 : RUN tree /app
---> Running in 004d300b0edf
/app
└── api
└── api.txt
1 directory, 1 file
Removing intermediate container 004d300b0edf
---> b52d788d4be3
Successfully built b52d788d4be3
Reporducing environment is below.
Actual behavior
Build using kaniko.
COPY api /app/api/
result is below.Expected behavior
Build using docker.
COPY api /app/api/
result is below.Docker version
To Reproduce
The reproduced environment is below repository.
https://github.com/SpringMT/kaniko_test
Steps to reproduce the behavior:
I'm using Cloud Build.
Build config file is https://github.com/SpringMT/kaniko_test/blob/master/cloudbuild.yaml .
Additional Information
https://github.com/SpringMT/kaniko_test/blob/master/Dockerfile
https://github.com/SpringMT/kaniko_test
The text was updated successfully, but these errors were encountered: