Update the priority values in the schema to match the actual allowed
ones.

Bug: 740704
Fixes to whiteboard env var definitions

- always define env vars (even when empty)
- set to empty when provisioning manual systems

Bug: 691442
Change-Id: Id47f78f97447f56e76e3bf72d53c73279141afea
update repo URL for Fedora ARM packages

Bug: 874675
Change-Id: I2ba4c3817be49eeebb9f58c6a2b59c6f81bbd9c3
fix error when destroying a VM which is not running

2012-11-08 14:25:09,875 bkr.server.model ERROR Failed to destroy vm guest_for_recipe_220, leaked!
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/bkr/server/model.py", line 6005, in release
    manager.destroy_vm(self.system_name)
  File "/usr/lib/python2.6/site-packages/bkr/server/model.py", line 6492, in destroy_vm
    vm.stop()
  File "/usr/lib/python2.6/site-packages/ovirtsdk/infrastructure/brokers.py", line 5313, in stop
    headers={"Correlation-Id":correlation_id})
  File "/usr/lib/python2.6/site-packages/ovirtsdk/infrastructure/proxy.py", line 128, in request
    last=last)
  File "/usr/lib/python2.6/site-packages/ovirtsdk/infrastructure/proxy.py", line 154, in __doRequest
    raise RequestError, response
RequestError:
status: 400
reason: Bad Request
detail: Cannot stop VM. VM is not running.

Change-Id: If8896b414746778b98bc72ae160de77bfcd5451b
Merge "Fixes to whiteboard env var definitions" into release-0.10
Merge "fix error when destroying a VM which is not running" into release-0.10
Look for an element on the loaded page.

This takes advantage of the implicit wait and hence
prevents intermittent failures.

Bug: 860870
Change-Id: I032df8fc0018dbbfd77995ae025aed674c1ff37a
Merge "update repo URL for Fedora ARM packages" into release-0.10
Re-doing template change from 77641e1.

This was acidentally overwritten by e708bd
skip log-delete tests if kerberos is not available

We only support Kerberos authentication in log-delete, so we can just
skip the tests if it's missing.

    Traceback (most recent call last):
      File "/usr/lib/python2.6/site-packages/bkr/inttest/server/tools/test_log_delete.py", line 116, in test_log_delete_expired
        log_delete.log_delete()
      File "/usr/lib/python2.6/site-packages/bkr/server/tools/log_delete.py", line 54, in log_delete
        auth=requests.auth.HTTPKerberosAuth(require_mutual_auth=False))
      File "/usr/lib/python2.6/site-packages/requests/auth.py", line 279, in __init__
        raise Exception("Kerberos libraries unavailable")
    Exception: Kerberos libraries unavailable

Change-Id: I55a50aedbd1255545126101ad88f713a25b04454
tests: ensure log messages are always evaluated immediately

This is to work around the fact that nose delays evaluating the log
messages when log capturing is enabled, which can result in exceptions
like this if the log message tries to format an expired sqlalchemy
instance:

    Traceback (most recent call last):
      File "/usr/bin/nosetests", line 9, in <module>
        load_entry_point('nose==1.1.2', 'console_scripts', 'nosetests')()
      File "/usr/lib/python2.6/site-packages/nose/core.py", line 118, in __init__
        **extra_args)
      File "/usr/lib64/python2.6/unittest.py", line 816, in __init__
        self.runTests()
      File "/usr/lib/python2.6/site-packages/nose/core.py", line 197, in runTests
        result = self.testRunner.run(self.test)
      File "/usr/lib/python2.6/site-packages/nose/core.py", line 61, in run
        test(result)
      [...]
      File "/usr/lib/python2.6/site-packages/nose/case.py", line 138, in run
        result.addError(self, err)
      File "/usr/lib/python2.6/site-packages/nose/proxy.py", line 131, in addError
        formatted = plugins.formatError(self.test, err)
      File "/usr/lib/python2.6/site-packages/nose/plugins/manager.py", line 94, in __call__
        return self.call(*arg, **kw)
      File "/usr/lib/python2.6/site-packages/nose/plugins/manager.py", line 136, in chain
        result = meth(*arg, **kw)
      File "/usr/lib/python2.6/site-packages/nose/plugins/logcapture.py", line 223, in formatError
        test.capturedLogging = records = self.formatLogRecords()
      File "/usr/lib/python2.6/site-packages/nose/plugins/logcapture.py", line 231, in formatLogRecords
        return [safe_str(format(r)) for r in self.handler.buffer]
      File "/usr/lib64/python2.6/logging/__init__.py", line 654, in format
        return fmt.format(record)
      File "/usr/lib64/python2.6/logging/__init__.py", line 436, in format
        record.message = record.getMessage()
      File "/usr/lib64/python2.6/logging/__init__.py", line 306, in getMessage
        msg = msg % self.args
      File "/usr/lib/python2.6/site-packages/bkr/server/model.py", line 2982, in __repr__
        return '%s(name=%r)' % (self.__class__.__name__, self.name)
      File "/usr/lib64/python2.6/site-packages/sqlalchemy/orm/attributes.py", line 168, in __get__
        instance_dict(instance))
      File "/usr/lib64/python2.6/site-packages/sqlalchemy/orm/attributes.py", line 388, in get
        value = callable_(passive=passive)
      File "/usr/lib64/python2.6/site-packages/sqlalchemy/orm/state.py", line 287, in __call__
        self.manager.deferred_scalar_loader(self, toload)
      File "/usr/lib64/python2.6/site-packages/sqlalchemy/orm/mapper.py", line 2509, in _load_scalar_attributes
        state_str(state))
    sqlalchemy.orm.exc.ObjectDeletedError: Instance '<Distro at 0x525ed90>' has been deleted.

Also removed a very old workaround for sqlalchemy 0.4 that no longer
applies.

Change-Id: I0c6bd888ae3ad660bb965c861a08d195c67ec0c5
roll back creation of VirtResource if VM creation fails

Otherwise the VirtResource row will be committed even though the VM was
never created and the recipe was not moved to Scheduled. So it will end
up breaking later on, when queued_recipes tries to provision a real
system for it:

    2012-11-12 18:12:12,071 beakerd ERROR Failed to commit in queued_recipes
    Traceback (most recent call last):
      File "/usr/lib/python2.6/site-packages/bkr/server/tools/beakerd.py", line 391, in queued_recipes
        recipe.resource.allocate()
      File "/usr/lib/python2.6/site-packages/bkr/server/model.py", line 5964, in allocate
        reservation_type=u'recipe')
      File "/usr/lib/python2.6/site-packages/bkr/server/model.py", line 2452, in reserve
        session.flush()
      [...]
    IntegrityError: (IntegrityError) (1452, 'Cannot add or update a child row: a foreign key constraint fails (`beaker_devel/recipe_resource`, CONSTRAINT `recipe_resource_recipe_id_fk` FOREIGN KEY (`recipe_id`) REFERENCES `recipe` (`id`) ON DELETE CASCADE ON UPDATE CASCADE)') 'UPDATE recipe_resource SET recipe_id=%s WHERE recipe_resource.id = %s' (None, 12L)

Change-Id: I6e9cd94ad674549e3dff688e5d2d8be0e9426fb5
fix Processed and Queued state transitions for guest recipes

This was a mistake in commit 7e690c1e for bug 655009. The update_status
method would never be called after changing the state of the guest
recipes so they would be stuck in New.

Change-Id: I871437dba7fa75f13fe2d0bc2fc32dbe084e7352
add /tmp/packaging.log to anamon watch list

Bug: 870908
Change-Id: I22113718a96d791d150d71608f56ebfe91551468
Move CSV export step to top of upgrade notes.

We need to do this step first as beaker may be in a non functioning state
half way through the upgrade, so the CSV export may not work at that point.
Specify which storage domain you want your beaker machines created on.

Without this option, having non bootable storage domains (i.e ISO domains) on your
Hypervisor can cause the following traceback during provisioning and will
abort the recipe:

  2012-11-15 17:22:51,828 beakerd ERROR Failed to provision recipeid 360
  Traceback (most recent call last):
    File "/usr/lib/python2.6/site-packages/bkr/server/tools/beakerd.py", line 525, in scheduled_recipes
      recipe.provision()
    File "/usr/lib/python2.6/site-packages/bkr/server/model.py", line 5194, in provision
      self.resource.lab_controller)
    File "/usr/lib/python2.6/site-packages/bkr/server/model.py", line 6484, in start_install
      self.api.vms.get(name).start(action=a)
    File "/usr/lib/python2.6/site-packages/ovirtsdk/infrastructure/brokers.py", line 5296, in start
      headers={"Correlation-Id":correlation_id})
    File "/usr/lib/python2.6/site-packages/ovirtsdk/infrastructure/proxy.py", line 128, in request
      last=last)
    File "/usr/lib/python2.6/site-packages/ovirtsdk/infrastructure/proxy.py", line 154, in __doRequest
      raise RequestError, response
  RequestError: ^M
  status: 400^M
  reason: Bad Request^M
  detail: Cannot run VM without at least one bootable disk
Moved schedule code into virt_recipes().

RHEV errors during the scheduling could cause every rhev recipe
to be aborted, without having the ability of falling back to queing
on a regular system. Errors from recipe.provision()
(like those shown in 7f541ff1d8ae3fa0a44bd) are now caught and handled.

Change-Id: Ida9e8d79b05f8c1b82f6ce46998c1bec7a71a7e5
Automatic commit of package [beaker] release [0.10.1-1].
Merge "add /tmp/packaging.log to anamon watch list" into release-0.10
Automatic commit of package [beaker] release [0.10.1-2].