Class: Actions::Katello::Host::Reassign

Inherits:
Base
  • Object
show all
Defined in:
app/lib/actions/katello/host/reassign.rb

Instance Method Summary collapse

Instance Method Details

#plan(host, content_view_id, environment_id) ⇒ Object



5
6
7
8
9
# File 'app/lib/actions/katello/host/reassign.rb', line 5

def plan(host, content_view_id, environment_id)
  cvenv = ::Katello::ContentViewEnvironment.find_by_cv_and_lce!(content_view_id, environment_id)
  host.content_facet.content_view_environments = [cvenv]
  host.update_candlepin_associations
end