Documentation
¶
Index ¶
- Constants
- func AddRoleToSubject(ctx context.Context, gc *gocloak.GoCloak, token, realm, idOfClient, sid string, ...) error
- func DeleteRoleFromSubject(ctx context.Context, gc *gocloak.GoCloak, token, realm, idOfClient, sid string, ...) error
- func ExtractEndpointFromSpec(r *BaseReconciler, ctx context.Context, spec v1alpha2.KeycloakEndpointSpec, ...) (*gocloak.GoCloak, string, error)
- func GetSubjectID(ctx context.Context, gc *gocloak.GoCloak, token, realm, idOfClient string, ...) (string, error)
- func GetSubjectRoles(ctx context.Context, gc *gocloak.GoCloak, token, realm, idOfClient, sid string, ...) ([]*gocloak.Role, error)
- func HandleError(err error) (ctrl.Result, error)
- func HasFinalizer(i client.Object) bool
- func IgnoreNotFound(err error) error
- func IsConfigMapEmpty(cm *api.ConfigMapValue) bool
- func IsNotFound(err error) (*gocloak.APIError, bool)
- func MarkedAsDeleted(i client.Object) bool
- func NoFinalizer(i client.Object) bool
- func Now() *metav1.Time
- func Unwrap[T any](v *T) T
- type ApiHelper
- func (api *ApiHelper) AlreadyDeleted() error
- func (api *ApiHelper) Created() error
- func (api *ApiHelper) Deleted() error
- func (api *ApiHelper) Error(action, text string, err error) error
- func (api *ApiHelper) EventUpdate(changelog diff.Changelog)
- func (api *ApiHelper) NoChange() error
- func (api *ApiHelper) Updated() error
- func (api *ApiHelper) Waiting(text string) error
- type BaseReconciler
- func (r *BaseReconciler) Api(ctx context.Context, i Object) *ApiHelper
- func (r *BaseReconciler) AppendFinalizer(ctx context.Context, i client.Object) error
- func (r *BaseReconciler) AppendOwnerReferences(ctx context.Context, i, owner client.Object) error
- func (r *BaseReconciler) CustomPatch(ctx context.Context, i client.Object, key, value, previous string) error
- func (r *BaseReconciler) ExtractEndpoint(ctx context.Context, i Object) (*gocloak.GoCloak, string, error)
- func (r *BaseReconciler) RemoveFinalizer(ctx context.Context, i client.Object) error
- func (r *BaseReconciler) SyncLDAP(ctx context.Context, gc *gocloak.GoCloak, token string, i Object, ...) error
- type LDAPSync
- type NoReschedule
- type Object
- type Reconciler
- type Reschedule
Constants ¶
View Source
const DEFAULT_ALLOW_RULE = "default-allow-rule"
View Source
const FORBIDDEN = "Forbidden"
Variables ¶
This section is empty.
Functions ¶
func AddRoleToSubject ¶
func DeleteRoleFromSubject ¶
func ExtractEndpointFromSpec ¶
func ExtractEndpointFromSpec(r *BaseReconciler, ctx context.Context, spec v1alpha2.KeycloakEndpointSpec, ns string) (*gocloak.GoCloak, string, error)
func GetSubjectID ¶
func GetSubjectRoles ¶
func HasFinalizer ¶
func IgnoreNotFound ¶
func IsConfigMapEmpty ¶
func IsConfigMapEmpty(cm *api.ConfigMapValue) bool
func MarkedAsDeleted ¶
func NoFinalizer ¶
Types ¶
type ApiHelper ¶
type ApiHelper struct { *BaseReconciler Context context.Context Object Object }
A api to manage log/event/status related to keycloak API resources.
func (*ApiHelper) AlreadyDeleted ¶
func (*ApiHelper) EventUpdate ¶
type BaseReconciler ¶
func NewReconciler ¶
func NewReconciler(mgr ctrl.Manager) BaseReconciler
func (*BaseReconciler) AppendFinalizer ¶
Append the finalizer to the object
func (*BaseReconciler) AppendOwnerReferences ¶
func (*BaseReconciler) CustomPatch ¶
func (*BaseReconciler) ExtractEndpoint ¶
func (r *BaseReconciler) ExtractEndpoint(ctx context.Context, i Object) (*gocloak.GoCloak, string, error)
Extract the endpoint, but deal with several kind of errors
func (*BaseReconciler) RemoveFinalizer ¶
type NoReschedule ¶
type NoReschedule struct{}
A wrapper for errors that should not retrigger the reconciler.
func (NoReschedule) Error ¶
func (nr NoReschedule) Error() string
func (NoReschedule) Is ¶
func (nr NoReschedule) Is(err error) bool
type Reconciler ¶
type Reconciler interface { BaseReconciler }
type Reschedule ¶
func (Reschedule) Error ¶
func (r Reschedule) Error() string
func (Reschedule) Is ¶
func (r Reschedule) Is(err error) bool
Click to show internal directories.
Click to hide internal directories.