dockerTools.buildLayeredImage: assert maxLayers > 1
Since a layer is reserved for "customization", the image can not
contains less than 2 layers.
The user gets the following message at evaluation:
nix-instantiate nixos/tests/docker-tools.nix
trace: the maxLayers argument of dockerTools.buildLayeredImage function must be greather than 1 (current value: 1)
This commit is contained in:
@@ -545,6 +545,9 @@ rec {
|
|||||||
# believe the actual maximum is 128.
|
# believe the actual maximum is 128.
|
||||||
maxLayers ? 100
|
maxLayers ? 100
|
||||||
}:
|
}:
|
||||||
|
assert
|
||||||
|
(lib.assertMsg (maxLayers > 1)
|
||||||
|
"the maxLayers argument of dockerTools.buildLayeredImage function must be greather than 1 (current value: ${toString maxLayers})");
|
||||||
let
|
let
|
||||||
baseName = baseNameOf name;
|
baseName = baseNameOf name;
|
||||||
contentsEnv = symlinkJoin {
|
contentsEnv = symlinkJoin {
|
||||||
|
|||||||
Reference in New Issue
Block a user