Change image.hw_qemu_guest_agent to be string

hw_qemu_guest_agent attribute of the image is a string boolean
supporting `yes` and `no` and not a real boolean like we were expecting.
Replace it to be string instead.

Change-Id: I5b9714e4388df440bf881033283da4e8aa1db497
This commit is contained in:
Artem Goncharov 2021-09-09 17:29:56 +02:00
parent 0078bc41e1
commit b4f93e335e
3 changed files with 9 additions and 3 deletions

View File

@ -224,8 +224,9 @@ class Image(resource.Resource, resource.TagMixin, _download.DownloadMixin):
os_type = resource.Body('os_type')
#: The operating system admin username.
os_admin_user = resource.Body('os_admin_user')
#: If true, QEMU guest agent will be exposed to the instance.
hw_qemu_guest_agent = resource.Body('hw_qemu_guest_agent', type=bool)
#: A string boolean, which if "true", QEMU guest agent will be exposed
#: to the instance.
hw_qemu_guest_agent = resource.Body('hw_qemu_guest_agent', type=str)
#: If true, require quiesce on snapshot via QEMU guest agent.
os_require_quiesce = resource.Body('os_require_quiesce', type=bool)
#: The URL for the schema describing a virtual machine image.

View File

@ -84,7 +84,7 @@ EXAMPLE = {
'auto_disk_config': True,
'os_type': '49',
'os_admin_user': 'ubuntu',
'hw_qemu_guest_agent': True,
'hw_qemu_guest_agent': 'yes',
'os_require_quiesce': True,
}

View File

@ -0,0 +1,5 @@
---
fixes:
- |
hw_qemu_guest_agent attribute of the image is a string boolean with values
`yes` and `no`.