mirror of
https://github.com/GoogleContainerTools/kaniko
synced 2026-10-02 18:01:45 +02:00
Preserve options when doing a cache push (#423)
* Preserve options when doing a cache push Otherwise options like `insecure` are lost * Do not override original object
This commit is contained in:
@@ -126,7 +126,7 @@ func pushLayerToCache(opts *config.KanikoOptions, cacheKey string, layer v1.Laye
|
||||
if err != nil {
|
||||
return errors.Wrap(err, "appending layer onto empty image")
|
||||
}
|
||||
return DoPush(empty, &config.KanikoOptions{
|
||||
Destinations: []string{cache},
|
||||
})
|
||||
cacheOpts := *opts
|
||||
cacheOpts.Destinations = []string{cache}
|
||||
return DoPush(empty, &cacheOpts)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user