moby/layer
Cory Snider 098a44c07f Finish refactor of UID/GID usage to a new struct
Finish the refactor which was partially completed with commit
34536c498d, passing around IdentityMapping structs instead of pairs of
[]IDMap slices.

Existing code which uses []IDMap relies on zero-valued fields to be
valid, empty mappings. So in order to successfully finish the
refactoring without introducing bugs, their replacement therefore also
needs to have a useful zero value which represents an empty mapping.
Change IdentityMapping to be a pass-by-value type so that there are no
nil pointers to worry about.

The functionality provided by the deprecated NewIDMappingsFromMaps
function is required by unit tests to to construct arbitrary
IdentityMapping values. And the daemon will always need to access the
mappings to pass them to the Linux kernel. Accommodate these use cases
by exporting the struct fields instead. BuildKit currently depends on
the UIDs and GIDs methods so we cannot get rid of them yet.

Signed-off-by: Cory Snider <csnider@mirantis.com>
2022-03-14 16:28:57 -04:00
..
empty.go layer: remove unused error return from .Size() and .DiffSize() 2022-01-24 18:45:47 +01:00
empty_test.go remove unneeded "digest" alias for "go-digest" 2022-03-04 14:49:42 +01:00
filestore.go remove unneeded "digest" alias for "go-digest" 2022-03-04 14:49:42 +01:00
filestore_test.go remove unneeded "digest" alias for "go-digest" 2022-03-04 14:49:42 +01:00
filestore_unix.go Update to Go 1.17.0, and gofmt with Go 1.17 2021-08-24 23:33:27 +02:00
filestore_windows.go refactor: move from io/ioutil to io and os package 2021-08-27 14:56:57 +08:00
layer.go remove unneeded "digest" alias for "go-digest" 2022-03-04 14:49:42 +01:00
layer_store.go Finish refactor of UID/GID usage to a new struct 2022-03-14 16:28:57 -04:00
layer_store_windows.go Add canonical import comment 2018-02-05 16:51:57 -05:00
layer_test.go Finish refactor of UID/GID usage to a new struct 2022-03-14 16:28:57 -04:00
layer_unix.go Update to Go 1.17.0, and gofmt with Go 1.17 2021-08-24 23:33:27 +02:00
layer_unix_test.go layer: remove unused error return from .Size() and .DiffSize() 2022-01-24 18:45:47 +01:00
layer_windows.go Fix a typos in layer_windows.go 2018-11-18 18:45:06 +08:00
migration.go Merge pull request #43302 from thaJeztah/layer_remove_getwithoutlock 2022-03-05 21:18:26 +01:00
migration_test.go layer: remove OS from layerstore 2022-01-25 15:23:23 +01:00
mount_test.go refactor: move from io/ioutil to io and os package 2021-08-27 14:56:57 +08:00
mounted_layer.go Remove unused functions, variables, fields 2019-09-18 12:57:12 +02:00
ro_layer.go remove unneeded "digest" alias for "go-digest" 2022-03-04 14:49:42 +01:00
ro_layer_windows.go Add canonical import comment 2018-02-05 16:51:57 -05:00