You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Remove build flag and re-introduce provision method attribute (#122)
* Remove build flag and re-introduce provision method attribute
The build flag was introduced as the replacement for the "method"
attribute. Earlier, the method could be set to "build" or "image", which
is then used by Foreman. The initial creation of a host also needed the
build flag to be set in the API request to signal Foreman that it should
create the machine.
This lead to the problem that Terraform configs containing "build = true"
would reset the build flag in Foreman even for existing, already built
machines, resetting them at the next boot. This is dangerous and should
be avoided.
The commit removes the build flag completely from Terraform and uses the
"provision_method" attribute from the Foreman API (again).
We will have to find an additional attribute to support the use case of
"enforced rebuild" that originally lead to the switch.
The "managed" flag is not changed.
Refs #40
Refs #68
Refs #106
* Add checks for image_id in compute_attributes in image-based provisioning
See examples/host/vmware_imagebased_host.tf for a VMware-backed image VM
Refs #103
Refs #102
Refs #105
* Fix test with failing provision_method Mock attribute
* Remove VMware-specific checks in ProvisionMethod==image in host creation
Removes an experimental check of the compute_attributes when using "image"-based
host creation. The backend providers need different values.
VMware for example needs the image_id as UUID, see the example file
in examples/host/vmware_imagebased_host.tf
Refs #125
0 commit comments