tko.db: Fix job status when deleting jobs

When deleting jobs, we should delete job_id instead of id in table
afe_host_queue_entries. Otherwise after deleting a job, all other
job's status were also deleted.

Signed-off-by: Wenli Quan <wquan@redhat.com>
client.shared.iscsi: Default for self.export_flag

self.export_flag is used in cleanup and has to be defined in __init__

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
client/shared/software_manager.py: use distro detection API instead

This was a leftover from the original conversion to the distro API.

Signed-off-by: Cleber Rosa <crosa@redhat.com>
frontend/pkgdeps.py: use distro names as returned by distro.detect()

We were using the names provided by the old API (client.utils.get_os_vendor()).

Signed-off-by: Cleber Rosa <crosa@redhat.com>
client/shared/software_manager.py: style changes

Make pylint happier about variable names and other small issues.

Signed-off-by: Cleber Rosa <crosa@redhat.com>
client/shared/distro.py: introduce distro specification class

Used to describe a distribution with requirements such as a mininum
version or given architecture.

Signed-off-by: Cleber Rosa <crosa@redhat.com>
frontend/pkgdeps.py: use distro.Spec to specify packages for Fedora 19

Fedora 19 has package names that differ from older versions, so it's
not possible to keep all under a single package list.

So this makes it more specific with regards to the distro name (fedora)
and minimum version (19) and use this new package list.

Signed-off-by: Cleber Rosa <crosa@redhat.com>
client/shared/software_manager.py: implement software installation by distro spec

Making it possible to use a distro/package map that includes requirements such
as architecture and minimum version and release.

Signed-off-by: Cleber Rosa <crosa@redhat.com>
frontend/pkgdeps.py: Fedora 19 south packages compatible with django 1.4

There's no package of django-south in Fedora 19 that is compatible with
django >= 1.5. So, instead of not having a functional setup with Fedora
19, let's use django 1.4 which is good enough for our needs.

Signed-off-by: Cleber Rosa <crosa@redhat.com>
contrib/install-autotest-server.sh: remove 2nd round of package installation

Nothing changes wrt to packages and repos between `install_packages` and
`update_packages`, so remove one of them.

Signed-off-by: Cleber Rosa <crosa@redhat.com>
contrib/install-autotest-server.sh: install passwd package earlier

On Red Hat (like) systems, `passwd` is also needed at a very early
stage of the installation (before the complete package installation).

While we could assgin the password for the autotest user later (after
the full packages install), let's just make use of the same function
that installs git and call them "basic packages".

Signed-off-by: Cleber Rosa <crosa@redhat.com>
install-autotest-server.sh: Use same branch for tests as autotest.

Signed-off-by: Vinson Lee <vlee@twitter.com>
contrib/install-autotest-server.sh: Make test branches configurable

If we are testing autotest from our own git repo and branch,
we want to make sure an appropriate upstream branch for the
tests submodules will be pulled. So, give that option to the
user.

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
client/shared/service_lib_unittest.py: make it runnable standalone

By adding the executable bits and the boiler plate code.

Signed-off-by: Cleber Rosa <crosa@redhat.com>
client.shared.service: Add '--no-pager' option to list units in systemd_command_generator

Signed-off-by: yangdongsheng <yangds.fnst@cn.fujitsu.com>
improve code coverage , added kvm_control unittests
added get_cpu_info method, cpu_has_flags and get_cpu_vendor_name
Added docstring according to CODING_STYLE, removed explicit importing of base_utils , modified importing order and added None validation @clebergnu suggestion
client/kvm_control_unittest.py: set executable bits

Signed-off-by: Cleber Rosa <crosa@redhat.com>
service: document systemctl pager workaround and arg string format

Make sure the argument list is a list of strings with one argument per
string so we are compatible with Popen and other execv style functions.

Signed-off-by: Ross Brattain <ross.b.brattain@intel.com>