| OLD | NEW |
| 1 # Copyright (c) 2015 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2015 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 import chromiumos_board_config | 5 import chromiumos_board_config |
| 6 | 6 |
| 7 from common.cros_chromite import ChromiteTarget | 7 from common.cros_chromite import ChromiteTarget |
| 8 from common.cros_chromite import SlaveType | 8 from common.cros_chromite import SlaveType |
| 9 | 9 |
| 10 # Use the SlaveAlloctor declared in 'board_config'. | 10 # Use the SlaveAlloctor declared in 'board_config'. |
| 11 sa = chromiumos_board_config.slave_allocator | 11 sa = chromiumos_board_config.slave_allocator |
| 12 sa.LoadState(enforce=False) | 12 sa.LoadState(enforce=False) |
| 13 | 13 |
| 14 def shared(slave_type): | 14 def shared(slave_type): |
| 15 return '%s_shared' % (slave_type,) | 15 return '%s_shared' % (slave_type,) |
| 16 | 16 |
| 17 # Baremetal slaves | 17 # Baremetal slaves |
| 18 sa.AddPool(SlaveType.BAREMETAL, *('build%s-m2' % (n,) for n in ( | 18 sa.AddPool(SlaveType.BAREMETAL, *('build%s-m2' % (n,) for n in set([ |
| 19 85, 86, 87, 91, 92, 93, 112, 118, 141, 162, 174, 182, | 19 85, 86, 87, 91, 92, 93, 112, 118, 141, 162, 174, 182, |
| 20 203, 263, 323, 326, 327 | 20 203, 263, 323, 326, 327 |
| 21 ))) | 21 ]) - set([ |
| 22 91, # crbug.com/600599 |
| 23 ]))) |
| 22 | 24 |
| 23 # GCE slaves | 25 # GCE slaves |
| 24 sa.AddPool(SlaveType.GCE, *('cros%s-c2' % (n,) for n in ( | 26 sa.AddPool(SlaveType.GCE, *('cros%s-c2' % (n,) for n in ( |
| 25 199, | 27 199, |
| 26 ))) | 28 ))) |
| 27 | 29 |
| 28 # Baremetal shared slave pool (e.g., build123-m2) | 30 # Baremetal shared slave pool (e.g., build123-m2) |
| 29 sa.AddPool(shared(SlaveType.BAREMETAL), *('build%s-m2' % (n,) for n in ( | 31 sa.AddPool(shared(SlaveType.BAREMETAL), *('build%s-m2' % (n,) for n in ( |
| 30 84, 94 | 32 84, 94 |
| 31 ))) | 33 ))) |
| (...skipping 27 matching lines...) Expand all Loading... |
| 59 for c in config_names], | 61 for c in config_names], |
| 60 'hostname': str(hostname), | 62 'hostname': str(hostname), |
| 61 'os': 'linux', | 63 'os': 'linux', |
| 62 'version': 'precise', | 64 'version': 'precise', |
| 63 } | 65 } |
| 64 | 66 |
| 65 slaves = [] | 67 slaves = [] |
| 66 slave_map = sa.GetSlaveMap() | 68 slave_map = sa.GetSlaveMap() |
| 67 for hostname, entry in slave_map.entries.iteritems(): | 69 for hostname, entry in slave_map.entries.iteritems(): |
| 68 slaves.append(GenSlave(hostname, entry.keys)) | 70 slaves.append(GenSlave(hostname, entry.keys)) |
| OLD | NEW |