Skip to content

Commit ae8f60b

Browse files
committed
In case where build arg exists with nil value, count as unmatched arg
Signed-off-by: Talon Bowler <[email protected]>
1 parent 5642608 commit ae8f60b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

frontend/dockerfile/dockerfile2llb/convert.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2210,7 +2210,9 @@ func reportUnmatchedVariables(cmd instructions.Command, buildArgs []instructions
22102210
return
22112211
}
22122212
for _, buildArg := range buildArgs {
2213-
delete(unmatched, buildArg.Key)
2213+
if buildArg.Value != nil {
2214+
delete(unmatched, buildArg.Key)
2215+
}
22142216
}
22152217
if len(unmatched) == 0 {
22162218
return

0 commit comments

Comments
 (0)