Skip existing VMs when hosts apply force_config_drive
When hosts apply config `CONF.force_config_drive=True`, the existing
VMs shouldn't be enforced to must have config drive device. For they
may have been cloud-inited via metadata service, and may not need and
have any config drive device ever. In contrast, the newly being-built
ones should. Instance attr `launched_at` serves as an apparent flag
to distinguish the two kinds of VMs.
When hard reboots happend, existing VMs skip config drive enforcement,
and therefore avoid hitting 'No such file or directory (config drive
device)' error.
Reviewed: https:/ /review. opendev. org/659703 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=2af89cfea05 31ab75b4f5765bb 220073f42662d0
Committed: https:/
Submitter: Zuul
Branch: master
commit 2af89cfea0531ab 75b4f5765bb2200 73f42662d0
Author: pandatt <guojy8993@163.com>
Date: Thu May 16 02:50:57 2019 +0800
Skip existing VMs when hosts apply force_config_drive
When hosts apply config `CONF.force_ config_ drive=True` , the existing
VMs shouldn't be enforced to must have config drive device. For they
may have been cloud-inited via metadata service, and may not need and
have any config drive device ever. In contrast, the newly being-built
ones should. Instance attr `launched_at` serves as an apparent flag
to distinguish the two kinds of VMs.
When hard reboots happend, existing VMs skip config drive enforcement,
and therefore avoid hitting 'No such file or directory (config drive
device)' error.
Change-Id: I0558ece92f8657 c2f6294e07965c6 19eb7c8dfcf
Closes-Bug: #1827492