store: propagate Flags from options

the flags specified in the layer options were not honored before.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
This commit is contained in:
Giuseppe Scrivano 2023-08-11 15:26:19 +02:00
parent c3276d6f83
commit 02a2c20b2d
No known key found for this signature in database
GPG Key ID: 67E38F7A8BA21772
1 changed files with 1 additions and 0 deletions

View File

@ -1459,6 +1459,7 @@ func (s *store) PutLayer(id, parent string, names []string, mountLabel string, w
layerOptions := LayerOptions{
OriginalDigest: options.OriginalDigest,
UncompressedDigest: options.UncompressedDigest,
Flags: options.Flags,
}
if s.canUseShifting(uidMap, gidMap) {
layerOptions.IDMappingOptions = types.IDMappingOptions{HostUIDMapping: true, HostGIDMapping: true, UIDMap: nil, GIDMap: nil}