Bug #15644
closedimport_facts assumes orchestration is available
Description
Currently (core:develop, discovery:develop) provisioning a discovered host isn't possible. The `import_facts` method assumes there are two methods defined, enable_orchestration! and skip_orchestration! which do not exist for Host::Discovered.
This causes Foreman to throw the following error "undefined method `enable_orchestration!' for #<Host::Discovered:0x005623782265b8>". This is also true when importing facts for a host with :unattended => false
Host::Discovered doesn't need the Orchestration module for anything, however `import_facts` assumes it's there. This should involve two fixes:
1: in discovery, so that it can skip those calls (mocking them or something).
2: in core, so that import_facts doesn't have to rely on anything but Host::Base APIs. It should "know less", and let Host::Managed do these things (enable/skip orchestration) perhaps, as that's where it matters.
The code that causes this error will go in 1.12.1 https://github.com/theforeman/foreman/pull/3574/files#diff-07cbb99bfdb4bed86ad02486bb5adde2R174 so we should hurry up and release a version that fixes the problem. http://projects.theforeman.org/issues/15306
Updated by Daniel Lobato Garcia over 8 years ago
- Related to Bug #15306: Orchestration does not roll back queued actions if DB error occurs added
Updated by Dominic Cleal over 8 years ago
This is a bug in Foreman if Host::Base assumes a Host::Managed (Orchestration) method exists.
Updated by Daniel Lobato Garcia over 8 years ago
- Project changed from Discovery to Foreman
- Category changed from Discovery plugin to Orchestration
Moving to Foreman then
Updated by Dominic Cleal over 8 years ago
- Translation missing: en.field_release set to 161
Updated by The Foreman Bot over 8 years ago
- Status changed from New to Ready For Testing
- Assignee set to Daniel Lobato Garcia
- Pull request https://github.com/theforeman/foreman/pull/3637 added
Updated by Dominic Cleal over 8 years ago
- Translation missing: en.field_release changed from 161 to 160
Updated by Daniel Lobato Garcia over 8 years ago
- Status changed from Ready For Testing to Closed
- % Done changed from 0 to 100
Applied in changeset 8cf057c84f11598d92918a0b747cf49903822e69.
Updated by Felix Barbeira about 8 years ago
- Related to Bug #17118: Error pushing facts to foreman added