This directory was implicitly removed with commit
8a020010b7 and breaks several peoples
builds as some examples and documentation expect the directory to exist.
Kaniko by default used to configure the GCR credential helper however
this caused Kaniko to fail when trying to use a base image from a public
GCR image. This patch makes it possible to use public GCR images as base
image when using docker even when you're not authenticated to GCR.
Co-authored-by: Nate Williams <nate.williams@files.com>
* Upgrade go.mod file
* Upgrade travis file
* Run rm -rf vendor && go mod tidy && go mod vendor to upgrade vendor/modules.txt according to golang 1.14
* Upgrade golangci-lint version
Cloud build is also really useful for devs that have limited resources
to build Kaniko locally. This commit makes adds parameters to cloudbuild
to make it easy to adjust to your own project.
I needed this for my arm64 k8s cluster. I have zero Go experience but
enough experience with other things to fix the rebase (I think!). This
patch is working fine on my cluster.
When using Kaniko with certain build systems, such as GitLab CI, it is necessary to use the 'debug' image and override the entrypoint, so that an arbitrary build script can be executed within the container. Unfortunately, the 'warmer' binary is not available in the 'debug' image, making it impossible to perform a base image cache warmup using such build systems.
This patch addresses this by ensuring that the 'out/warmer' target is made in the initial stage, and that all 'out' files are copied to '/kaniko' in the final stage.
* comments
* initial commit for persisent volume caching
* cache warmer works
* general cleanup
* adding some debugging
* adding missing files
* Fixing up cache retrieval and cleanup
* fix tests
* removing auth since we only cache public images
* simplifying the caching logic
* fixing logic
* adding volume cache to integration tests. remove auth from cache warmer image.
* add building warmer to integration-test
* move sample yaml files to examples dir
* small test fix
In the debug image, declare /busybox as a volume so that it is automatically whitelisted, because we don't want to delete it when building multi-stages images.
FYI this is required when using Jenkins, because we need to use the debug kaniko image to be able to start the container "doing nothing" (with /busybox/cat) before building (by executing /kaniko/executor directly inside the container)
See https://issues.jenkins-ci.org/browse/JENKINS-52576
I was seeing an error with our cloudbuild triggers where the tagged
:latest version of image wasn't the same as the :commit version, even
though it was created via 'docker tag image:commit image:latest'.
I'm not sure why this would be happening, but for now building each
image separately should hopefully fix this error.
* Vendor changes for go-containerregistry switch.
* Manual changes for go-containerregistry switch.
The biggest change is refactoring the tarball unpacking.
* Pull more of container-diff out.
* More vendor removals.
* More unit tests.
The certs should be added to the whitelisted kaniko directory so that
an image build does not override them and possibly affect the push to
the registry.