Bug #14325
closedVM does not start after creation when using a compute profile
Description
Using the vmware provider on 1.10.2, we are provisioning VMs using the API. If we use a compute profile, the VM does not start upon boot.
The JSON we POST to /api/hosts is something like:
{
"host": {
"compute_profile_id" : 46,
"ip" : null,
"hostgroup_name" : "mgmt/test",
"compute_resource_id" : 2,
"name" : "test01.example.com",
"build" : "true",
}
}
If I try the same host through the UI, it starts the VM properly after creation.
Updated by Dominic Cleal over 8 years ago
- Is duplicate of Bug #10223: Image provisoning over API doesn't start host automatically added
Updated by Dominic Cleal over 8 years ago
- Status changed from New to Duplicate
Thanks for the report, we're tracking this under ticket #10223.
It's possible to provide "compute_attributes":{"start":"1"}
to workaround this problem, but on 1.10 you'd also need to supply all attributes from the compute profile as it overwrites them. In Foreman 1.11, the compute attributes from the API get merged into the compute profile.
Updated by Greg Petras over 8 years ago
Dominic Cleal wrote:
Thanks for the report, we're tracking this under ticket #10223.
Ah, thanks - I searched for one but didn't see that ticket. Thanks!
It's possible to provide
"compute_attributes":{"start":"1"}
to workaround this problem, but on 1.10 you'd also need to supply all attributes from the compute profile as it overwrites them. In Foreman 1.11, the compute attributes from the API get merged into the compute profile.
Ok, thanks. I do see that behavior. Looking forward to 1.11. Thanks Dominic!