Default organizations and locations

There was a brief conversation about this on IRC, but Ohad had to run so I'm moving it to the list.

New hosts are currently required to be part of an organization or location if they are enabled. This can be confusing to users because if they don't have any orgs/locations then fields won't get populated on the host creation page. I think there are a few ways to deal with this:

  1. Create a dummy location or organization when the features are enabled. This is probably easiest for new installations, but might be tricky for users with existing infrastructure in foreman because users will then have a location or organization they're not familiar with and will have to change.

  2. If a user has permission to create a new location or organization then present a modal after login that asks them to create a new location or org. If the user doesn't have permission to create one, then the modal will just say they need to contact their administrator because locations/orgs are enabled, but none exist. This is the most complicated option as I see it, but also probably the best from a usability perspective.

  3. Don't force a location and/or organization to be selected. This would mirror the way other parts of Foreman, like hostgroups, currently work. Users that are pinned to a certain location or organization (or combo of the two) wouldn't be able to view hosts that exist outside orgs/locations that they don't have permission to view, including those that aren't assigned a location or organization.

Interested to get some feedback on this!

-Sam

Wouldn't it make sense to have a Default organization / Default
Location (atleast from UI point of view) regardless of whether Orgs
and Locations are enabled. Unifying the experience as well. Parts of
the UI could advise operator that changes to Locs and Orgs are not
possible until the feature is enabled.

Not sure that's possible though, Locs and Orgs sure feel complicated
(but powerful!)

··· On Wed, Jan 16, 2013 at 7:30 PM, David Caplan wrote: > Why not define a baseline organization and location that act as wildcards > for searching functions. Unless explicitly modified by an authorized > administrator all new hosts are placed into the baseline org and location. > The location acts like a wildcard, so it always resolves.


Mikael