3 from TestMapper import TestMapper
5 # using mapper to do the reallocation job
7 def config (plcs, options):
9 if options.arch == "i386":
10 plc_box ='speedball.inria.fr'
11 node_box1 = 'testbox64_1.onelab.eu'
12 node_box2 = 'testbox64_2.onelab.eu'
13 elif options.arch == "x86_64":
14 plc_box = 'speedball.inria.fr'
15 node_box1 = 'testbox64_1.onelab.eu'
16 node_box2 = 'testbox64_2.onelab.eu'
18 print 'Unsupported arch %s'%options.arch
21 mapper = {'plc': [ ('*' , {'hostname':plc_box,
22 'PLC_DB_HOST':plc_box,
23 'PLC_API_HOST':plc_box,
24 'PLC_BOOT_HOST':plc_box,
25 'PLC_WWW_HOST':plc_box,
26 'name':'%s-'+options.arch } )
28 'node': [ ('deferred01' , {'host_box': node_box1 } ),
29 ('deferred02' , {'host_box': node_box2 } ),
33 return TestMapper(plcs,options).map(mapper)