Actions
Bug #24662
closed"Provision method can't be updated after host is provisioned" error when provision method is changed from implicit to explicit 'build'
Status:
Closed
Priority:
Normal
Assignee:
-
Category:
Web Interface
Target version:
-
Description
As shown by a small Rails console example;
irb(main):001:0> h = Host::Managed.find_by(name: 'example-machine') => #<Host::Managed id: 4512 ... irb(main):002:0> h.attributes['provision_method'] => nil irb(main):003:0> h.provision_method => "build" irb(main):004:0> h.provision_method = 'build' => "build" irb(main):005:0> h.validate! ActiveRecord::RecordInvalid: Validation failed: Provision method can't be updated after host is provisioned from (irb):5 from lib/tasks/console.rake:5:in `block in <top (required)>'
This error has started occuring for us when combining our own WDS plugin - which seems to cause Foreman to always send the provision method as a parameter when saving hosts, and discovery - which creates discovered host entries that use the implicit 'build' provision method.
Updated by The Foreman Bot about 6 years ago
- Status changed from New to Ready For Testing
- Pull request https://github.com/theforeman/foreman/pull/6102 added
Updated by Alexander Olofsson about 6 years ago
- Status changed from Ready For Testing to Closed
Applied in changeset 0dacc639d650f157718fbc7dacce0e6658a4107f.
Actions