bake: merge cache-from field from compose and x-bake

Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
This commit is contained in:
CrazyMax
2022-06-23 21:47:05 +02:00
parent b438032a60
commit a0f92829a7
2 changed files with 2 additions and 2 deletions

View File

@ -190,7 +190,7 @@ func (t *Target) composeExtTarget(exts map[string]interface{}) error {
t.Tags = append(t.Tags, xb.Tags...)
}
if len(xb.CacheFrom) > 0 {
t.CacheFrom = xb.CacheFrom // override main field
t.CacheFrom = append(t.CacheFrom, xb.CacheFrom...)
}
if len(xb.CacheTo) > 0 {
t.CacheTo = append(t.CacheTo, xb.CacheTo...)