Documentation
¶
Index ¶
- func GetDistributionClassRef(distro api.Distribution) api.ObjectReference
- func GetSecretRef(distro api.Distribution) string
- func NewIndexer(mgr ctrl.Manager, key string, indexer IndexerFunc)
- func NewObjectReferenceIndexer(mgr ctrl.Manager, kind string, indexer ObjReference)
- func SetUpDistributionIndexers(mgr ctrl.Manager)
- type IndexerFunc
- type ObjReference
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetDistributionClassRef ¶
func GetDistributionClassRef(distro api.Distribution) api.ObjectReference
Returns the DistributionClassRef for the given Distribution
func GetSecretRef ¶
func GetSecretRef(distro api.Distribution) string
Returns the secret name for the given Distribution
If TLS is not specified, an empty string is returned.
func NewIndexer ¶
func NewIndexer(mgr ctrl.Manager, key string, indexer IndexerFunc)
Indexes a new field on Distributions with the given index key and using the given IndexerFunc to extract the field
In the event that the IndexerFunc returns an emtpty string, no fields will be indexed.
func NewObjectReferenceIndexer ¶
func NewObjectReferenceIndexer(mgr ctrl.Manager, kind string, indexer ObjReference)
Indexes a new Object Reference field on Distributions
If the ObjectReference is blank, or is not for the given type, an empty string is returned. Otherwise the Object Reference's name is returned.
func SetUpDistributionIndexers ¶
func SetUpDistributionIndexers(mgr ctrl.Manager)
Sets up the field indexes for Distribution resources
These are: - DistributionClasses referenced in DistributionClassRef - ClusterDistributionClasses referenced in DistributionClassRef - Secrets referenced in TLS.SecretRef
Types ¶
type IndexerFunc ¶
type IndexerFunc func(api.Distribution) string
Returns the value of a field for a given Distribution to be used by the FieldIndexer
This is a more specific func of the client.IndexerFunc, tailored to a kubernetes-compatible single key, and Distribution resources.
type ObjReference ¶
type ObjReference func(api.Distribution) api.ObjectReference
Returns the ObjectReference value of a field for a given Distribution to be used by the FieldIndexer
This is a more specific func of the IndexerFunc above, tailored for fields with ObjectReference values.