- merge from PlanetLab Europe
[plcapi.git] / plctest / TestConfig.py
1 #definition of all structure used by the test_setup.py script
2
3 site1_nodes = {
4 'node1' :  {'hostname': 'test1.one-lab.org',
5             'boot_state':'inst',
6             'model':'vmware/minhw',
7             'owned' : 'pi',
8             'network': { 'method':'static',
9                          'type':'ipv4',
10                          'ip':'192.168.132.128',
11                          'gateway':'192.168.132.1',
12                          'network':'192.168.132.0',
13                          'broadcast':'192.168.132.255',
14                          'netmask':'255.255.255.0',
15                          'dns1': '192.168.132.2',
16                          },
17             
18             },
19 'node2' :   { 'hostname':'test2.one-lab.org',
20               'boot_state':'inst',
21               'model':'vmware/minhw',
22               'owned' : 'tech',
23               'network': {'method':'static',
24                           'type':'ipv4',
25                           'ip':'192.168.132.130',
26                           'gateway':'192.168.132.1',
27                           'network':'192.168.132.0',
28                           'broadcast':'192.168.132.255',
29                           'netmask':'255.255.255.0',
30                           'dns1': '192.168.132.2',
31                           },
32               
33               },
34 }
35
36 site_spec1 = {
37 'site_fields' : {'name':'testsite',
38                  'login_base':'ts',
39                  'abbreviated_name':'PLanettest',
40                  'max_slices':100,
41                  'url':'http://onelab-test.inria.fr',
42                  },
43 'site_address' : {'line1':'route des lucioles',
44                   'city':'sophia',
45                   'state':'fr',
46                   'postalcode':'06600',
47                   'country':'france',
48                   },
49 'pi_spec' : {'first_name':'PI',
50                'last_name':'PI',
51                'enabled':'True',
52                'email':'fake-pi1@one-lab.org',
53                'password':'testpi',
54                'roles':['pi'],
55                },
56 'tech_spec' : {'first_name':'Tech',
57                'last_name':'Tech',
58                  'enabled':'true',
59                  'email':'fake-tech1@one-lab.org',
60                  'password':'testtech',
61                  'roles':['tech'],
62                  },
63 'user_spec' : {'first_name':'User',
64                  'last_name':'User',
65                  'enabled':'true',
66                  'email':'fake-user1@one-lab.org',
67                  'password':'testuser',
68                  'roles':['user'],
69                  },
70 'tech_user_spec' : {'first_name':'UserTech',
71                  'last_name':'UserTech',
72                  'enabled':'true',
73                  'email':'fake-tech2@one-lab.org',
74                  'password':'testusertech',
75                  'roles':['tech','user'],
76                  },
77 'pi_tech_spec' : {'first_name':'PiTech',
78                  'last_name':'PiTech',
79                  'enabled':'true',
80                  'email':'fake-pi2@one-lab.org',
81                  'password':'testusertech',
82                  'roles':['pi','tech'],
83                   },
84
85 'nodes' :  [ site1_nodes['node1'], site1_nodes['node2']],
86 }
87
88     
89 site_specs = [ site_spec1 ]
90
91 plc_spec1 =  { 
92     'hostname' : 'localhost',
93     'role' : 'root',
94     'PLC_ROOT_USER' : 'root@onelab-test.inria.fr',
95     'PLC_ROOT_PASSWORD' : 'test++',
96     'PLC_NAME' : 'TestLab',
97     'PLC_MAIL_ENABLED':'true',
98     'PLC_MAIL_SUPPORT_ADDRESS' : 'mohamed-amine.chaoui@sophia.inria.fr',
99     'PLC_DB_HOST' : 'onelab-test.inria.fr',
100     'PLC_API_DEBUG':'true',
101     'PLC_API_HOST' : 'onelab-test.inria.fr',
102     'PLC_WWW_HOST' : 'onelab-test.inria.fr',
103     'PLC_BOOT_HOST' : 'onelab-test.inria.fr',
104     'PLC_NET_DNS1' : '138.96.0.10',
105     'PLC_NET_DNS2' : '138.96.0.11',
106     'sites' : site_specs,
107     }
108
109 plc_specs = [ plc_spec1 ]
110
111 key={'key_type':'ssh',
112      'key':'ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEA4jNj8yT9ieEc6nSJz/ESu4fui9WrJ2y/MCfqIZ5WcdVKhBFUYyIenmUaeTduMcSqvoYRQ4QnFR1BFdLG8XR9D6FWZ5zTKUgpkew22EVNeqai4IXeWYKyt1Qf3ehaz9E3o1PG/bmQNIM6aQay6TD1Y4lqXI+eTVXVQev4K2fixySjFQpp9RB4UHbeA8c28yoa/cgAYHqCqlvm9uvpGMjgm/Qa4M+ZeO7NdjowfaF/wF4BQIzVFN9YRhvQ/d8WDz84B5Pr0J7pWpaX7EyC4bvdskxl6kmdNIwIRcIe4OcuIiX5Z9oO+7h/chsEVJWF4vqNIYlL9Zvyhnr0hLLhhuk2bw== root@onelab-test.inria.fr'}
113
114
115 slice_spec={'name':'ts_slicetest1',
116               'instantiation':'plc-instantiated',
117               'url':'http://foo@ffo.com',
118               'description':'testslice the first slice for the site testsite',
119               'max_nodes':1000
120               }
121
122 file_name='%d%s.iso'