Documentation ¶
Index ¶
- func CreateAgentConfigMapInNamespace(instance *agentv1alpha1.Agent, namespace string) *corev1.ConfigMap
- func CreateAgentSecretInNamespace(instance *agentv1alpha1.Agent, namespace string) (*corev1.Secret, error)
- func CreateConfigMapForAgent(client client.Client, recorder record.EventRecorder, ...) (controllerutil.OperationResult, error)
- func CreateSecretForAgent(client client.Client, recorder record.EventRecorder, secret *corev1.Secret, ...) (controllerutil.OperationResult, error)
- type AgentHooks
- type AgentReconciler
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateAgentConfigMapInNamespace ¶
func CreateAgentConfigMapInNamespace(instance *agentv1alpha1.Agent, namespace string) *corev1.ConfigMap
CreateAgentConfigMapInNamespace creates the Agent ConfigMap in the given namespace instead of the default one.
func CreateAgentSecretInNamespace ¶
func CreateAgentSecretInNamespace(instance *agentv1alpha1.Agent, namespace string) (*corev1.Secret, error)
CreateAgentSecretInNamespace creates the Agent Secret for ApiKey in the given namespace instead of the default one.
func CreateConfigMapForAgent ¶
func CreateConfigMapForAgent( client client.Client, recorder record.EventRecorder, configMap *corev1.ConfigMap, ctx context.Context, instance *agentv1alpha1.Agent) ( controllerutil.OperationResult, error, )
CreateConfigMapForAgent calls the Kubernetes API to create the provided Agent ConfigMap resource.
func CreateSecretForAgent ¶
func CreateSecretForAgent( client client.Client, recorder record.EventRecorder, secret *corev1.Secret, ctx context.Context, instance *agentv1alpha1.Agent) ( controllerutil.OperationResult, error, )
CreateSecretForAgent calls the Kubernetes API to create the provided Agent Secret resource.
Types ¶
type AgentHooks ¶
type AgentHooks struct {
// contains filtered or unexported fields
}
AgentHooks injects the default spec of Aperture Agent in CR.
func (*AgentHooks) Handle ¶
Handle receives incoming requests from MutatingWebhook for newly created Agents, set defaults and validates them.
func (*AgentHooks) InjectDecoder ¶
func (agentHooks *AgentHooks) InjectDecoder(d *admission.Decoder) error
InjectDecoder injects the decoder.
type AgentReconciler ¶
type AgentReconciler struct { client.Client DynamicClient dynamic.Interface Scheme *runtime.Scheme Recorder record.EventRecorder ApertureInjector *mutatingwebhook.ApertureInjector // contains filtered or unexported fields }
AgentReconciler reconciles a Agent object.
func (*AgentReconciler) Reconcile ¶
Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state. TODO(user): Modify the Reconcile function to compare the state specified by the Agent object against the actual cluster state, and then perform operations to make the cluster state reflect the state specified by the user.
For more details, check Reconcile and its Result here: - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.11.2/pkg/reconcile
func (*AgentReconciler) SetupWithManager ¶
func (r *AgentReconciler) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager sets up the controller with the Manager.