Project

General

Profile

Bug #2644

HostController.find_by_name needs refactoring

Added by Greg Sutcliffe almost 6 years ago. Updated almost 6 years ago.

Status:
Closed
Priority:
Normal
Category:
Unattended installations
Target version:
Difficulty:
Triaged:
No
Bugzilla link:
Pull request:
Team Backlog:
Fixed in Releases:
Found in Releases:

Description

Presently this method makes unnecessary checks for permissions (which could be handled by scope) and restricts itself to Host::Managed which can break Discovery. This should also be refactored to allow additional ways of finding a host.

https://github.com/theforeman/foreman/pull/699

Associated revisions

Revision 5b5af86e (diff)
Added by Greg Sutcliffe almost 6 years ago

Fixes #2644 - Refactor Host find_by_name to use several ways to find a
host, and refactor my_hosts scope to Host::Base, allowing us to remove
unnecessary permissions check from find_by_name

Revision 87bd795e (diff)
Added by Greg Sutcliffe almost 6 years ago

Fixes #2644 - Refactor Host find_by_name to use several ways to find a
host, and refactor my_hosts scope to Host::Base, allowing us to remove
unnecessary permissions check from find_by_name
(cherry picked from commit 5b5af86ecd6f6b147aeb4dd4ceadd890dc9f2699)

History

#1 Updated by Greg Sutcliffe almost 6 years ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100

Also available in: Atom PDF