GoogleContainerTools / GoogleContainerTools/skaffold
skaffold cache documentation
- Dominant language
- Go
- Stars
- 15.9k
- Forks
- 1.7k
- Avg merge
- 3d 9h
- Merged PRs (30d)
- 10
Description
### Expected behavior
### Actual behavior
### Information
- Skaffold version: v1.38.0
- Operating system: macos and centos
- Installed via: curl
- Contents of skaffold.yaml:
the following is a snippet of skaffold
apiVersion: skaffold/v2beta17
```yaml
profiles:
- name: buildbase
build:
local:
push: false
artifacts:
- image: test/test-base
context: ../../../..
docker:
dockerfile: apps/test/deploy/docker/Dockerfile
tagPolicy:
envTemplate:
template: 'dev34'
- name: test
build:
artifacts:
- image: test/test-test
context: ../../../..
docker:
dockerfile: apps/test/deploy/docker/Dockerfile_tester
target: tester
buildArgs:
DOCKERFILE_BASE: test/test-base:dev34
tagPolicy:
envTemplate:
template: "dev34"
local:
push: false
- name: remote
build:
local:
push: true
artifacts:
- image: testregistryaq.azurecr.io/test/test
context: ../../../..
docker:
dockerfile: apps/test/deploy/docker/Dockerfile_runtime
buildArgs:
DOCKERFILE_BASE: test/test-base:dev34
tagPolicy:
envTemplate:
template: 'dev34'
```
###Dockerfiles
Dockerfile
```
FROM node:14
COPY . .
COPY test-tonton /tmp/test-tonton
```
Dockerfile_tester
```
ARG DOCKERFILE_BASE
FROM ${DOCKERFILE_BASE} AS tester
```
Dockerfile_runtime
```
ARG DOCKERFILE_BASE
FROM ${DOCKERFILE_BASE} AS runtime
```
### Steps to reproduce the behavior
- if we change the content of the file test-tonton skaffold, using the profile buildbase, will build a new image, BUT the profile test will not build a new image saying Found Locally
- if we add a new layer in the Dockerfile of the profile buildbase, skaffold will build a new image when using the profile test
- for the profile remote whatever we change in the base image skaffold will not rebuild the child image saying Found Remotly
please can you add an explan how the cache works in the background to know what to expect
Contributor guide
Assessment
This issue has not been assessed yet.