Add THP test variants to tests_base.cfg.sample
[autotest-zwu.git] / server / samples / git_kernel.srv
blobf78f705cc70a7c61f08da02c372ce8e815ff9d6e
1 # dir on remote host to hold git repo
2 repodir = '/tmp/kvm'
4 # git url to clone
5 giturl  = 'git://git.kernel.org/pub/scm/linux/kernel/git/avi/kvm.git'
7 # web url to check remote version to determine whether or not to 'git pull'
8 weburl  = 'http://git.kernel.org/?p=linux/kernel/git/avi/kvm.git'
10 # CHANGEME - kernel config
11 kconfig = 'http://git.kernel.org/?p=virt/kvm/kvm-userspace.git;a=blob_plain;f=kernel/x86_64.config;hb=HEAD'
13 # CHANGEME
14 myhostname = 'myhost'
16 # init the git kernel
17 kernel = git_kernel.GitKernel(repodir, giturl, weburl)
19 # ssh to remote host
20 h = hosts.create_host(myhostname)
22 # acquire git repo, make sure it is up-to-date, clone repo into tmp dir
23 kernel.get(h)
25 # display local repo version
26 print kernel.get_local_head(h)
28 # configure, build, and install on remote host
29 kernel.configure(kconfig)
30 kernel.build(h)
31 kernel.install(h)
33 # add kernel to remote host bootloader, set up next boot entry
34 h.bootloader.boot_once('autotest')
36 # reboot and check that everything worked
37 h.reboot()
38 h.wait_up()
39 print h.run("uname -a").stdout