Documentation ¶
Index ¶
- Constants
- Variables
- func NewCmdSyncGroups(name, fullName string, f *clientcmd.Factory, out io.Writer) *cobra.Command
- func ValidateSource(source GroupSyncSource) bool
- type ADBuilder
- func (b *ADBuilder) GetGroupLister() (interfaces.LDAPGroupLister, error)
- func (b *ADBuilder) GetGroupMemberExtractor() (interfaces.LDAPMemberExtractor, error)
- func (b *ADBuilder) GetGroupNameMapper() (interfaces.LDAPGroupNameMapper, error)
- func (b *ADBuilder) GetUserNameMapper() (interfaces.LDAPUserNameMapper, error)
- type AugmentedADBuilder
- func (b *AugmentedADBuilder) GetGroupLister() (interfaces.LDAPGroupLister, error)
- func (b *AugmentedADBuilder) GetGroupMemberExtractor() (interfaces.LDAPMemberExtractor, error)
- func (b *AugmentedADBuilder) GetGroupNameMapper() (interfaces.LDAPGroupNameMapper, error)
- func (b *AugmentedADBuilder) GetUserNameMapper() (interfaces.LDAPUserNameMapper, error)
- type GroupNameRestrictions
- type GroupSyncSource
- type MappedNameRestrictions
- type OpenShiftGroupNameRestrictions
- type RFC2307Builder
- func (b *RFC2307Builder) GetGroupLister() (interfaces.LDAPGroupLister, error)
- func (b *RFC2307Builder) GetGroupMemberExtractor() (interfaces.LDAPMemberExtractor, error)
- func (b *RFC2307Builder) GetGroupNameMapper() (interfaces.LDAPGroupNameMapper, error)
- func (b *RFC2307Builder) GetUserNameMapper() (interfaces.LDAPUserNameMapper, error)
- type SyncBuilder
- type SyncGroupsOptions
- func (o *SyncGroupsOptions) Complete(typeArg, whitelistFile, blacklistFile, configFile string, args []string, ...) error
- func (o *SyncGroupsOptions) GetBlacklist() []string
- func (o *SyncGroupsOptions) GetClient() osclient.GroupInterface
- func (o *SyncGroupsOptions) GetGroupNameMappings() map[string]string
- func (o *SyncGroupsOptions) GetWhitelist() []string
- func (o *SyncGroupsOptions) Run(cmd *cobra.Command, f *clientcmd.Factory) error
- func (o *SyncGroupsOptions) Validate() error
Constants ¶
View Source
const (
SyncGroupsRecommendedName = "sync-groups"
)
Variables ¶
View Source
var AllowedSourceTypes = []string{string(GroupSyncSourceLDAP), string(GroupSyncSourceOpenShift)}
Functions ¶
func NewCmdSyncGroups ¶
func ValidateSource ¶
func ValidateSource(source GroupSyncSource) bool
Types ¶
type ADBuilder ¶
type ADBuilder struct { ClientConfig ldapclient.Config Config *api.ActiveDirectoryConfig // contains filtered or unexported fields }
func (*ADBuilder) GetGroupLister ¶
func (b *ADBuilder) GetGroupLister() (interfaces.LDAPGroupLister, error)
func (*ADBuilder) GetGroupMemberExtractor ¶
func (b *ADBuilder) GetGroupMemberExtractor() (interfaces.LDAPMemberExtractor, error)
func (*ADBuilder) GetGroupNameMapper ¶
func (b *ADBuilder) GetGroupNameMapper() (interfaces.LDAPGroupNameMapper, error)
func (*ADBuilder) GetUserNameMapper ¶
func (b *ADBuilder) GetUserNameMapper() (interfaces.LDAPUserNameMapper, error)
type AugmentedADBuilder ¶
type AugmentedADBuilder struct { ClientConfig ldapclient.Config Config *api.AugmentedActiveDirectoryConfig // contains filtered or unexported fields }
func (*AugmentedADBuilder) GetGroupLister ¶
func (b *AugmentedADBuilder) GetGroupLister() (interfaces.LDAPGroupLister, error)
func (*AugmentedADBuilder) GetGroupMemberExtractor ¶
func (b *AugmentedADBuilder) GetGroupMemberExtractor() (interfaces.LDAPMemberExtractor, error)
func (*AugmentedADBuilder) GetGroupNameMapper ¶
func (b *AugmentedADBuilder) GetGroupNameMapper() (interfaces.LDAPGroupNameMapper, error)
func (*AugmentedADBuilder) GetUserNameMapper ¶
func (b *AugmentedADBuilder) GetUserNameMapper() (interfaces.LDAPUserNameMapper, error)
type GroupNameRestrictions ¶
GroupNameRestrictions desribes an object that holds blacklists and whitelists
type GroupSyncSource ¶
type GroupSyncSource string
GroupSyncSource determines the source of the groups to be synced
const ( // GroupSyncSourceLDAP determines that the groups to be synced are determined from an LDAP record GroupSyncSourceLDAP GroupSyncSource = "ldap" // GroupSyncSourceOpenShift determines that the groups to be synced are determined from OpenShift records GroupSyncSourceOpenShift GroupSyncSource = "openshift" )
type MappedNameRestrictions ¶
MappedNameRestrictions describes an object that holds user name mappings for a group sync job
type OpenShiftGroupNameRestrictions ¶
type OpenShiftGroupNameRestrictions interface { GroupNameRestrictions GetClient() client.GroupInterface }
OpenShiftGroupNameRestrictions describes an object that holds blacklists and whitelists as well as a client that can retrieve OpenShift groups to satisfy those lists
type RFC2307Builder ¶
type RFC2307Builder struct { ClientConfig ldapclient.Config Config *api.RFC2307Config // contains filtered or unexported fields }
func (*RFC2307Builder) GetGroupLister ¶
func (b *RFC2307Builder) GetGroupLister() (interfaces.LDAPGroupLister, error)
func (*RFC2307Builder) GetGroupMemberExtractor ¶
func (b *RFC2307Builder) GetGroupMemberExtractor() (interfaces.LDAPMemberExtractor, error)
func (*RFC2307Builder) GetGroupNameMapper ¶
func (b *RFC2307Builder) GetGroupNameMapper() (interfaces.LDAPGroupNameMapper, error)
func (*RFC2307Builder) GetUserNameMapper ¶
func (b *RFC2307Builder) GetUserNameMapper() (interfaces.LDAPUserNameMapper, error)
type SyncBuilder ¶
type SyncBuilder interface { GetGroupLister() (interfaces.LDAPGroupLister, error) GetGroupNameMapper() (interfaces.LDAPGroupNameMapper, error) GetUserNameMapper() (interfaces.LDAPUserNameMapper, error) GetGroupMemberExtractor() (interfaces.LDAPMemberExtractor, error) }
SyncBuilder describes an object that can build all the schema-specific parts of an LDAPGroupSyncer
type SyncGroupsOptions ¶
type SyncGroupsOptions struct { // Source determines the source of the list of groups to sync Source GroupSyncSource // Config is the LDAP sync config read from file Config *api.LDAPSyncConfig // Whitelist are the names of OpenShift group or LDAP group UIDs to use for syncing Whitelist []string // Blacklist are the names of OpenShift group or LDAP group UIDs to exclude Blacklist []string // Confirm determines whether or not to write to OpenShift Confirm bool // GroupsInterface is the interface used to interact with OpenShift Group objects GroupInterface osclient.GroupInterface // Stderr is the writer to write warnings and errors to Stderr io.Writer // Out is the writer to write output to Out io.Writer }
func NewSyncGroupsOptions ¶
func NewSyncGroupsOptions() *SyncGroupsOptions
func (*SyncGroupsOptions) GetBlacklist ¶
func (o *SyncGroupsOptions) GetBlacklist() []string
func (*SyncGroupsOptions) GetClient ¶
func (o *SyncGroupsOptions) GetClient() osclient.GroupInterface
func (*SyncGroupsOptions) GetGroupNameMappings ¶
func (o *SyncGroupsOptions) GetGroupNameMappings() map[string]string
func (*SyncGroupsOptions) GetWhitelist ¶
func (o *SyncGroupsOptions) GetWhitelist() []string
func (*SyncGroupsOptions) Run ¶
Run creates the GroupSyncer specified and runs it to sync groups the arguments are only here because its the only way to get the printer we need
func (*SyncGroupsOptions) Validate ¶
func (o *SyncGroupsOptions) Validate() error
Click to show internal directories.
Click to hide internal directories.