summaryrefslogtreecommitdiff
path: root/bin/server-submit.py
blob: 42fa75f8b19b2514337ddcfba77df931935e7251 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#!/usr/bin/python

import xmlrpclib

# pylint: disable=invalid-name

with open('/home/buildd/tokens/staging.token') as auth:
    staging_token = "%s" % auth.read().split('\n')[0]

with open('/home/buildd/tokens/production.token') as auth:
    production_token = "%s" % auth.read().split('\n')[0]

with open("/home/buildd/refactoring/functional/lxc-server-stretch.yaml") as f:
    config = f.read()

server = xmlrpclib.ServerProxy("http://lavabuildd:%s@staging.validation.linaro.org/RPC2/" % staging_token)
job_id = server.scheduler.submit_job(config)
server = xmlrpclib.ServerProxy("http://lava-auto:%s@validation.linaro.org/RPC2/" % production_token)
job_id = server.scheduler.submit_job(config)

# install tests
install = "/home/buildd/refactoring/functional/server-staging-install.yaml"
qemu_di = "/home/buildd/refactoring/functional/qemu-jessie-installer.yaml"

with open(upgrade) as f:
    config = f.read()
server = xmlrpclib.ServerProxy("http://lavabuildd:%s@staging.validation.linaro.org/RPC2/" % staging_token)
job_id = server.scheduler.submit_job(config)

with open(install) as f:
    config = f.read()
job_id = server.scheduler.submit_job(config)

with open(qemu_di) as f:
    config = f.read()
job_id = server.scheduler.submit_job(config)