dockerTools.*: Assertion against building for Darwin (#77952)

dockerTools.*: Assertion against building for Darwin
This commit is contained in:
Silvan Mosberger 2020-01-31 21:17:40 +01:00 committed by GitHub
commit 0a351c3f65
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -593,6 +593,8 @@ rec {
if tag == null
then lib.head (lib.splitString "-" (lib.last (lib.splitString "/" result)))
else lib.toLower tag;
# Docker can't be made to run darwin binaries
meta.badPlatforms = lib.platforms.darwin;
} ''
${if (tag == null) then ''
outName="$(basename "$out")"
@ -723,6 +725,8 @@ rec {
layerClosure = writeReferencesToFile layer;
passthru.buildArgs = args;
passthru.layer = layer;
# Docker can't be made to run darwin binaries
meta.badPlatforms = lib.platforms.darwin;
} ''
${lib.optionalString (tag == null) ''
outName="$(basename "$out")"