diff --git a/etc/metadefs/compute-vtpm-hw.json b/etc/metadefs/compute-vtpm-hw.json index 0a4f060269..5d3f72fef4 100644 --- a/etc/metadefs/compute-vtpm-hw.json +++ b/etc/metadefs/compute-vtpm-hw.json @@ -17,14 +17,24 @@ "properties": { "tpm_model": { "title": "TPM model", - "description": "TPM model to use. Option CRB is only valid for TPM version 2.0. Defaults to TIS.", + "description": "TPM model to use. Option tpm-crb is only valid for TPM version 2.0. Defaults to tpm-tis.", "operators": [""], "type": "string", "enum": [ - "TIS", - "CRB" + "tpm-tis", + "tpm-crb" ], - "default": "TIS" + "default": "tpm-tis" + }, + "tpm_version": { + "title": "TPM version", + "description": "TPM version to use. Required if requesting a vTPM. Model tpm-tis supports both, tpm-crb supports only 2.0.", + "operators": [""], + "type": "string", + "enum": [ + "1.2", + "2.0" + ] } }, "objects": [] diff --git a/glance/tests/functional/db/base_metadef.py b/glance/tests/functional/db/base_metadef.py index 23dcd26173..c2982d0e1d 100644 --- a/glance/tests/functional/db/base_metadef.py +++ b/glance/tests/functional/db/base_metadef.py @@ -791,7 +791,7 @@ class MetadefLoadUnloadTests: 'OS::Glance::CommonImageProperties': 10, 'OS::Compute::GuestShutdownBehavior': 1, 'OS::Compute::VMwareFlavor': 2, - 'OS::Compute::TPM': 1, + 'OS::Compute::TPM': 2, 'OS::Compute::GuestMemoryBacking': 1, 'OS::Compute::LibvirtImage': 17, 'OS::Compute::VMware': 6,