Merge pull request #985 from tonistiigi/multi-node-platform

build: fix multi-node builds with mixed platforms
This commit is contained in:
CrazyMax 2022-03-04 15:35:55 +01:00 committed by GitHub
commit a1256c6bb2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -189,6 +189,10 @@ func splitToDriverPairs(availablePlatforms map[string]int, opt map[string]Option
pp = append(pp, p)
mm[idx] = pp
}
// if no platform is specified, use first driver
if len(mm) == 0 {
mm[0] = nil
}
dps := make([]driverPair, 0, 2)
for idx, pp := range mm {
dps = append(dps, driverPair{driverIndex: idx, platforms: pp})